3 ms·
I'm curious though. What does one do if the database goes away? Also, how does one achieve high availability without doubling costs? Is this covered anywhere as
by nstart 9y ago
I'm curious though. What does one do if the database goes away? Also, how does one achieve high availability without doubling costs? Is this covered anywhere as a topic area or book or dedicated blog? Quite curious how to get started with something like this.
- adrianN 9y agoI'd be very surprised if you could get a 1-out-of-2 system with only double the cost. You need twice the hardware and significantly more complex logic.
- di4na 9y agoIt depends of what you are trying to do. About the database : Cache. Offer a different flow that does not need the database, like with hardcoded stuff. Etc etc About doubling the costs : It highly depends. On a small app, sure it may double the cost. On a big thing with thousands of servers, you can play a bit more with redistributing roles and all.
- dastbe 9y agoyou're increasing costs, but you're insuring against the lost profits from your site being down as well as reduced consumer trust. there are ways to keep the cost multiplier down (running many smaller instances vs a single large instance, using containers and running mulitenant machines), but when you start thinking about all layers you want to add redundancy (load balancing, application, database, storage, etc.) you're going to be spending quite a bit of additional money for that insurance. which is why there are good arguments that not every application needs to build in these kinds of redundancy. For your specific question about databases, you generally have clustering to reduce the impact of any one database instance going down, caching of data to guard against temporary db outages/network issues, and sharding of data across multiple databases to reduce the blast radius of any one logical database going away entirely.