hive-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From the...@apache.org
Subject svn commit: r1583225 - /hive/branches/branch-0.13/jdbc/src/java/org/apache/hive/jdbc/HiveConnection.java
Date Sun, 30 Mar 2014 23:45:54 GMT
Author: thejas
Date: Sun Mar 30 23:45:53 2014
New Revision: 1583225

URL: http://svn.apache.org/r1583225
Log:
HIVE-6781 : Hive JDBC in http mode is using HiveConf - should be removed  (Vaibhav Gumashta
via Thejas Nair)

Modified:
    hive/branches/branch-0.13/jdbc/src/java/org/apache/hive/jdbc/HiveConnection.java

Modified: hive/branches/branch-0.13/jdbc/src/java/org/apache/hive/jdbc/HiveConnection.java
URL: http://svn.apache.org/viewvc/hive/branches/branch-0.13/jdbc/src/java/org/apache/hive/jdbc/HiveConnection.java?rev=1583225&r1=1583224&r2=1583225&view=diff
==============================================================================
--- hive/branches/branch-0.13/jdbc/src/java/org/apache/hive/jdbc/HiveConnection.java (original)
+++ hive/branches/branch-0.13/jdbc/src/java/org/apache/hive/jdbc/HiveConnection.java Sun Mar
30 23:45:53 2014
@@ -52,7 +52,6 @@ import javax.security.sasl.SaslException
 
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
-import org.apache.hadoop.hive.conf.HiveConf;
 import org.apache.hadoop.hive.ql.session.SessionState;
 import org.apache.hadoop.hive.shims.ShimLoader;
 import org.apache.hive.service.auth.HiveAuthFactory;
@@ -102,6 +101,8 @@ public class HiveConnection implements j
   private static final String HIVE_USE_SSL = "ssl";
   private static final String HIVE_SSL_TRUST_STORE = "sslTrustStore";
   private static final String HIVE_SSL_TRUST_STORE_PASSWORD = "trustStorePassword";
+  private static final String HIVE_SERVER2_TRANSPORT_MODE = "hive.server2.transport.mode";
+  private static final String HIVE_SERVER2_THRIFT_HTTP_PATH = "hive.server2.thrift.http.path";
   private static final String HIVE_VAR_PREFIX = "hivevar:";
   private static final String HIVE_CONF_PREFIX = "hiveconf:";
   // Currently supports JKS keystore format
@@ -213,8 +214,7 @@ public class HiveConnection implements j
     String schemeName = useSsl ? "https" : "http";
     // http path should begin with "/"
     String httpPath;
-    httpPath = hiveConfMap.get(
-        HiveConf.ConfVars.HIVE_SERVER2_THRIFT_HTTP_PATH.varname);
+    httpPath = hiveConfMap.get(HIVE_SERVER2_THRIFT_HTTP_PATH);
     if(httpPath == null) {
       httpPath = "/";
     }
@@ -478,8 +478,7 @@ public class HiveConnection implements j
   }
 
   private boolean isHttpTransportMode() {
-    String transportMode =
-        hiveConfMap.get(HiveConf.ConfVars.HIVE_SERVER2_TRANSPORT_MODE.varname);
+    String transportMode = hiveConfMap.get(HIVE_SERVER2_TRANSPORT_MODE);
     if(transportMode != null && (transportMode.equalsIgnoreCase("http"))) {
       return true;
     }



Mime
View raw message