I want to restoring CacheEntry to actual Entity Object.
Is there any solution about that ?
I’m using Hibernate second level cache with Hazelcast jcache specification.
Distributed Cache Cluster’s total memory is bigger than each local instance memory.
When i use Hibernate MultiLoad, it is too slow getting cached entity one by one in a synchronous way at remote cache cluster when there is no cached entries.
To solve this issue, i thought about the following way.
First. using asynchronous function that provided by cache provider for getting CachedEntries.
-> Asynchonouse function works getting cached entries in local cache and gettiing cached entries in remote cache asynchonously when not founded in local.
Second. Restoring cached entries taken from the above operation to actual entity objects.
Third. Getting entries which is not founded from the above operation using Hibernate findAllById().
Fourth. Merging all of entities that from the above operations.
How can i solve this performance issue ?
And is there any solution about restoring CacheEntry to actual Entity Object ?