use of com.scalar.db.service.StorageFactory in project scalardb by scalar-labs.
the class DistributedTransactionServiceWithConsensusCommitWithExtraReadIntegrationTest method setUpBeforeClass.
@BeforeClass
public static void setUpBeforeClass() throws ExecutionException, IOException {
ServerConfig serverConfig = ServerEnv.getServerConfig(Isolation.SERIALIZABLE, SerializableStrategy.EXTRA_READ);
if (serverConfig != null) {
server = new ScalarDbServer(serverConfig);
server.start();
}
GrpcConfig grpcConfig = ServerEnv.getGrpcConfig();
StorageFactory factory = new StorageFactory(grpcConfig);
admin = factory.getAdmin();
consensusCommitAdmin = new ConsensusCommitAdmin(admin, new ConsensusCommitConfig(grpcConfig.getProperties()));
createTables(admin, consensusCommitAdmin);
manager = new GrpcTransactionManager(grpcConfig);
}
use of com.scalar.db.service.StorageFactory in project scalardb by scalar-labs.
the class DistributedStorageIntegrationTestBase method beforeAll.
@BeforeAll
public void beforeAll() throws Exception {
initialize();
StorageFactory factory = StorageFactory.create(getProperties());
admin = factory.getAdmin();
namespace = getNamespace();
createTable();
storage = factory.getStorage();
}
use of com.scalar.db.service.StorageFactory in project scalardb by scalar-labs.
the class DistributedStorageMultiplePartitionKeyIntegrationTestBase method beforeAll.
@BeforeAll
public void beforeAll() throws Exception {
initialize();
StorageFactory factory = StorageFactory.create(TestUtils.addSuffix(getProperties(), TEST_NAME));
admin = factory.getAdmin();
namespaceBaseName = getNamespaceBaseName();
partitionKeyTypes = getPartitionKeyTypes();
executorService = Executors.newFixedThreadPool(getThreadNum());
createTables();
storage = factory.getStorage();
seed = System.currentTimeMillis();
System.out.println("The seed used in the multiple partition key integration test is " + seed);
}
use of com.scalar.db.service.StorageFactory in project scalardb by scalar-labs.
the class DistributedStorageSingleClusteringKeyScanIntegrationTestBase method beforeAll.
@BeforeAll
public void beforeAll() throws Exception {
initialize();
StorageFactory factory = StorageFactory.create(TestUtils.addSuffix(getProperties(), TEST_NAME));
admin = factory.getAdmin();
namespace = getNamespace();
clusteringKeyTypes = getClusteringKeyTypes();
createTables();
storage = factory.getStorage();
seed = System.currentTimeMillis();
System.out.println("The seed used in the single clustering key scan integration test is " + seed);
}
use of com.scalar.db.service.StorageFactory in project scalardb by scalar-labs.
the class DistributedStorageColumnValueIntegrationTestBase method beforeAll.
@BeforeAll
public void beforeAll() throws Exception {
initialize();
StorageFactory factory = StorageFactory.create(TestUtils.addSuffix(getProperties(), TEST_NAME));
admin = factory.getAdmin();
namespace = getNamespace();
createTable();
storage = factory.getStorage();
seed = System.currentTimeMillis();
System.out.println("The seed used in the column value integration test is " + seed);
}
Aggregations