List of usage examples for org.hibernate.jpa AvailableSettings SHARED_CACHE_MODE
String SHARED_CACHE_MODE
To view the source code for org.hibernate.jpa AvailableSettings SHARED_CACHE_MODE.
Click Source Link
From source file:org.infinispan.test.hibernate.cache.CacheKeySerializationTest.java
License:LGPL
private SessionFactoryImplementor getSessionFactory(String cacheKeysFactory) { Configuration configuration = new Configuration().setProperty(Environment.USE_SECOND_LEVEL_CACHE, "true") .setProperty(Environment.CACHE_REGION_FACTORY, TestInfinispanRegionFactory.class.getName()) .setProperty(Environment.DEFAULT_CACHE_CONCURRENCY_STRATEGY, "transactional") .setProperty(AvailableSettings.SHARED_CACHE_MODE, "ALL") .setProperty(Environment.HBM2DDL_AUTO, "create-drop"); if (cacheKeysFactory != null) { configuration.setProperty(Environment.CACHE_KEYS_FACTORY, cacheKeysFactory); }/* ww w . ja v a 2s . co m*/ configuration.addAnnotatedClass(WithSimpleId.class); configuration.addAnnotatedClass(WithEmbeddedId.class); return (SessionFactoryImplementor) configuration.buildSessionFactory(); }
From source file:org.jooby.internal.hbm.HbmUnitDescriptor.java
License:Apache License
@Override public SharedCacheMode getSharedCacheMode() { return SharedCacheMode.valueOf(property(AvailableSettings.SHARED_CACHE_MODE, "UNSPECIFIED")); }