Caching improvements
Implementation of the serialization-deserialization-overhead-eliminating strategy outlined in #289. Please see that issue for an outline and general details of the strategy.
Thanks for the pull request, and welcome! The Rails team is excited to review your changes, and you should hear from @rwz (or someone else) soon.
If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. Due to the way GitHub handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes.
Please see the contribution instructions for more information.
Please see this comment on the proposal pull request for performance results.
@dirk would love to try this out, do you have a fork you are maintaining for your own projects?
have you seen before?
ActionView::Template::Error (can't add a new key into hash during iteration): occurs when there is another nested cache!
@rromanchuk I think the error is raised when a template call same template itself.
# model/_template.jbuilder
if model[:child].present?
json.child model[:child], partial: 'model/template', as: :model
else
json.child []
end