In memory cache solutions in C5

Hi there!

I've only recently started using C5, but I've got a couple of years of experience working with ZF1.x. And I've got a question regarding the caching.

While looking at the Image helper, I noticed that thumbnails were loaded from cache, that was always File based, which is all fine and dandy for small installs, but is not the fastest option provided by Zend. There are various means out there for caching, like Memcache(built in for Zend) and even more importantly - Redis (not built in, but a couple of nice implementations can be found on Github).

Has there been any talk/plans on providing us with means to choose which caching backend we want to use? On the top of my head I can think of Zend's TwoLevels caching backend that could be quite beneficial, if set up right, it could automatically store bigger items (like image) on the file system, and thing that fit - in memory based cache.

I'm just thinking, that having this sort of caching could speed up C5 by quite a bit.

View Replies:
focus43 replied on at Permalink Reply
Check out the quickstart package we put together on Pagodabox. Along with some other benefits, there's a nice little Redis package we built into it that takes care of the full page caching.

See for a larger discussion of what the quickstart does.
FnTm replied on at Permalink Reply
Ok, this is unexpected and quite impressive. I'm gonna take a long hard look at the code in the Github repo, but on a quick glance it seems a really solid solution for full-page caching.

But what about things like other small things, like small images, and the like? That could speed it up even more.
focus43 replied on at Permalink Reply
First - thanks. Redis definitely gave a noticeable speed boost on all the sites its been deployed on, and has been rock-solid thus far. If you are interested in implementing it, would be happy to help you out more. Shoot me a PM (really its just the package and then declaring a couple constants in config/site.php).

Re: caching other stuff, C5 used to take the approach of object caching instead of doing a full page cache - using Zend Cache actually (and I think the object cache library is still available, its just not used for things like pages, users, attributes, etc). I was kind of sad to see it get stripped out of the core, but it made sense given that Zend was using the file system to store serialized objects - and most sites are running on some low-end shared hosting. Needless to say that slowed it down and used up a lot of disk. I had used previous versions with memcached pretty successfully though.

For image caching - not sure I'm totally following your question. Explain more?
FnTm replied on at Permalink Reply
Thanks about the info. If I require any assistance with the package, I'll be sure to shoot you a message.

As to the images - don't mind it. Some late night development combined with some stress helped me think in all the wrong ways :)