Remix.run Logo
▲ toast0 a day ago

My personal theory is the clouds charge bandwidth at absurd prices because it's easy to meter and it roughly correlates with all the input costs they can't easily meter.

At the end of the day, they have a margin they're targeting, and it's just easier to hang most of that on bandwidth.

▲danpalmer a day ago | parent | next [-]

This is likely a big part of it. Another is probably flexibility. You pay for the bandwidth you use, but that cost must fund all the bandwidth not being used that needs to exist because you expect to be able to use it if you need it.

People move to the cloud because it means no longer thinking about ordering machines, setting up routers, replacing hard drives... but they forget that the cloud provider is doing all of that and also doesn't know what their users are going to do! They can do forecasting of course, but they don't know when a customer is about to do a big transfer between two regions, or order 1000 new VMs. If in the same company you could push back, but when they're a paying customer you can't in the same way.

▲cduzz a day ago | parent | prev [-]

I've always advocated that it makes sense (for lots of things) to treat an AZ as a self contained service by itself, and to run, for instance, 3 of those services across 3 AZs; things inside an AZ talk to the local service.

The presumption was that for lots of things, you're kinda okay with some stuff within an AZ being eventually consistent on the assumption that the AZ will eventually come back online and what happened within it will still be there.

So for instance -- run 3 2 node kafka clusters instead of one 6 node kafka cluster.

This isn't a good idea for lots of things, but it does help to constrain some cross-AZ traffic that may not actually be all that useful.

▲hamburglar a day ago | parent | next [-]

Yes, when you’re building the cloud itself you follow this same pattern. AZ independence by default. Cross-AZ is an exception you must have a good reason for. Cross-region is a very rare exception and unless you are specifically building a feature whose point is going cross-region, you’ve messed up.

▲Vaushite a day ago | parent | prev [-]

Isn't this what happens automatically if you have a Kafka cluster split across AZs? Or do you mean each user's data is confined within an AZ and unavailable when it's down, but you still serve 2/3 of your customers?

▲cduzz 10 hours ago | parent [-]

I'll ignore fancy "kafka as a service" for a moment to just discuss a vanilla kafka cluster;

A 6 node cluster with 2 nodes in each AZ will be somewhat trashed by an AZ failure; lots of partitions lose redundancy, you'll have a pile of leader elections, and some partitions may be totally unavailable (if you messed up the AZ awareness or were particularly unlucky and a partition was already underreplicated). This mess will very likely cause your other 2 functional AZs to be degraded and if you'v got your acks set to what most people have them set to for most data you'll likely drop transactions that were in-flight. And if you've got your acks set to something paranoid, your cluster will be super slow all the time and hickup whenever AZ interconnects burp, which they do a lot.

This same "one AZ failure trashes the distributed system" issue holds true for opensearch and probably most other shared nothing systems.

So my proposal is usually 3 (or "N") independent clusters (which is probably also a pain in the ass) each tied to a single AZ, and service discovery such that internal services reach that internal resource, and only reach out to "all of it" when strictly necessary to do the bigger aggregations (opensearch cross cluster search / kafka consumers dumping into S3, etc).

So in that idiom, 2/3rds of your customers keep trucking along without noticing.

Now, if someone's droned the AZ and it's totally gone, and that was compliance critical data or whatever, it's time to talk to your in-house legal counsel about the force majeure clause in your SLAs. Ideally you talk about that particular column in your "risk register" ahead of time...

[edited to refine / correct partition issues with AZ failure]