---
title: "Cloud Balancer"
date: 2008-07-30
description: "The latest Amazon S3 blackout made me think what could be done to try to solve this problem, when your application depends on S3 or any other cloud service.\nDoes this mean that you should all stop …"
---


The latest [Amazon S3][1] blackout made me think what could be done to try to solve this problem, when your application depends on S3 or any other cloud service.

Does this mean that you should all stop using cloud services and go back to your own data center? No way! There are better and more reasonable solutions. They just need a bit of thought and some experimentation.

Some people, like [Dave Winer][2], can even see that a new service can emerge from this need. On his article "[Amazon S3 down all day][3]", Dave proposes a possible solution:

> It seems there is a business opportunity here -- it would be easy to hook up an external service to S3, and for a fee, keep a mirror on another server. Then it would be a matter of redirecting domains to point at the other server when S3 goes down.

So, here's my proposed solution for this specific problem: use as many equivalent storage solutions as redundacy. Technicaly speaking, you should write your data to multiple services at once and create a read procedure that selects the fastest service and uses it.

[![Cloud Balancer diagram](http://farm4.static.flickr.com/3293/2717317758_460543353f_o.png "Cloud Balancer diagram")](http://flickr.com/photos/44124468340@N01/2717317758 "Cloud Balancer")

This solution can use [tarpipe][4] to let you write data to multiple destinations at once, and [Gnip][5] can inform your application about the best service to read from.

[1]: http://aws.amazon.com/s3 "Amazon S3"
[2]: http://scripting.com/ "Dave Winer"
[3]: http://www.scripting.com/stories/2008/07/20/amazonS3DownAllDay.html "Amazon S3 down all day"
[4]: http://tarpipe.com/ "tarpipe"
[5]: http://gnipcentral.com/ "Gnip"
