Github user satishd commented on a diff in the pull request:

    https://github.com/apache/storm/pull/1351#discussion_r60524577
  
    --- Diff: 
external/storm-hdfs/src/main/java/org/apache/storm/hdfs/common/security/HdfsSecurityUtil.java
 ---
    @@ -40,23 +41,27 @@
         public static final String STORM_USER_NAME_KEY = 
"hdfs.kerberos.principal";
     
         private static final Logger LOG = 
LoggerFactory.getLogger(HdfsSecurityUtil.class);
    -
    +    private static AtomicBoolean isLoggedIn = new AtomicBoolean();
         public static void login(Map conf, Configuration hdfsConfig) throws 
IOException {
             //If AutoHDFS is specified, do not attempt to login using keytabs, 
only kept for backward compatibility.
             if(conf.get(TOPOLOGY_AUTO_CREDENTIALS) == null ||
                     
(!(((List)conf.get(TOPOLOGY_AUTO_CREDENTIALS)).contains(AutoHDFS.class.getName()))
 &&
                      
!(((List)conf.get(TOPOLOGY_AUTO_CREDENTIALS)).contains(AutoTGT.class.getName()))))
 {
                 if (UserGroupInformation.isSecurityEnabled()) {
    -                LOG.info("Logging in using keytab as AutoHDFS is not 
specified for " + TOPOLOGY_AUTO_CREDENTIALS);
    -                String keytab = (String) conf.get(STORM_KEYTAB_FILE_KEY);
    -                if (keytab != null) {
    -                    hdfsConfig.set(STORM_KEYTAB_FILE_KEY, keytab);
    -                }
    -                String userName = (String) conf.get(STORM_USER_NAME_KEY);
    -                if (userName != null) {
    -                    hdfsConfig.set(STORM_USER_NAME_KEY, userName);
    +                // compareAndSet added because of 
https://issues.apache.org/jira/browse/STORM-1535
    +                // need to test it first during ERIE release testing since 
the JIRA says "might" be and port it to apache.
    --- End diff --
    
    @priyank5485 You may want to remove this comment as it is not valid here in 
apache repo.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

Reply via email to