Redis cache from Rails.cache is not getting hits
Response times are much larger than expected because any Rails.cache.fetch
seems to get a cache miss. Calls to RequestContext.redis
do seem to work, seeing a lot of cached keys there.
To check, check for the event log in Sentry (cache_read) and observe the hit parameter being false. Alternatively, open redis-cli (SELECT 1
) and observe that no keys are getting added (KEYS *
).