You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@sqoop.apache.org by fe...@apache.org on 2018/12/04 14:32:13 UTC

sqoop git commit: SQOOP-3417: Execute Oracle XE tests on Travis CI

Repository: sqoop
Updated Branches:
  refs/heads/trunk 3c1fb870e -> 302674d96


SQOOP-3417: Execute Oracle XE tests on Travis CI

(Szabolcs Vasas via Fero Szabo)

This closes #65


Project: http://git-wip-us.apache.org/repos/asf/sqoop/repo
Commit: http://git-wip-us.apache.org/repos/asf/sqoop/commit/302674d9
Tree: http://git-wip-us.apache.org/repos/asf/sqoop/tree/302674d9
Diff: http://git-wip-us.apache.org/repos/asf/sqoop/diff/302674d9

Branch: refs/heads/trunk
Commit: 302674d96b18bae3c5283d16603afb985b892795
Parents: 3c1fb87
Author: Fero Szabo <fe...@apache.org>
Authored: Tue Dec 4 15:30:16 2018 +0100
Committer: Fero Szabo <fe...@apache.org>
Committed: Tue Dec 4 15:30:16 2018 +0100

----------------------------------------------------------------------
 .travis.yml       | 16 +++-------------
 COMPILING.txt     |  6 +-----
 build.gradle      |  9 +++++++--
 gradle.properties |  1 +
 4 files changed, 12 insertions(+), 20 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/sqoop/blob/302674d9/.travis.yml
----------------------------------------------------------------------
diff --git a/.travis.yml b/.travis.yml
index a2a9c38..dda1452 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -58,21 +58,11 @@ before_install:
     sleep 60;
   elif [ "$TEST_TASK" = "oracleXeTest" ];
   then
-  if [ -n "$ORACLE_DRIVER_URL" ];
-    then
-      mkdir -p drivers;
-      wget -q $ORACLE_DRIVER_URL --output-document ./drivers/oracledriver.jar;
-      ./src/scripts/thirdpartytest/start-thirdpartytest-db-containers.sh oracle;
-      sleep 90;
-    fi
+    ./src/scripts/thirdpartytest/start-thirdpartytest-db-containers.sh oracle;
+    sleep 90;
   fi
 script:
-- if [ "$TEST_TASK" != "oracleXeTest" ] || [ -n "$ORACLE_DRIVER_URL" ];
-  then
-    ./gradlew -Dsqoop.thirdparty.lib.dir=./drivers $TEST_TASK;
-  else
-    echo 'Skipping Oracle XE test execution because ORACLE_DRIVER_URL is not set.';
-  fi
+- ./gradlew $TEST_TASK;
 before_cache:
 - rm -f  $HOME/.gradle/caches/modules-2/modules-2.lock
 - rm -fr $HOME/.gradle/caches/*/plugin-resolution/

http://git-wip-us.apache.org/repos/asf/sqoop/blob/302674d9/COMPILING.txt
----------------------------------------------------------------------
diff --git a/COMPILING.txt b/COMPILING.txt
index f5d7e79..2d7c899 100644
--- a/COMPILING.txt
+++ b/COMPILING.txt
@@ -420,7 +420,7 @@ or
     thirdPartyTest
 ----
 
-Gradle is able download all of the necessary drivers except the Oracle one but the Ant build has to be provided
+Gradle is able download all of the necessary drivers but the Ant build has to be provided
 with the drivers for all the databases.
 
 Please note that even if you do not need to install RDBMSs to run Sqoop third party tests against the Docker containers you still need to install the following tools:
@@ -640,7 +640,3 @@ The steps for setting up the CI job are the following:
 
 The Travis CI job uses Gradle to build and test the project and it is able to execute all of the tests except the
 ones requiring an Oracle EE database.
-Note that by default the Oracle XE tests are also disabled because the necessary +ojdbc6.jar+ is not publicly available.
-Contributors have to upload +ojdbc6.jar+ to a public drive and make it available to the CI job by setting
-the +ORACLE_DRIVER_URL+ environment variable in Travis (for more information see Travis
-https://docs.travis-ci.com/user/environment-variables/#defining-variables-in-repository-settings[documentation]).

http://git-wip-us.apache.org/repos/asf/sqoop/blob/302674d9/build.gradle
----------------------------------------------------------------------
diff --git a/build.gradle b/build.gradle
index 47d4136..02d069e 100644
--- a/build.gradle
+++ b/build.gradle
@@ -46,6 +46,11 @@ repositories {
     maven {
         url 'https://artifacts.alfresco.com/nexus/content/repositories/public/'
     }
+
+    // Oracle driver repository
+    maven {
+        url 'http://www.datanucleus.org/downloads/maven2/'
+    }
 }
 
 sourceSets {
@@ -104,12 +109,10 @@ configurations.all {
     exclude group: 'org.apache.hadoop', module: 'avro'
 }
 
-def sqoopThirdPartyLib = System.getProperty("sqoop.thirdparty.lib.dir")
 def forkEveryDefault = Integer.valueOf(System.getProperty("forkEvery.default", "0"))
 def ignoreTestFailures = Boolean.getBoolean("ignoreTestFailures")
 
 dependencies {
-    if (sqoopThirdPartyLib != null) runtime fileTree(dir: sqoopThirdPartyLib, include: '*.jar')
     compile group: 'org.apache.hadoop', name: 'hadoop-aws', version: hadoopVersion
     compile (group: 'org.apache.hadoop', name: 'hadoop-common', version: hadoopVersion) {
         exclude group: "asm", module: "asm"
@@ -177,6 +180,8 @@ dependencies {
     testCompile group: 'cubrid', name: 'cubrid-jdbc', version: cubridJdbcDriverVersion
     testCompile group: 'com.microsoft.sqlserver', name: 'mssql-jdbc', version: msSqlJdbcDriverVersion
     testCompile group: 'com.ibm.db2.jcc', name: 'db2jcc4', version: db2JdbcDriverVersion
+    testCompile group: 'oracle', name: 'ojdbc6', version: oracleJdbcDriverVersion
+
 }
 
 task unitTest (type: Test) {

http://git-wip-us.apache.org/repos/asf/sqoop/blob/302674d9/gradle.properties
----------------------------------------------------------------------
diff --git a/gradle.properties b/gradle.properties
index 924ce19..3b3eace 100644
--- a/gradle.properties
+++ b/gradle.properties
@@ -55,6 +55,7 @@ mySqlConnectorVersion=5.1.47
 cubridJdbcDriverVersion=10.1.2.7694
 msSqlJdbcDriverVersion=7.0.0.jre8
 db2JdbcDriverVersion=10.1
+oracleJdbcDriverVersion=11.2.0.3
 
 checkstyleVersion=5.5