Infinispan - set per Entity expiration.lifespan

前端 未结 2 567
醉话见心
醉话见心 2021-01-14 08:51

I have a java web application deployed on Jboss 6.1.0, that uses infinispan 5.2.6.Final. I\'m trying to set a per Entity specific expiration.lifespan follow

2条回答
  •  余生分开走
    2021-01-14 09:17

    Spent hours to find correct configuration. Apparently it is as following:

    Hibernate property should be in the following format:

    hibernate.cache.infinispan... where:

    - by default it is in the name that you see in a sort of JNDI name. In case of Wildfly, it is ear-name.ear/ejb-jar-name.jar#persistence-unit-name However, it can be controlled by hibernate.cache.region_prefix property. Set region_prefix to "" and ignore the prefix.

    - String as it appears in org.hibernate.cache.infinispan.InfinispanRegionFactory class and in official Infinispan documentation.

    In short, official Infinispan documentation is correct only when you set hibernate.cache.region_prefix to ""

提交回复
热议问题