- Queries look more like application code so you're not wasting mental cycles and time trying to translate an idea into a SQL query. From experience, this leads to less-fragile queries.
- Little to no concern over injection attacks (you have to go out of your way to create potential for them).
- Easier to write non-trivial queries than with SQL (IMO).
- Type-casting data can be done in code as opposed to with SQL you have to use inline, platform-specific functions like field_name::timestamp.
- A single source of truth for how to query and develop with it (with SQL, you're almost always developing against a flavor of it).
- Scales reasonably well (and easily) for a majority of use cases.
- No room for dogmatic fervor/confusion around a specific variety of MongoDB as there's only one variety.
Why wouldn’t you need to worry about migrations without developing against a schema? You’ll need to worry more about migrations because your data will be more messy.
If you're careless with your data, yes. "With great power comes great responsibility."
At first at least, haven't checked in on that in awhile
In 99% of the cases, even if you need a flexible schema, PostgreSQL will remain the best choice.
Also, query for query, Mongo isn't going to be that much slower than PG, and faster for some usage patterns...
But what's the advantage of Postgresql in this case?
Note: I work at MongoDB
Isn't firebase built on top of mongoDb?
I'm not going to push for you to use MongoDB but am merely trying to provide some context around that Jepsen analysis.
As much fun as Jepsen is, I'd probably not follow up with a company that turned my product into a mockery. I enjoy the hell out of reading that report as an outsider, and I personally would be a repeat customer, but I can see how a company might not love the writeup.
there were zero done in 2021, two in early 2022 and even the footer copyright say 2022.
This is not easy to do with PostgreSQL, which we use for all other scenarios requiring a DB.