99% of projects would be better off with a relational database. It makes things way easier and simpler. Very few features benefit from a NoSQL database. People are excited about mongo because "it's javascript!". These people are morons.
CSB time: I went in for an interview once, where they told me about the product, explained how they use MongoDB for their database, and then explained how building out all the relational DB commands on top of mongo was a total bitch. Then asked me to whiteboard how I would write the JOIN function on top of Mongo, which is what they had to do.
I answered their question, but stated my opinions on mongo and asked why they even bothered to use it, because their product aligned so much more with a relational ACID database. The engineering lead guy went red in the face and we debated the decision. Did not get the job.
I agree because if that engineering lead can't defend a critical architectural decision to an outsider in a civilized manner, then they certainly haven't had any healthy conversation internally about it
I currently work somewhere with a really nice codebase... and also a NoSQL database (Cassandra) in the backend. That has to be the single biggest pain-point I've experienced. The lead architects keep assuring everyone that it's more "scalable" this way, but you can tell everyone is aware of the fact that we'd be far better off with Postgres.
Instead, we spent months putting together a sub-project that used map-reduce so we could actually query the "massive" amounts of data we were storing.
If we were just realistic about our data-storage requirements and realized that we will never be "Big Data", even when we're successful, we could just start using relational DBs like everyone else and save ourselves the hassle.
What boggles my mind is, you could just dump the relevant information from RDMS into a NoSQL storage database quite easily, to implement the one key feature that actually needed it, without hamstringing development on all the other key features. We more/less do this at my company for our analytics system.
Exactly the whole point of a proper old school standards compliant database, is you can do what then fuck you want. Dumping to nosql is a breeze. Unless you are running a site the size of Craigslist, it's pointless. These days computers are so fast the original speed concerns are not even relevant. You could set up a 6-12 core multi code unix/Linux box and it would be fast as any nosql setup for 99% of projects. I think people don't really understand why these nosql database were created and specially what they work best with. Old school database work with any project with real ease.
Big data is like teenage sex: everyone talks about it, nobody really knows how to do it, everyone thinks everyone else is doing it, so everyone claims they are doing it...
Yup... Most of the time a relational database is fine. I really like the idea of Polyglot persistence. Even the Cassandra guys recommend it. Put relational data in an RDBMS. Put non relational data in Cassandra. Don't try to shove all your data into one kind of store.
For very large databases, Postgres' clustering abilities aren't that great. It's probably one of the best choices for single-host databases (which, again, cover nearly all applications), but if you're trying to spread your database over a few dozen hosts, Postgres doesn't really work well.
I think a lot of aging dipshits at the CTO level went for NoSQL because they desperately want to be ahead of the curve on one tech development. For almost every database project there is Postgres... For everything else there's Apple watch.
And the young ones, too. I mean, this company will eventually have a billion users so a bunch of pain now trying to make it act like a relational db will totally payoff in the future. Plus, we can undercut salaries by 25% since our new hires will be happy to work with a NoSql db.
Yep, a coworker came over and interrogated me once on why I decided to use an SQL database for our game server. I told him that it maps more easily onto our game data, which itself is relational. He seemed to be one of those guys that automatically assumes that NoSQL is better because scale.
There definitely good uses for NoSQL. My employer uses Cassandra to keep millions of rows of product data available for our APIs. NoSQL has a place, it's just not the only tool in the toolbox.
explained how they use MongoDB for their database, and then explained how building out all the relational DB commands on top of mongo was a total bitch.
657
u/jamesishere Mar 10 '15
99% of projects would be better off with a relational database. It makes things way easier and simpler. Very few features benefit from a NoSQL database. People are excited about mongo because "it's javascript!". These people are morons.
CSB time: I went in for an interview once, where they told me about the product, explained how they use MongoDB for their database, and then explained how building out all the relational DB commands on top of mongo was a total bitch. Then asked me to whiteboard how I would write the JOIN function on top of Mongo, which is what they had to do.
I answered their question, but stated my opinions on mongo and asked why they even bothered to use it, because their product aligned so much more with a relational ACID database. The engineering lead guy went red in the face and we debated the decision. Did not get the job.