ranger-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rm...@apache.org
Subject incubator-ranger git commit: RANGER:384 Ranger hive lookup and test connection issue due to hive-jdbc.jar wrong version in ranger admin
Date Mon, 20 Apr 2015 19:51:47 GMT
Repository: incubator-ranger
Updated Branches:
  refs/heads/master da7002470 -> 0f56f8263


RANGER:384 Ranger hive lookup and test connection issue due to hive-jdbc.jar wrong version
in ranger admin


Project: http://git-wip-us.apache.org/repos/asf/incubator-ranger/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-ranger/commit/0f56f826
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ranger/tree/0f56f826
Diff: http://git-wip-us.apache.org/repos/asf/incubator-ranger/diff/0f56f826

Branch: refs/heads/master
Commit: 0f56f8263afae41534456f1733cd2774a3d27140
Parents: da70024
Author: rmani <rmani@hortonworks.com>
Authored: Mon Apr 20 12:51:42 2015 -0700
Committer: rmani <rmani@hortonworks.com>
Committed: Mon Apr 20 12:51:42 2015 -0700

----------------------------------------------------------------------
 hive-agent/pom.xml                                             | 6 ++++++
 .../org/apache/ranger/services/hive/client/HiveClient.java     | 6 ++++++
 .../apache/ranger/services/hive/client/HiveResourceMgr.java    | 4 ++--
 src/main/assembly/admin-web.xml                                | 1 +
 4 files changed, 15 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ranger/blob/0f56f826/hive-agent/pom.xml
----------------------------------------------------------------------
diff --git a/hive-agent/pom.xml b/hive-agent/pom.xml
index 9118f16..2f2e7f8 100644
--- a/hive-agent/pom.xml
+++ b/hive-agent/pom.xml
@@ -102,6 +102,12 @@
 	  <version>${hive.version}</version>
     </dependency>
     <dependency>
+	  <groupId>org.apache.hive</groupId>
+	  <artifactId>hive-jdbc</artifactId>
+	  <version>${hive.version}</version>
+	  <classifier>standalone</classifier>
+    </dependency>
+    <dependency>
 	  <groupId>org.apache.hadoop</groupId>
 	  <artifactId>hadoop-hdfs</artifactId>
 	  <version>${hadoop.version}</version>

http://git-wip-us.apache.org/repos/asf/incubator-ranger/blob/0f56f826/hive-agent/src/main/java/org/apache/ranger/services/hive/client/HiveClient.java
----------------------------------------------------------------------
diff --git a/hive-agent/src/main/java/org/apache/ranger/services/hive/client/HiveClient.java
b/hive-agent/src/main/java/org/apache/ranger/services/hive/client/HiveClient.java
index 15ee2fc..3668eac 100644
--- a/hive-agent/src/main/java/org/apache/ranger/services/hive/client/HiveClient.java
+++ b/hive-agent/src/main/java/org/apache/ranger/services/hive/client/HiveClient.java
@@ -478,6 +478,12 @@ public class HiveClient extends BaseClient implements Closeable {
 			hdpException.generateResponseDataMap(false, getMessage(se), msgDesc
 					+ errMsg, null, null);
 			throw hdpException;
+		} catch ( Throwable t) {
+			String msgDesc = "Unable to connect to Hive Thrift Server instance";
+			HadoopException hdpException = new HadoopException(msgDesc, t);
+			hdpException.generateResponseDataMap(false, getMessage(t),
+					msgDesc + errMsg, null, url);
+		     throw hdpException;
 		}
 	}
 

http://git-wip-us.apache.org/repos/asf/incubator-ranger/blob/0f56f826/hive-agent/src/main/java/org/apache/ranger/services/hive/client/HiveResourceMgr.java
----------------------------------------------------------------------
diff --git a/hive-agent/src/main/java/org/apache/ranger/services/hive/client/HiveResourceMgr.java
b/hive-agent/src/main/java/org/apache/ranger/services/hive/client/HiveResourceMgr.java
index a050f71..98622b0 100644
--- a/hive-agent/src/main/java/org/apache/ranger/services/hive/client/HiveResourceMgr.java
+++ b/hive-agent/src/main/java/org/apache/ranger/services/hive/client/HiveResourceMgr.java
@@ -42,7 +42,7 @@ public class HiveResourceMgr {
 		HashMap<String, Object> ret = null;
 		
 		if(LOG.isDebugEnabled()) {
-			LOG.debug("<== HiveResourceMgr.testConnection ServiceName: "+ serviceName + "Configs"
+ configs ) ;
+			LOG.debug("==> HiveResourceMgr.testConnection ServiceName: "+ serviceName + "Configs"
+ configs ) ;
 		}	
 		
 		try {
@@ -108,7 +108,7 @@ public class HiveResourceMgr {
 			try {
 				
 				if(LOG.isDebugEnabled()) {
-					LOG.debug("<== HiveResourceMgr.getHiveResources() UserInput: "+ userInput  + " configs:
" + configs + " databaseList: "  + databaseList + " tableList: " 
+					LOG.debug("==> HiveResourceMgr.getHiveResources() UserInput: "+ userInput  + " configs:
" + configs + " databaseList: "  + databaseList + " tableList: " 
 																				  + tableList + " columnList: " + columnList ) ;
 				}
 				

http://git-wip-us.apache.org/repos/asf/incubator-ranger/blob/0f56f826/src/main/assembly/admin-web.xml
----------------------------------------------------------------------
diff --git a/src/main/assembly/admin-web.xml b/src/main/assembly/admin-web.xml
index ec47ce4..6e5b3c7 100644
--- a/src/main/assembly/admin-web.xml
+++ b/src/main/assembly/admin-web.xml
@@ -74,6 +74,7 @@
               <include>org.apache.hive:hive-service:jar:${hive.version}</include>
               <include>org.apache.hive:hive-exec:jar:${hive.version}</include>
               <include>org.apache.hive:hive-jdbc:jar:${hive.version}</include>
+              <include>org.apache.hive:hive-jdbc:jar:standalone:${hive.version}</include>
               <include>org.apache.hive:hive-metastore:jar:${hive.version}</include>
             </includes>
           </dependencySet>


Mime
View raw message