sqoop-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jar...@apache.org
Subject sqoop git commit: SQOOP-1567: Auto-Configure JTDS Driver From JDBCUrl
Date Wed, 19 Nov 2014 18:07:11 GMT
Repository: sqoop
Updated Branches:
  refs/heads/trunk bcefb9227 -> 8704ff260


SQOOP-1567: Auto-Configure JTDS Driver From JDBCUrl

(Nick White via Jarek Jarcec Cecho)


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

Branch: refs/heads/trunk
Commit: 8704ff2607f11a0d570dc82257aea63312af8c16
Parents: bcefb92
Author: Jarek Jarcec Cecho <jarcec@apache.org>
Authored: Wed Nov 19 10:06:41 2014 -0800
Committer: Jarek Jarcec Cecho <jarcec@apache.org>
Committed: Wed Nov 19 10:06:41 2014 -0800

----------------------------------------------------------------------
 src/java/org/apache/sqoop/manager/DefaultManagerFactory.java | 4 ++++
 src/java/org/apache/sqoop/manager/SQLServerManager.java      | 6 +++++-
 2 files changed, 9 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/sqoop/blob/8704ff26/src/java/org/apache/sqoop/manager/DefaultManagerFactory.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/sqoop/manager/DefaultManagerFactory.java b/src/java/org/apache/sqoop/manager/DefaultManagerFactory.java
index 5400c43..58ff745 100644
--- a/src/java/org/apache/sqoop/manager/DefaultManagerFactory.java
+++ b/src/java/org/apache/sqoop/manager/DefaultManagerFactory.java
@@ -66,6 +66,10 @@ public class DefaultManagerFactory
       return new OracleManager(options);
     } else if (scheme.startsWith("jdbc:sqlserver:")) {
       return new SQLServerManager(options);
+    } else if (scheme.startsWith("jdbc:jtds:sqlserver:")) {
+      return new SQLServerManager(
+        "net.sourceforge.jtds.jdbc.Driver",
+        options);
     } else if (scheme.startsWith("jdbc:db2:")) {
       return new Db2Manager(options);
     } else if (scheme.startsWith("jdbc:netezza:")) {

http://git-wip-us.apache.org/repos/asf/sqoop/blob/8704ff26/src/java/org/apache/sqoop/manager/SQLServerManager.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/sqoop/manager/SQLServerManager.java b/src/java/org/apache/sqoop/manager/SQLServerManager.java
index 60d380e..9a3d918 100644
--- a/src/java/org/apache/sqoop/manager/SQLServerManager.java
+++ b/src/java/org/apache/sqoop/manager/SQLServerManager.java
@@ -91,7 +91,11 @@ public class SQLServerManager
   private boolean identityInserts;
 
   public SQLServerManager(final SqoopOptions opts) {
-    super(DRIVER_CLASS, opts);
+    this(DRIVER_CLASS, opts);
+  }
+
+  public SQLServerManager(final String driver, final SqoopOptions opts) {
+    super(driver, opts);
 
     // Try to parse extra arguments
     try {


Mime
View raw message