diff --git a/.travis.yml b/.travis.yml index c1f85c2..5ef4630 100644 --- a/.travis.yml +++ b/.travis.yml @@ -34,7 +34,7 @@ install: script: - mvn package -DskipTests - - mvn package appassembler:assemble + - mvn package jar:jar appassembler:assemble before_deploy: - bash .travis/create_release.sh diff --git a/README.md b/README.md index 945d052..fd88eed 100644 --- a/README.md +++ b/README.md @@ -20,13 +20,12 @@ You can also download all development versions from [Bintray](https://bintray.co * When using reporters for Sonar or Coveralls client needs to be invoked from project's root directory. * Due to Oracle license we can't ship the necessary oracle libraries directly with utPLSQL-cli. Please download the libraries directly from oracle website and put the jars into the "lib" folder of your utPLSQL-cli installation * Oracle `ojdbc8` driver - * Oracle `ucp` library - * If you are on a 11g database with non0standard NLS settings, you will also need the `orai18n` library. + * If you are on a 11g database with non standard NLS settings, you will also need the `orai18n` library. * All of the above can be downloaded from [Oracle download site](http://www.oracle.com/technetwork/database/features/jdbc/jdbc-ucp-122-3110062.html) ## Compatibility -The latest CLI is always compatible with all database frameworks of the same major version. -For example CLI-3.0.4 is compatible with database framework 3.0.0-3.0.4 but not with database framework 2.x. +The latest CLI is always compatible with all database frameworks of the same minor version. +For example CLI-3.0.4 is compatible with database framework 3.0.0-3.0.4 but not with database framework 2.x and 3.1.x. ## Usage diff --git a/pom.xml b/pom.xml index eef3a59..2f5dd67 100644 --- a/pom.xml +++ b/pom.xml @@ -22,6 +22,12 @@ java-api 3.0.4 compile + + + com.oracle.jdbc + ucp + + com.beust @@ -30,10 +36,22 @@ compile - junit - junit - 4.12 - test + com.zaxxer + HikariCP + 2.7.2 + compile + + + org.slf4j + slf4j-nop + 1.7.25 + compile + + + junit + junit + 4.12 + test diff --git a/src/main/java/org/utplsql/cli/ConnectionInfo.java b/src/main/java/org/utplsql/cli/ConnectionInfo.java index 4f76f81..d96a67f 100644 --- a/src/main/java/org/utplsql/cli/ConnectionInfo.java +++ b/src/main/java/org/utplsql/cli/ConnectionInfo.java @@ -1,8 +1,7 @@ package org.utplsql.cli; import com.beust.jcommander.IStringConverter; -import oracle.ucp.jdbc.PoolDataSource; -import oracle.ucp.jdbc.PoolDataSourceFactory; +import com.zaxxer.hikari.HikariDataSource; import java.io.File; import java.sql.Connection; @@ -22,16 +21,13 @@ public class ConnectionInfo { } } - private PoolDataSource pds = PoolDataSourceFactory.getPoolDataSource(); + private HikariDataSource pds = new HikariDataSource(); public ConnectionInfo(String connectionInfo) { - try { - this.pds.setConnectionFactoryClassName("oracle.jdbc.pool.OracleDataSource"); - this.pds.setURL("jdbc:oracle:thin:" + connectionInfo); - this.pds.setInitialPoolSize(2); - } catch (SQLException e) { - e.printStackTrace(); - } + + pds.setJdbcUrl("jdbc:oracle:thin:" + connectionInfo); + pds.setAutoCommit(false); + } public Connection getConnection() throws SQLException {