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

    https://github.com/apache/spark/pull/22598#discussion_r221822533
  
    --- Diff: 
core/src/test/scala/org/apache/spark/deploy/security/HadoopDelegationTokenManagerSuite.scala
 ---
    @@ -111,6 +113,17 @@ class HadoopDelegationTokenManagerSuite extends 
SparkFunSuite with Matchers {
         creds.getAllTokens.size should be (0)
       }
     
    +  test("Obtain tokens For Kafka") {
    +    val hadoopConf = new Configuration()
    +    sparkConf.set(KAFKA_DELEGATION_TOKEN_ENABLED, true)
    +
    +    val kafkaTokenProvider = new KafkaDelegationTokenProvider()
    +    val creds = new Credentials()
    +    kafkaTokenProvider.obtainDelegationTokens(hadoopConf, sparkConf, creds)
    +
    +    creds.getAllTokens.size should be (0)
    --- End diff --
    
    I see. Unfortunately this way this test has not much value as in 
obtainDelegationTokens an exception is thrown when the loadclass is called with 
"org.apache.spark.sql.kafka010.TokenUtil". But as this is quite the same for 
HBase you can keep it. 


---

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

Reply via email to