jtstorck commented on a change in pull request #4102: NIFI-7025: Adds Kerberos 
Password to Hive/Hive_1_1/Hive3 components
URL: https://github.com/apache/nifi/pull/4102#discussion_r385934166
 
 

 ##########
 File path: 
nifi-nar-bundles/nifi-extension-utils/nifi-hadoop-utils/src/main/java/org/apache/nifi/processors/hadoop/AbstractHadoopProcessor.java
 ##########
 @@ -563,8 +558,8 @@ protected UserGroupInformation getUserGroupInformation() {
     /*
      * Overridable by subclasses in the same package, mainly intended for 
testing purposes to allow verification without having to set environment 
variables.
      */
-    String getAllowExplicitKeytabEnvironmentVariable() {
-        return System.getenv(ALLOW_EXPLICIT_KEYTAB);
+    boolean isAllowExplicitKeytab() {
+        return Boolean.parseBoolean(System.getenv(ALLOW_EXPLICIT_KEYTAB));
 
 Review comment:
   Boolean.parseBoolean(String s) doesn't throw an exception.  It'll return 
false unless the string passed to it, ignoring case, equals "true".  It doesn't 
do any trimming, just takes the given string and evaluates it:
   ```java
       public static boolean parseBoolean(String s) {
           return ((s != null) && s.equalsIgnoreCase("true"));
       }
   ```

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to