4 ms·
I worked with one of the largest ad publishing companies. They wanted to track data about every client served an ad. This generated over 1.2 Terabyte per hour
by dsmithatx 9y ago
I worked with one of the largest ad publishing companies. They wanted to track data about every client served an ad. This generated over 1.2 Terabyte per hour of data when the MySQL master started to max out. We had the largest possible multiple core system. It was going to cost my client $30k to upgrade to SSD drives to get more out of MySQL. Also note we had to store this data on an expensive SAN in order to feed the data at a reasonable rate to MySQL or PostgreSQL.
I had just learned of MongoDB and went to school at 10gen for their sys admin class. I talked to the developer about storing the data in NoSQL using a small sharded cluster on a Friday. Monday morning he asked me to setup a MongoDB cluster. Tuesday we moved over from MySQL. They ended up using much smaller servers, got rid of the 3par and epsilon SAN's and saving tons of money.
My point is there are certain situations where NoSQL is still the answer unless you can cluster your SQL write server. I've moved on from working with Ad publishing clients but, I'm sure there are other places where SQL databases are not adequate.
NoSQL might be or, have been, a fad but, like any tool when used for the right job it works.
- qaq 9y agoA production large scale ad. system system that was doing 1.2 TB per hour in writes, was migrated over from MySQL to MongoDB in roughly 24 hour window cool story Bro.
- mcintyre1994 9y agoIf more comments were like their story then this would be a way higher value comments section.
- qaq 9y agohow can more made up stories result in higher value comments section?
- DenisM 9y agoGood point. How is it possible to move that much data from SAN to mongo cluster in such a short time window?
- qaq 9y agoand rewrite and validate all the code that was accessing MySQL to use MongoDB
- foxh0und 9y agoWas $30k a lot of money for one of the largest add publishers?
- roel_v 9y agoOTOH, if you're a consultant, and you can say 'hey guys I can save you 30k, my fee is only 15k', and you can do it in a week - I mean, there are weeks where I bill less than 15k...
- quickthrower2 9y ago3k a day consulting. I'm in!
- tehlike 9y agosounds like the wrong tool. what you are producing was probably logs data, which is immutable. There are far more efficient (storage, cpu) write-only stores.
- skrebbel 9y agoSuch as?
- hvidgaard 9y agoConcider what a database does. It provides ACID properties and ability to query data. If all you need is writing data, the fastest you can do it write it directly to the disk, without the overhead a database comes with. Using a loadbalancer in front of a farm of cheap logging machines, and aggreate the data you need for analysis to a suitable machine.
- LoSboccacc 9y agothey'd still need to query their stuff, I guess, so you'd need to trow in there somewhere something to aggregate logs and get the metrics they're tracking out of it - which can totally be done in streaming, without the need of going trough the logs every time, for most metrics.
- hvidgaard 9y agoWith that amount of data, streaming and only saving aggregated data is the only sane way. With 1.2TB/hour there is a limit to how much historical data that can be saved anyway, and we're talking about 30% utilization of a 10gbps network interface, so it's beyond using single machines for most usecases.
- tehlike 9y agoQuery? Most likely not. At least not in the traditional "lets on the fly create a dashboard" sense.
- 0xbear 9y agoThe largest ad system ever, Google AdSense, used MySQL until circa 2014 when it moved to a completely custom DB backend, F1. F1 is also a SQL database, however. Google does use bigtable and such where appropriate, but for anything more complex than dumb key/value you can't do much better than regular DBs. Some people think they can, but 99% of the time they're mistaken.
- dx034 9y agoHow can MongoDB use that much less in such a situation? Especially prior to WireTiger? An optimised schema in a relational database should be close to the minimum possible storage.