Cache Graph for Ruby on Rails

问题内容:

Do you know any Ruby gem or library that implements cache with dependency graph? I’m looking for a solution for organizing cache objects to a graph structure and it’s intelligent enough to invalidate all the dependencies of a node recursively when the node becomes invalid. It’s just better if it supports Memcached or Redis as a storage engine.

问题评论:

    
What will be the case when node will become invalid?
    
When a node becomes invalid then all of its descendants would become invalid. Let me give you an example. There is a user-12 node that is a cache node for user#12. This parent node does not store data. It has subnodes for the attributes, user-12-name, user-12-email,… Only the leaves store data. When user#12‘s email address is updated then only cache user-12-email would be invalidated but the others would remain active. When the user is being deleted then the parent node (user-12) would become invalid and all of its dependencies, so user-12-name, user-12-email.
– Nucc
21 hours ago

原文地址:

https://stackoverflow.com/questions/47741108/cache-graph-for-ruby-on-rails

添加评论

友情链接:蝴蝶教程