viirya commented on a change in pull request #23499: [SPARK-26254][CORE] Extract Hive + Kafka dependencies from Core. URL: https://github.com/apache/spark/pull/23499#discussion_r249412644
########## File path: core/src/main/scala/org/apache/spark/deploy/security/HadoopDelegationTokenManager.scala ########## @@ -244,29 +247,24 @@ private[spark] class HadoopDelegationTokenManager( } private def loadProviders(): Map[String, HadoopDelegationTokenProvider] = { - val providers = Seq( - new HadoopFSDelegationTokenProvider( - () => HadoopDelegationTokenManager.this.fileSystemsToAccess())) ++ - safeCreateProvider(new HiveDelegationTokenProvider) ++ - safeCreateProvider(new HBaseDelegationTokenProvider) ++ - safeCreateProvider(new KafkaDelegationTokenProvider) + val loader = ServiceLoader.load(classOf[HadoopDelegationTokenProvider], + Utils.getContextOrSparkClassLoader) + var providers = mutable.ArrayBuffer[HadoopDelegationTokenProvider]() Review comment: `var` -> `val`? ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org