hive-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From c..@apache.org
Subject svn commit: r1202443 - /hive/trunk/metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java
Date Tue, 15 Nov 2011 22:08:39 GMT
Author: cws
Date: Tue Nov 15 22:08:38 2011
New Revision: 1202443

URL: http://svn.apache.org/viewvc?rev=1202443&view=rev
Log:
HIVE-2411. Metastore server tries to connect to NN without authenticating itself (Ashutosh
Chauhan via cws)

Modified:
    hive/trunk/metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java

Modified: hive/trunk/metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java
URL: http://svn.apache.org/viewvc/hive/trunk/metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java?rev=1202443&r1=1202442&r2=1202443&view=diff
==============================================================================
--- hive/trunk/metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java (original)
+++ hive/trunk/metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java Tue
Nov 15 22:08:38 2011
@@ -3668,7 +3668,6 @@ public class HiveMetaStore extends Thrif
   public static void startMetaStore(int port, HadoopThriftAuthBridge bridge,
       HiveConf conf) throws Throwable {
     try {
-      HMSHandler handler = new HMSHandler("new db based metaserver", conf);
 
       // Server will create new threads up to max as necessary. After an idle
       // period, it will destory threads to keep the number of threads in the
@@ -3681,7 +3680,7 @@ public class HiveMetaStore extends Thrif
       TServerTransport serverTransport = tcpKeepAlive ?
           new TServerSocketKeepAlive(port) : new TServerSocket(port);
 
-      TProcessor processor = new ThriftHiveMetastore.Processor(handler);
+      TProcessor processor;
       TTransportFactory transFactory;
       if (useSasl) {
          saslServer = bridge.createServer(
@@ -3691,8 +3690,11 @@ public class HiveMetaStore extends Thrif
         // start delegation token manager
         saslServer.startDelegationTokenSecretManager(conf);
         transFactory = saslServer.createTransportFactory();
-        processor = saslServer.wrapProcessor(processor);
+        processor = saslServer.wrapProcessor(new ThriftHiveMetastore.Processor(
+            new HMSHandler("new db based metaserver", conf)));
       } else {
+        processor = new ThriftHiveMetastore.Processor(
+            new HMSHandler("new db based metaserver", conf));
         transFactory = new TTransportFactory();
       }
 



Mime
View raw message