dailidong commented on issue #2223: [BUG] Throw exception when create file.
URL: 
https://github.com/apache/incubator-dolphinscheduler/issues/2223#issuecomment-612098150
 
 
   you can see the code HadoopUtils.java 
   
   init method:
   
   ```
                              if (fs == null) {
                                   if(StringUtils.isNotEmpty(hdfsUser)){
                                       //UserGroupInformation ugi = 
UserGroupInformation.createProxyUser(hdfsUser,UserGroupInformation.getLoginUser());
                                       UserGroupInformation ugi = 
UserGroupInformation.createRemoteUser(hdfsUser);
                                       ugi.doAs(new 
PrivilegedExceptionAction<Boolean>() {
                                           @Override
                                           public Boolean run() throws 
Exception {
                                               fs = 
FileSystem.get(configuration);
                                               return true;
                                           }
                                       });
                                   }else{
                                       logger.warn("hdfs.root.user is not set 
value!");
                                       fs = FileSystem.get(configuration);
                                   }
                               }
   ```

----------------------------------------------------------------
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