Uploaded image for project: 'Hadoop Common'
  1. Hadoop Common
  2. HADOOP-17971

Exclude IBM Java security classes from being shaded/relocated

    XMLWordPrintableJSON

Details

    Description

      IBM Java classes are shaded in Hadoop libraries, e.g. hadoop-client-api. When loaded by Spark, UserGroupInformation has exception:

      org.apache.hadoop.security.KerberosAuthException: failure to login: javax.security.auth.login.LoginException: unable to find LoginModule class: org.apache.hadoop.shaded.com.ibm.security.auth.module.JAASLoginModule
      	at org.apache.hadoop.security.UserGroupInformation.doSubjectLogin(UserGroupInformation.java:1986)
      	at org.apache.hadoop.security.UserGroupInformation.createLoginUser(UserGroupInformation.java:719)
      	at org.apache.hadoop.security.UserGroupInformation.getLoginUser(UserGroupInformation.java:669)
      	at org.apache.hadoop.security.UserGroupInformation.getCurrentUser(UserGroupInformation.java:579)
      	at org.apache.spark.util.Utils$.$anonfun$getCurrentUserName$1(Utils.scala:2609)
      	at org.apache.spark.util.Utils$$$Lambda$1388/0x00000000338e9c30.apply(Unknown Source)
      	at scala.Option.getOrElse(Option.scala:189)
      

      When I manually compile UserGroupInformation.java without maven (aka relocation) and inject the class files into hadoop-client-api jar; it works.

       

      Attachments

        Issue Links

          Activity

            People

              nmarion Nicholas Marion
              nmarion Nicholas Marion
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 0.5h
                  0.5h