Re: [hibernate-dev] What does CacheConcurrencyStrategy.NONE mean?
On Mon, Jul 30, 2018 at 3:59 PM Steve Ebersole wrote: > It is equivalent to `javax.persistence.Cacheable(false)`, although it was > never well defined what it means in relation to > `javax.persistence.SharedCacheMode` > OK, thanks, will just fix the NPE then. ___ hibernate-dev mailing list hibernate-dev@lists.jboss.org https://lists.jboss.org/mailman/listinfo/hibernate-dev
Re: [hibernate-dev] What does CacheConcurrencyStrategy.NONE mean?
It is equivalent to `javax.persistence.Cacheable(false)`, although it was never well defined what it means in relation to `javax.persistence.SharedCacheMode` On Mon, Jul 30, 2018 at 5:40 AM Guillaume Smet wrote: > Hi, > > Does setting @Cache(usage = CacheConcurrencyStrategy.NONE) on an entity > mean that we entirely disable the 2nd level cache for this entity? > > The documentation does not reference this value and the Javadoc does not > state clearly that the cache is disabled with this concurrency strategy. > > Asking that because of: > - https://hibernate.atlassian.net/browse/HHH-12587 - where Chris disabled > writing to the cache in this case to fix a NPE; > - https://hibernate.atlassian.net/browse/HHH-12868 - where we have the > exact same NPE when reading from the cache. > > The fix is easy if it's just about disabling the cache in this case but > maybe we should update the Javadoc of CacheConcurrencyStrategy if it's > about disabling the cache entirely? > > Thanks for any insight! > > -- > Guillaume > ___ > hibernate-dev mailing list > hibernate-dev@lists.jboss.org > https://lists.jboss.org/mailman/listinfo/hibernate-dev > ___ hibernate-dev mailing list hibernate-dev@lists.jboss.org https://lists.jboss.org/mailman/listinfo/hibernate-dev
[hibernate-dev] What does CacheConcurrencyStrategy.NONE mean?
Hi, Does setting @Cache(usage = CacheConcurrencyStrategy.NONE) on an entity mean that we entirely disable the 2nd level cache for this entity? The documentation does not reference this value and the Javadoc does not state clearly that the cache is disabled with this concurrency strategy. Asking that because of: - https://hibernate.atlassian.net/browse/HHH-12587 - where Chris disabled writing to the cache in this case to fix a NPE; - https://hibernate.atlassian.net/browse/HHH-12868 - where we have the exact same NPE when reading from the cache. The fix is easy if it's just about disabling the cache in this case but maybe we should update the Javadoc of CacheConcurrencyStrategy if it's about disabling the cache entirely? Thanks for any insight! -- Guillaume ___ hibernate-dev mailing list hibernate-dev@lists.jboss.org https://lists.jboss.org/mailman/listinfo/hibernate-dev