From my understanding of Russian Doll caching with Cache Digests, in order to prevent us from having to version the fragments, if I update a child fragment the digest key should bubble up to expire it's parent.
If this is correct I am having an issue where I am updating a child's template that doesn't expire it's parent cache. In this scenario I am changing the html in /schoolworks/need_grading/row.html.haml and the changes are never reflected because of the cache on /schoolworks/need_grading/row.html.haml.
The haml code for the two different pages are:
/schoolworks/need_grading.html.haml
- cache @schoolwork.to_a do
#other html stuff
= render partial: 'schoolworks/need_grading/row', collection: @schoolwork
/schoolworks/need_grading/row.html.haml
- cache [ row, get_user_language] do
#other html stuff
= link_to row.title
I ran rake cache_digests:nested_dependencies TEMPLATE=schoolworks/need_grading and it returned
[
"schoolworks/need_grading/row"
]
It looks like the nested dependency matches up with the rendered partial. I'm lost on why this wouldn't expire the parent cache.