Re:Convex vs. Firebase
by tlarkworthy on Wednesday June 22, 2022 @02:54AM
(#31832813)
I spoke at HYTRADBOI too! https://www.hytradboi.com/2022/creating-a-wire-compatible-fi...
> Consistency-wise Convex supports full serializability.
As discussed elsewhere both Firebase DBs too and also provide clients with a causally consistent snapshots too, so you are not actually adding anything over the Firebase offering. Firebase has optimistic updates too and can use clientside persistent storage (I think convex has just an in-memory cache at the moment).
> e.g., having to fetch a list of posts first before knowing which post ids to fetch comments for.
Yes this does perform badly. Though this type of join is also an IO hog on a relational DB too, just it's not so visible.
The specific concern with regards to multiple round trips is scenarios where the client needs to send multiple serial requests to render a web view, e.g., having to fetch a list of posts first before knowing which post ids to fetch comments for. These request waterfalls can lead to high page load times for many web apps.
Consistency-wise Convex supports full serializability. The main point this article is making with regards to consistency however is providing tools to ensure not only that the database is consistent but that the data rendered to the end user is also a consistent view. I talk a little more about that here: https://youtu.be/B9aeddqwVas?t=446
Btw we are huge fans of Firebase and think it did a ton to advance the industry forward. Thanks for your work on it!