I'm pondering the use of S3 as a poor-man's load balancer / Akamai solution. I've already mounted (several different ways) S3 partitions using FUSE. I've mainly done it on the EC2 instance for immediate backup purposes. Amazon has now released their persistent storage solution for EC2, but there's much debate on the cost effetiveness of it all compared to mounting an S3 partition.
I personally found PersistentFS to be extremely good because you have a great deal of control over how your data is being accessed and what to expect in your monthly AWS bill as well as control it.
So of course a cache system needs to be fast. I would suspect Amazon's EBS to be the clear winner in that department. So mount one of those and store your CakePHP /tmp/ folder there...or why not the entire application at that point? Sure then we're making a moot point out of what I'm after.
I'm after a very specific thing here. I'm thinking about how S3 is mirrored and I'm focusing on it's advantage. Cheap High Availability and the power to offload strain on your server. Therefore, a pure S3 implementation is better than using the EBS because nothing goes through your server. In fact, your server can be down and your data will still be on S3. Also, I'm looking at the people who aren't using Amazon EC2 and/or don't have the ability to use FUSE. What about shared web hosts?
Naturally storing session data and other persistent data like that wouldn't be good. So in my thinking that leaves the model and persistent folders of the cache directory of CakePHP out. Again, I'm focusing on a specific purpose here. I'm targeting the view caching.
My question and research is now geared toward performance issues with view caching. So not all caching that CakePHP does, just specific types. So I guess a hypothesis would be: If the view cache folder is stored on and read from Amazon S3, then loading pages in CakePHP will be faster.
Is that true? I don't know. I have to think about performance issues...again, we're not just saying "here go load this file" when we load up view cache. There's other classes responsible for talking to these files. So the server hop may create an issue that slows something down...If so, is it to the point that it's detrimental? Is it a trade-off situation? Have a million visitors hit your cached page at once just a little bit slower than normal, or don't handle a million visitors at the same time? I'd personally rather handle some sort of digg effect a little slow than not at all.
I also have to think about the assets. CSS files, images, javascript, etc. So does the webroot folder have to be on S3 too? Is there a way to maybe have the engine store and look for all those assets on S3?
Something I'll be experimenting with and asking around for opinions and things I haven't thought of. However, it would be great to setup a "load-balance" solution for common files and assets for shared hosting. I know you can serve all your media off S3 from a shared host quite easily ... but a plug and play solution for CakePHP to do that would be great. I imagine that would help a lot of sites get more life out of a shared hosting solution.
Admin