We have Rails 4.2 application running on production with the following configurations (cache related). And we have not implemented any caching technique so far (default setup).
config.action_controller.perform_caching = true
# Use a different cache store in production.
# config.cache_store = :mem_cache_store
I am having an issue with particular view which is not showing updated data accordingly.
Is there a way that I can disable fragment caching for particular view not in entire application?
TLDR: while caching can cause problems, it's worth verifying that you are actually using it before trying to fix it!
The simplest way to disable caching for a single view is also the most obvious (but potentially quite easy to miss):
Rails does not do any caching for you by default, so this will take care of it entirely. If you don't have a call to
cachewith a block inside your view, you are not using caching.E.g:
Cached:
Not cached: