kumaab commented on code in PR #439:
URL: https://github.com/apache/ranger/pull/439#discussion_r1877257374


##########
agents-audit/src/main/java/org/apache/ranger/audit/utils/InMemoryJAASConfiguration.java:
##########
@@ -247,21 +237,20 @@ private void initialize(Properties properties) {
             }
         }
 
-        for(String jaasClient : jaasClients.keySet()) {
-            for(Integer index :  jaasClients.get(jaasClient)) {
+        for (String jaasClient : jaasClients.keySet()) {
+            for (Integer index : jaasClients.get(jaasClient)) {
                 String keyPrefix = JAAS_CONFIG_PREFIX_PARAM + jaasClient + ".";
 
                 if (index > -1) {
-                    keyPrefix = keyPrefix  + String.valueOf(index) + ".";
+                    keyPrefix = keyPrefix + index + ".";
                 }
 
                 String keyParam        = keyPrefix + 
JAAS_CONFIG_LOGIN_MODULE_NAME_PARAM;
                 String loginModuleName = properties.getProperty(keyParam);
 
                 if (loginModuleName == null) {
-                    LOG.error("Unable to add JAAS configuration for "
-                            + "client [" + jaasClient + "] as it is missing 
param [" + keyParam + "]."
-                            + " Skipping JAAS config for [" + jaasClient + 
"]");
+                    LOG.error("Unable to add JAAS configuration for " + 
"client [{}] as it is missing param [{}]." + " Skipping JAAS config for [{}]", 
jaasClient, keyParam, jaasClient);

Review Comment:
   nit: the sentences can be combined.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscr...@ranger.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to