identity_cache icon indicating copy to clipboard operation
identity_cache copied to clipboard

Integrating kaminari with identity_cache

Open srebalaji opened this issue 7 years ago • 1 comments

Hi, I'm trying to integrate kaminari with identity_cache. As the fetch_ method returns the records in Array I can't able to restrict the records on page-wise. Any good practices to implement it.

Thank you

srebalaji avatar Feb 19 '18 05:02 srebalaji

IdentityCache's cache_has_many associations are meant to be used with relatively small bounded associations, since the result of loading the whole association is stored as a single cache blob.

To integrate with a paginator, we load the ids from the database, then fetch the full records using the ids from IdentityCache.

dylanahsmith avatar Feb 20 '18 15:02 dylanahsmith