Shopify/identity_cache — pull request #53 by hornairs (2013-06-04 18:51:51+00:00)
Title: Allow disabling the primary index on objects in order to prevent extraneous index maintenance for mid level cached associations

If I have a three level deep top level -> has_many children -> has_many grandchildren, and I want to cache the whole tree, the mid level child object needs to include `IdentityCache` in order to get all the stuff which will allow it to `cache_has_many :grandchildren`. In the event that we're never fetching that child object directly however and just getting to it from the parent, maintaining the primary index for that midlevel child is just a waste of time. This allows the disabling of it while asserting that all the other stuff still works.

@camilo @dylanahsmith @boourns thoughts?