Package org.infinispan.configuration.cache

Examples of org.infinispan.configuration.cache.Configuration.persistence()


            assertFalse(c.transaction().recovery().enabled()); // Non XA
            assertTrue(c.transaction().syncCommitPhase()); // Non XA - default configuration value
            assertTrue(c.transaction().syncRollbackPhase()); // Non XA - side effect of cache manager creation
            assertEquals(EvictionStrategy.NONE, c.eviction().strategy());
            assertEquals(-1, c.eviction().maxEntries());
            fileStore = (SingleFileStoreConfiguration) c.persistence().stores().get(1);
            assertTrue(fileStore.preload());
            assertFalse(fileStore.purgeOnStartup());

            c = cm.getCache("HibernateSearch-LuceneIndexesData").getCacheConfiguration();
            assertEquals(CacheMode.REPL_SYNC, c.clustering().cacheMode());
View Full Code Here


            assertFalse(c.transaction().recovery().enabled()); // Non XA
            assertTrue(c.transaction().syncCommitPhase()); // Non XA - default configuration value
            assertTrue(c.transaction().syncRollbackPhase()); // Non XA - side effect of cache manager creation
            assertEquals(EvictionStrategy.NONE, c.eviction().strategy());
            assertEquals(-1, c.eviction().maxEntries());
            fileStore = (SingleFileStoreConfiguration) c.persistence().stores().get(1);
            assertTrue(fileStore.preload());
            assertFalse(fileStore.purgeOnStartup());

            c = cm.getCache("HibernateSearch-LuceneIndexesLocking").getCacheConfiguration();
            assertEquals(CacheMode.REPL_SYNC, c.clustering().cacheMode());
View Full Code Here

            .persistence()
               .addStore(DummyInMemoryStoreConfigurationBuilder.class)
            .persistence()
               .clearStores()
         .build();
      assertEquals(c.persistence().stores().size(), 0);
   }

   @Test(expectedExceptions = CacheConfigurationException.class)
   public void testClusterNameNull() {
      GlobalConfigurationBuilder gc = new GlobalConfigurationBuilder();
View Full Code Here

            assertEquals(20000, c.eviction().maxEntries());
            assertEquals(EvictionStrategy.LIRS, c.eviction().strategy());
            assertEquals(10000, c.expiration().wakeUpInterval());
            assertEquals(10, c.expiration().lifespan());
            assertEquals(10, c.expiration().maxIdle());
            assertFalse(c.persistence().passivation());
            SingleFileStoreConfiguration fileStore = (SingleFileStoreConfiguration) c.persistence().stores().get(0);
            assertFalse(fileStore.fetchPersistentState());
            assertEquals("path", fileStore.location());
            assertFalse(fileStore.singletonStore().enabled());
            assertFalse(fileStore.purgeOnStartup());
View Full Code Here

            assertEquals(EvictionStrategy.LIRS, c.eviction().strategy());
            assertEquals(10000, c.expiration().wakeUpInterval());
            assertEquals(10, c.expiration().lifespan());
            assertEquals(10, c.expiration().maxIdle());
            assertFalse(c.persistence().passivation());
            SingleFileStoreConfiguration fileStore = (SingleFileStoreConfiguration) c.persistence().stores().get(0);
            assertFalse(fileStore.fetchPersistentState());
            assertEquals("path", fileStore.location());
            assertFalse(fileStore.singletonStore().enabled());
            assertFalse(fileStore.purgeOnStartup());
            assertTrue(fileStore.preload());
View Full Code Here

            assertEquals(12, c.expiration().lifespan());
            assertEquals(12, c.expiration().maxIdle());
            assertFalse(c.clustering().stateTransfer().fetchInMemoryState());
            assertEquals(60000, c.clustering().stateTransfer().timeout());
            assertEquals(10000, c.clustering().stateTransfer().chunkSize());
            ClusterLoaderConfiguration clusterLoader = (ClusterLoaderConfiguration) c.persistence().stores().get(1);
            assertEquals(35000, clusterLoader.remoteCallTimeout());
            assertTrue(clusterLoader.preload());
            assertEquals(Index.NONE, c.indexing().index());

            c = cm.getCache("dist").getCacheConfiguration();
View Full Code Here

            assertFalse(c.transaction().recovery().enabled()); // Non XA
            assertTrue(c.transaction().syncCommitPhase()); // Non XA - default configuration value
            assertTrue(c.transaction().syncRollbackPhase()); // Non XA - side effect of cache manager creation
            assertEquals(EvictionStrategy.NONE, c.eviction().strategy());
            assertEquals(-1, c.eviction().maxEntries());
            fileStore = (SingleFileStoreConfiguration) c.persistence().stores().get(1);
            assertTrue(fileStore.preload());
            assertFalse(fileStore.purgeOnStartup());

            c = cm.getCache("capedwarf-metadata").getCacheConfiguration();
            assertEquals(CacheMode.REPL_ASYNC, c.clustering().cacheMode());
View Full Code Here

            assertFalse(c.transaction().recovery().enabled()); // Non XA
            assertTrue(c.transaction().syncCommitPhase()); // Non XA - default configuration value
            assertTrue(c.transaction().syncRollbackPhase()); // Non XA - side effect of cache manager creation
            assertEquals(EvictionStrategy.NONE, c.eviction().strategy());
            assertEquals(-1, c.eviction().maxEntries());
            DummyInMemoryStoreConfiguration dummyStore = (DummyInMemoryStoreConfiguration) c.persistence().stores().get(1);
            assertFalse(dummyStore.preload());
            assertFalse(dummyStore.purgeOnStartup());

            c = cm.getCache("capedwarf-memcache").getCacheConfiguration();
            assertEquals(CacheMode.REPL_ASYNC, c.clustering().cacheMode());
View Full Code Here

            .persistence()
               .addStore(DummyInMemoryStoreConfigurationBuilder.class)
            .persistence()
               .clearStores()
         .build();
      assertEquals(c.persistence().stores().size(), 0);
   }

   @Test(expectedExceptions = CacheConfigurationException.class)
   public void testClusterNameNull() {
      GlobalConfigurationBuilder gc = new GlobalConfigurationBuilder();
View Full Code Here

            assertFalse(c.transaction().recovery().enabled()); // Non XA
            assertTrue(c.transaction().syncCommitPhase()); // Non XA - default configuration value
            assertTrue(c.transaction().syncRollbackPhase()); // Non XA - side effect of cache manager creation
            assertEquals(EvictionStrategy.NONE, c.eviction().strategy());
            assertEquals(-1, c.eviction().maxEntries());
            fileStore = (SingleFileStoreConfiguration) c.persistence().stores().get(0);
            assertTrue(fileStore.preload());
            assertFalse(fileStore.purgeOnStartup());
            assertEquals(Index.NONE, c.indexing().index());

            c = cm.getCache("capedwarf-dist").getCacheConfiguration();
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.