1

I'm using Rack::Cache, and google search bot triggers all my cache misses, so my cache is always full of pages that don't actually represent the most popular ones on my site, I can't seem to find how to ignore an IP or useragent for caching, has anyone had this problem before?

JP Silvashy
  • 46,977
  • 48
  • 149
  • 227

1 Answers1

1

You could check for Googlebot in the user-agent string and skip caching if it is.

Search agent strings: http://www.smart-it-consulting.com/internet/google/googlebot-spoofer/

Travis Reeder
  • 38,611
  • 12
  • 87
  • 87
  • This is a good route to take, I suppose I can wrap the cache method in each controller action with this condition. – JP Silvashy Aug 30 '11 at 04:46