Skip to content

Firefox 3 not caching, hammer fix

Recently I’ve been finding Firefox 3 to be sluggish.   Pages on a Rails app I maintain were very slow to render.  Looking at the HTTP traffic through the terrific Firebug, I found that every resource on each page was being pulled down on every page refresh.    The application uses, and I argue overuses, several different Javascripts, some of which are fairly heavy.    The expectation was that they would be loaded on first page hit for the user, and subsequent requests would be served with an HTTP 304 Not Modified response.   I watched the Apache logs, and indeed all the javascripts/CSS/images were being redelivered with a 200 response.  I checked with other browsers, Konqueror and Opera, and they behaved as expected.

So I started searching, and found some users who found their cache settings in about:config had magically turned off.  Mine looked OK though.  Some say it caches too aggressively.   I thought maybe an extension like Firebug, Web Developer Toolbar, Session Manager or something was causing the problems, so I disabled all of them.  No dice.

Finally, in desperation, I moved my ~/.mozilla directory out of the way and started with a fresh profile.  That did the trick, now it is sending the appropriate headers to receive 304 responses.  I’ve carried this directory through many upgrades of Firefox, perhaps even back to the Firebird days.  I haven’t found a way to reimport my saved passwords, and I’ve got some extensions to reinstall, but at least things work.    Our server still shows an HTTP 200/304 ratio much larger than I’d hoped, causing me to wonder how many other br0ken Firefoxes are out there.

Post a Comment

Your email is never published nor shared. Required fields are marked *
*
*