use of org.postgresql.ds.common.BaseDataSource in project hazelcast by hazelcast.
the class WriteJdbcPTest method createDataSource.
private static CommonDataSource createDataSource(boolean xa) {
BaseDataSource dataSource = xa ? new PGXADataSource() : new PGSimpleDataSource();
dataSource.setUrl(container.getJdbcUrl());
dataSource.setUser(container.getUsername());
dataSource.setPassword(container.getPassword());
dataSource.setDatabaseName(container.getDatabaseName());
return dataSource;
}
Aggregations