Passenger and conditional page caching, part 2

A while back I posted about Passenger and how it could affect my Giggle website. Today I got around to some testing to see if the idea I outlined would actually work. Unfortunately it seems that it doesn’t. Passenger has built-in support for running Rails applications, and it looks like its code for checking for […]

giggle patching

Uhoh. I had to do some hurried patching on Giggle yesterday when I tried to add the latest gig I went to and found it wouldn’t work. It seems my last set of updates caused a couple of problems that I hadn’t spotted. The first problem was entirely my own fault. Due to my caching […]

authentication and conditional page caching

This is another followup on conditional page caching in Rails. In the original article I glossed over the integration of the page caching with the authentication mechanism. After all, there are lots of web sites discussing how to do authentication in Rails, so it was not really the focus of the article. However a few […]

followup on conditional page caching

A reader of my blog entry conditional use of page cache in Rails pointed out some problems with the caching behaviour. Thanks Dan! The problem could occur because the “page cached” version of a page is served by the web server directly, and not by Rails, so it may have HTTP cache headers as defined […]

rails page caching dynamic images

My exchange rate graph application dynamically generates graph images, but the data only change once per day, and it always shows the same default image when you open the page. So there is clearly some gain to be made from caching the images. I got quite confused and spent a while fiddling with various Rails […]

Giggle 2 Search Caching

Finally, time for my third article about caching in my ‘Giggle 2’ project. The last part was about Fragment Caching, while this part is about my changes for Search Caching.To recap: the search page in the application presents some problems that are not entirely addressed by the ‘standard’ caching behaviour in Rails. Users can enter […]

Giggle 2 Search caching design notes

Just trying to record my thoughts while I’m working out the design. Search cache consists of ‘generations’. Generation is number, which is included into the fragment key. A single extra fragment stores the current generation number, along with its expiry time (if set). This can use YAML, which is quite simple. When a change means […]

Giggle 2 Fragment Caching

This is my second article about implementing caching in my ‘Giggle 2’ project. Unlike the first part this doesn’t include any ‘cleverness’ extending Rails, it’s just using standard Rails functionality, but I want a record of the issues for myself.# In my plan I wrote about caching the footer for each user, but once I […]

conditional use of page cache in Rails

As discussed in my previous post, I worked out a way to use Page caching for the ‘public’ view of my Rails app, while rendering the same pages through Rails if the user is logged in. I implemented my idea today, so here’s a bit more technical detail. First, I add a cookie that indicates […]

rails caching and my projects

After posting about my projects the other day, someone pointed out that my site was “broken”. So I spent quite a while investigating the performance issues. The site is hosted on Dreamhost, and set up through FastCGI – but it seems that Dreamhost’s FastCGI configuration is not really optimal for Rails applications. I made a […]