Ankita Sinha created RANGER-3625: ------------------------------------ Summary: Update isDebugEnable condition in RangerHiveAuthorizer Key: RANGER-3625 URL: https://issues.apache.org/jira/browse/RANGER-3625 Project: Ranger Issue Type: Bug Components: Ranger Affects Versions: 2.2.0 Reporter: Ankita Sinha Assignee: Ankita Sinha
{+}_Problem Statement_{+}: In RangerHiveAuthorizer, the Logger isDebugEnabled condition needs to be updated {code:java} else if (!result.getIsAllowed()) { if (!LOG.isDebugEnabled()) { String path = resource.getAsString(); LOG.debug(String.format("filterListCmdObjects: Permission denied: user [%s] does not have [%s] privilege on [%s]. resource[%s], request[%s], result[%s]", user, request.getHiveAccessType().name(), path, resource, request, result)); } {code} here in above code the condition check is "!LOG.isDebugEnabled()" and log is logged at Debug level which will never get log. {+}_Solution_{+}: The condition "{*}if (!LOG.isDebugEnabled()){*}" should be replaced by *"if (LOG.isDebugEnabled())"* -- This message was sent by Atlassian Jira (v8.20.1#820001)