How to get the cache misses in rails

I am using Rails.cache for caching

config.action_controller.perform_caching = true
config.cache_store = :file_store, "location"

How can I check if there was a cache miss?

Also, I am not able to see the cache miss information in my logs.

Thanks

1 answer

  • answered 2017-11-14 23:20 Daniel Westendorf

    To get pragmatic notifications about cache events, look to ActiveSupport::Notifications to subscribe to cache events.