Trying to configure invalidation-cache regions with different expiration lifespans.
I started with the following in standalone-ha.xml:
<invalidation-cache name="entity-invalidation" mode="SYNC"> <transaction mode="NON_XA"/> <eviction strategy="LRU" max-entries="10000"/> <expiration lifespan="300000" max-idle="120000"/> <!-- 5 minute max, 2 minute idle --> </invalidation-cache>
I added the following property in persistence.xml:
<property name="hibernate.cache.infinispan.jboss.eap-1.0-SNAPSHOT.jar#jboss-eap-hibernate.invalidation.cfg" value="entity-invalidation"/>
And in my entities, I used:
@Cache(usage = CacheConcurrencyStrategy.TRANSACTIONAL, region="invalidation")
Using JConsole, I see a region named "jboss.eap-1.0-SNAPSHOT.jar#jboss-eap-hibernate.invalidation(local)" has been created and find that my entities are put there in testing. But, the configuration from standalone-ha.xml isn't picked up as JConsole shows that maxIdle == -1 and lifespan == -1 whereas I expect to see 120000 and 300000, respectively. Also, this should not be a "local" cache.
- is cloned by
-
JBEAP-8220 [GSS](7.1.0) race condition between the start of the custom cache configurationservice and the cache creation by the region factory
- Closed
- is incorporated by
-
JBEAP-8221 [GSS] (7.0.z) race condition between the start of the custom cache configurationservice and the cache creation by the region factory
- Closed
- is related to
-
JBEAP-10453 Create test for JBEAP-8219
- Pull Request Sent