logoalt Hacker News

spicybright • today at 3:26 PM • 7 replies • view on HN

People still use MongoDB?


Replies

giancarlostoro • today at 3:31 PM

MongoDB is not a bad database, it is not my first immediate choice for everything, but it is very easy to get into, super easy to prototype with. My biggest pet peeve is how it handled indexes, shoves it all into memory. That and how people use it sometimes bewilders me.

Two fun facts: ObjectID's are like Discord snowflakes: you can get a timestamp of when they were generated, you can also generate them client side, so you can filter items in a collection by when they were created.

The other one, that I always enjoyed is, you can take an existing ObjectId, and reinsert it into another document, you dont have to nest all your data, you can go kinda sorta relational about it.

Used it at a previous job, the first project could have just used a SQL db but because the person who made the intial one tried to do NoSQL using something in the cloud, they migrated it to MongoDB to keep it simple and consistent. The second project, well, we really discovered all the limits if you aren't Google with unlimited server memory available, like indexing as I mentioned. MongoDB pipelines are probably my favorite feature on the other hand.

➕ show 1 reply
stuckinaloop • today at 4:02 PM

IIRC (from my time there) Stripe still uses MongoDB for it's main datastore.

https://stripe.dev/blog/how-stripes-document-databases-suppo...

Salgat • today at 3:39 PM

MongoDB's biggest weakness was its default settings, which made it insecure and very vulnerable to data consistency failures. An absolute nightmare for PR. It's not perfect, but it's comparable to other NoSQL databases now.

➕ show 1 reply
d2kx • today at 3:47 PM

MongoDB has been a good database for years.

stevefan1999 • today at 6:55 PM

MongoDB is a natural choice if you are working with denormalized deeply hierarchical data structure like JSON. It is also natural to JavaScript devs since the shell itself is JavaScript. This makes it super effective on modern web framework although I recently switched to Drizzle

christkv • today at 5:19 PM

MongoDB is a great db for agentic workloads to be honest. Thats probably why they are still seeing growth. They also have some very good embedding models. They should really make those available over their own API though.

They probably should look into JEV style models as well might make sense for automatic classification of data.

vlyan • today at 3:42 PM

poor souls stuck maintaining brownfield webshit developed during the height of mongo's marketing campaign 10 years ago.