I have a scenario in which a second-level Hibernate server is enabled, and I would like to cache an object for which 1000 instances are created every day and stored for 8 years, but the requests concern only the last two days. I would like to avoid the need to create a history table, because then for rare cases for historical searches, the code depends on the date.
Is it possible in Hibernate, with Infinispan as a level 2 provider, to configure a very specific concrete cache with specific attributes (eviction policy, size, etc.) that Hibernate should use for the Foo entity?
source
share