@After public void expelDatabase() { expel(); }
@After public void expelDatabase() { expel(); }
@Test public void params_reconnect_01() { // Create. StoreConnection.connectCreate(loc) ; // Drop. expel(); // Reconnect StoreConnection.connectCreate(loc, null) ; StoreParams pLoc = StoreParamsCodec.read(loc) ; assertNull(pLoc) ; StoreParams pDB = StoreConnection.connectExisting(loc).getDatasetGraphTDB().getStoreParams() ; assertNotNull(pDB) ; // Should be the default setup. assertTrue(StoreParams.sameValues(pDft, pDB)) ; }
@Test public void params_reconnect_01() { // Create. StoreConnection.connectCreate(loc) ; // Drop. expel(); // Reconnect StoreConnection.connectCreate(loc, null) ; StoreParams pLoc = StoreParamsCodec.read(loc) ; assertNull(pLoc) ; StoreParams pDB = StoreConnection.connectExisting(loc).getDatasetGraphTDB().getStoreParams() ; assertNotNull(pDB) ; // Should be the default setup. assertTrue(StoreParams.sameValues(pDft, pDB)) ; }
@Test public void params_reconnect_02() { // Create. StoreConnection.connectCreate(loc, null) ; // Drop. expel(); // Reconnect StoreConnection.connectCreate(loc, pSpecial) ; //StoreParams pLoc = StoreParamsCodec.read(loc) ; //assertNotNull(pLoc) ; StoreParams pDB = StoreConnection.connectExisting(loc).getDatasetGraphTDB().getStoreParams() ; assertNotNull(pDB) ; // Should be the default setup, modified by pApp for cache sizes. assertFalse(StoreParams.sameValues(pDft, pDB)) ; assertFalse(StoreParams.sameValues(pSpecial, pDB)) ; // Check it's default-modified-by-special. assertEquals(pSpecial.getBlockReadCacheSize(), pDB.getBlockReadCacheSize()) ; assertNotEquals(pDft.getBlockReadCacheSize(), pDB.getBlockReadCacheSize()) ; assertNotEquals(pSpecial.getBlockSize(), pDB.getBlockSize()) ; assertEquals(pDft.getBlockSize(), pDB.getBlockSize()) ; }
@Test public void params_reconnect_03() { // Create. StoreConnection.connectCreate(loc, pApp) ; // Drop. expel(); // Reconnect StoreConnection.connectCreate(loc, pSpecial) ; //StoreParams pLoc = StoreParamsCodec.read(loc) ; //assertNotNull(pLoc) ; StoreParams pDB = StoreConnection.connectExisting(loc).getDatasetGraphTDB().getStoreParams() ; assertNotNull(pDB) ; // Should be the default setup, modified by pApp for cache sizes. assertFalse(StoreParams.sameValues(pApp, pDB)) ; assertFalse(StoreParams.sameValues(pSpecial, pDB)) ; // Check it's default-modified-by-special. assertEquals(pSpecial.getBlockReadCacheSize(), pDB.getBlockReadCacheSize()) ; assertNotEquals(pApp.getBlockReadCacheSize(), pDB.getBlockReadCacheSize()) ; assertNotEquals(pSpecial.getBlockSize(), pDB.getBlockSize()) ; assertEquals(pApp.getBlockSize(), pDB.getBlockSize()) ; }
@Test public void params_reconnect_02() { // Create. StoreConnection.connectCreate(loc, null) ; // Drop. expel(); // Reconnect StoreConnection.connectCreate(loc, pSpecial) ; //StoreParams pLoc = StoreParamsCodec.read(loc) ; //assertNotNull(pLoc) ; StoreParams pDB = StoreConnection.connectExisting(loc).getDatasetGraphTDB().getStoreParams() ; assertNotNull(pDB) ; // Should be the default setup, modified by pApp for cache sizes. assertFalse(StoreParams.sameValues(pDft, pDB)) ; assertFalse(StoreParams.sameValues(pSpecial, pDB)) ; // Check it's default-modified-by-special. assertEquals(pSpecial.getBlockReadCacheSize(), pDB.getBlockReadCacheSize()) ; assertNotEquals(pDft.getBlockReadCacheSize(), pDB.getBlockReadCacheSize()) ; assertNotEquals(pSpecial.getBlockSize(), pDB.getBlockSize()) ; assertEquals(pDft.getBlockSize(), pDB.getBlockSize()) ; }
@Test public void params_reconnect_03() { // Create. StoreConnection.connectCreate(loc, pApp) ; // Drop. expel(); // Reconnect StoreConnection.connectCreate(loc, pSpecial) ; //StoreParams pLoc = StoreParamsCodec.read(loc) ; //assertNotNull(pLoc) ; StoreParams pDB = StoreConnection.connectExisting(loc).getDatasetGraphTDB().getStoreParams() ; assertNotNull(pDB) ; // Should be the default setup, modified by pApp for cache sizes. assertFalse(StoreParams.sameValues(pApp, pDB)) ; assertFalse(StoreParams.sameValues(pSpecial, pDB)) ; // Check it's default-modified-by-special. assertEquals(pSpecial.getBlockReadCacheSize(), pDB.getBlockReadCacheSize()) ; assertNotEquals(pApp.getBlockReadCacheSize(), pDB.getBlockReadCacheSize()) ; assertNotEquals(pSpecial.getBlockSize(), pDB.getBlockSize()) ; assertEquals(pApp.getBlockSize(), pDB.getBlockSize()) ; }