ranger-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mad...@apache.org
Subject [2/3] git commit: - fix log level
Date Fri, 22 Aug 2014 07:20:05 GMT
- fix log level

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

Branch: refs/heads/master
Commit: 77245582fd69af6b064f2b9b4fed286a4a249580
Parents: 2c56c56
Author: mneethiraj <mneethiraj@hortonworks.com>
Authored: Thu Aug 21 20:11:02 2014 -0700
Committer: mneethiraj <mneethiraj@hortonworks.com>
Committed: Thu Aug 21 20:11:02 2014 -0700

----------------------------------------------------------------------
 .../hive/authorizer/XaSecureHiveAuthorizer.java      | 15 ++++++++++-----
 1 file changed, 10 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-argus/blob/77245582/hive-agent/src/main/java/com/xasecure/authorization/hive/authorizer/XaSecureHiveAuthorizer.java
----------------------------------------------------------------------
diff --git a/hive-agent/src/main/java/com/xasecure/authorization/hive/authorizer/XaSecureHiveAuthorizer.java
b/hive-agent/src/main/java/com/xasecure/authorization/hive/authorizer/XaSecureHiveAuthorizer.java
index cbdccb2..a09b372 100644
--- a/hive-agent/src/main/java/com/xasecure/authorization/hive/authorizer/XaSecureHiveAuthorizer.java
+++ b/hive-agent/src/main/java/com/xasecure/authorization/hive/authorizer/XaSecureHiveAuthorizer.java
@@ -89,7 +89,9 @@ public class XaSecureHiveAuthorizer extends XaSecureHiveAuthorizerBase {
 		try {
 			GrantRevokeData grData = createGrantRevokeData(objAccessInfo, hivePrincipals, hivePrivileges,
grantorPrincipal, grantOption);
 
-			LOG.warn("grantPrivileges(): " + grData.toJson());
+			if(LOG.isDebugEnabled()) {
+				LOG.debug("grantPrivileges(): " + grData.toJson());
+			}
 
 			XaAdminRESTClient xaAdmin = new XaAdminRESTClient();
 
@@ -101,7 +103,8 @@ public class XaSecureHiveAuthorizer extends XaSecureHiveAuthorizerBase
{
 		} finally {
 			if(mHiveAccessVerifier.isAudited(objAccessInfo)) {
 				UserGroupInformation ugi = this.getCurrentUserGroupInfo();
-	
+
+				// Note: failed return from REST call will be logged as 'DENIED'
 				logAuditEvent(ugi, objAccessInfo, isSuccess);
 			}
 		}
@@ -134,7 +137,9 @@ public class XaSecureHiveAuthorizer extends XaSecureHiveAuthorizerBase
{
 		try {
 			GrantRevokeData grData = createGrantRevokeData(objAccessInfo, hivePrincipals, hivePrivileges,
grantorPrincipal, grantOption);
 
-			LOG.warn("revokePrivileges(): " + grData.toJson());
+			if(LOG.isDebugEnabled()) {
+				LOG.debug("revokePrivileges(): " + grData.toJson());
+			}
 
 			XaAdminRESTClient xaAdmin = new XaAdminRESTClient();
 
@@ -146,8 +151,8 @@ public class XaSecureHiveAuthorizer extends XaSecureHiveAuthorizerBase
{
 		} finally {
 			if(mHiveAccessVerifier.isAudited(objAccessInfo)) {
 				UserGroupInformation ugi = this.getCurrentUserGroupInfo();
-	
-				// failed return from REST calls will be logged as 'DENIED'
+
+				// Note: failed return from REST call will be logged as 'DENIED'
 				logAuditEvent(ugi, objAccessInfo, isSuccess);
 			}
 		}


Mime
View raw message