Search in sources :

Example 1 with OracleConnectionPoolDataSource

use of oracle.jdbc.pool.OracleConnectionPoolDataSource in project siesta by cadenzauk.

the class OracleConfig method dataSource.

@Bean
public DataSource dataSource() throws SQLException {
    OracleConnectionPoolDataSource pool = new OracleConnectionPoolDataSource();
    pool.setUser("siesta");
    pool.setPassword("siesta");
    pool.setURL("jdbc:oracle:thin:@127.0.0.1:1521:xe");
    return new PooledDataSource(pool, "ALTER SESSION SET NLS_DATE_FORMAT='YYYY-MM-DD'");
}
Also used : OracleConnectionPoolDataSource(oracle.jdbc.pool.OracleConnectionPoolDataSource) PooledDataSource(com.cadenzauk.core.sql.testutil.PooledDataSource) Bean(org.springframework.context.annotation.Bean)

Aggregations

PooledDataSource (com.cadenzauk.core.sql.testutil.PooledDataSource)1 OracleConnectionPoolDataSource (oracle.jdbc.pool.OracleConnectionPoolDataSource)1 Bean (org.springframework.context.annotation.Bean)1