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

    https://github.com/apache/spark/pull/9168#discussion_r42392020
  
    --- Diff: core/src/main/scala/org/apache/spark/deploy/SparkHadoopUtil.scala 
---
    @@ -130,6 +132,20 @@ class SparkHadoopUtil extends Logging {
         UserGroupInformation.loginUserFromKeytab(principalName, keytabFilename)
       }
     
    +  def updateCurrentUserHDFSDelegationToken(): Unit = {
    +    val conf = new Configuration()
    +    val nsId = DFSUtil.getNamenodeNameServiceId(conf)
    +    val isHaEnabled = HAUtil.isHAEnabled(conf, nsId)
    +
    +    if(isHaEnabled){
    +      val ugi = UserGroupInformation.getCurrentUser
    +      val uri = FileSystem.getDefaultUri(conf)
    +      val map = DFSUtil.getHaNnRpcAddresses(conf)
    --- End diff --
    
    I'd try and avoid this class if possible. It is tagged as `@Private` in 
hadoop, and in hadoop 2.8 it'll remain in the larger hadoop-hdfs JAR, not the 
leaner client-side hadoop-hdfs-client JAR. The method isn't going away, and 
there will be a {{DFSUtilClient}} where it will move to -but that doesn't help 
current code.
    
    If it can't be avoided, then the HDFS team will need to be kept up to date 
with its use and so encouraged not to break things


---
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 [email protected] or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to