You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ranger.apache.org by rm...@apache.org on 2015/04/07 08:15:26 UTC

incubator-ranger git commit: BUG-33608:Make serviceType case insensitive for REST APIs

Repository: incubator-ranger
Updated Branches:
  refs/heads/master 931315383 -> 0ea6b16a2


BUG-33608:Make serviceType case insensitive for REST APIs


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

Branch: refs/heads/master
Commit: 0ea6b16a281d5aa14383eb3921c268ee18abacde
Parents: 9313153
Author: Gautam Borad <gb...@gmail.com>
Authored: Tue Apr 7 11:37:43 2015 +0530
Committer: rmani <rm...@hortonworks.com>
Committed: Mon Apr 6 23:15:12 2015 -0700

----------------------------------------------------------------------
 .../src/main/java/org/apache/ranger/common/ServiceUtil.java   | 7 ++++++-
 .../src/main/resources/conf.dist/xa_system.properties         | 1 +
 2 files changed, 7 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ranger/blob/0ea6b16a/security-admin/src/main/java/org/apache/ranger/common/ServiceUtil.java
----------------------------------------------------------------------
diff --git a/security-admin/src/main/java/org/apache/ranger/common/ServiceUtil.java b/security-admin/src/main/java/org/apache/ranger/common/ServiceUtil.java
index c6da757..19d320c 100644
--- a/security-admin/src/main/java/org/apache/ranger/common/ServiceUtil.java
+++ b/security-admin/src/main/java/org/apache/ranger/common/ServiceUtil.java
@@ -367,7 +367,12 @@ public class ServiceUtil {
 	}
 
 	public static Integer toAssetType(String serviceType) {
-		Integer ret = mapServiceTypeToAssetType.get(serviceType);
+		
+		if(serviceType == null) {
+			return null;
+		}
+		
+		Integer ret = mapServiceTypeToAssetType.get(serviceType.toLowerCase());
 
 		return ret;
 	}

http://git-wip-us.apache.org/repos/asf/incubator-ranger/blob/0ea6b16a/security-admin/src/main/resources/conf.dist/xa_system.properties
----------------------------------------------------------------------
diff --git a/security-admin/src/main/resources/conf.dist/xa_system.properties b/security-admin/src/main/resources/conf.dist/xa_system.properties
index dac7c2d..2f41e7c 100644
--- a/security-admin/src/main/resources/conf.dist/xa_system.properties
+++ b/security-admin/src/main/resources/conf.dist/xa_system.properties
@@ -44,6 +44,7 @@ xa.logs.base.dir=user.home
 xa.scheduler.enabled=true
 
 xa.audit.store=db
+xa.audit.solr.url=
 
 # DB Info for audit_DB
 auditDB.jdbc.dialect=org.eclipse.persistence.platform.database.MySQLPlatform