Search in sources :

Example 1 with RdbTransactionLogStorage

use of com.dangdang.ddframe.rdb.transaction.soft.storage.impl.RdbTransactionLogStorage in project sharding-jdbc by dangdangdotcom.

the class RdbTransactionLogStorageOperationsTest method assertRdbTransactionLogStorageOperations.

@Test
public void assertRdbTransactionLogStorageOperations() throws SQLException {
    BasicDataSource dataSource = new BasicDataSource();
    dataSource.setDriverClassName(org.h2.Driver.class.getName());
    dataSource.setUrl("jdbc:h2:mem:db_transaction_storage");
    dataSource.setUsername("sa");
    dataSource.setPassword("");
    createTable(dataSource);
    TransactionLogStorage storage = new RdbTransactionLogStorage(dataSource);
    assertTransactionLogStorageOperations(storage);
}
Also used : RdbTransactionLogStorage(com.dangdang.ddframe.rdb.transaction.soft.storage.impl.RdbTransactionLogStorage) RdbTransactionLogStorage(com.dangdang.ddframe.rdb.transaction.soft.storage.impl.RdbTransactionLogStorage) TransactionLogStorage(com.dangdang.ddframe.rdb.transaction.soft.storage.TransactionLogStorage) BasicDataSource(org.apache.commons.dbcp.BasicDataSource) Test(org.junit.Test)

Aggregations

TransactionLogStorage (com.dangdang.ddframe.rdb.transaction.soft.storage.TransactionLogStorage)1 RdbTransactionLogStorage (com.dangdang.ddframe.rdb.transaction.soft.storage.impl.RdbTransactionLogStorage)1 BasicDataSource (org.apache.commons.dbcp.BasicDataSource)1 Test (org.junit.Test)1