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

    https://github.com/apache/spark/pull/21396#discussion_r190100259
  
    --- Diff: 
core/src/main/scala/org/apache/spark/deploy/security/HiveDelegationTokenProvider.scala
 ---
    @@ -85,7 +85,10 @@ private[spark] class HiveDelegationTokenProvider
           val principal = conf.getTrimmed(principalKey, "")
           require(principal.nonEmpty, s"Hive principal $principalKey 
undefined")
           val metastoreUri = conf.getTrimmed("hive.metastore.uris", "")
    -      require(metastoreUri.nonEmpty, "Hive metastore uri undefined")
    +      if (metastoreUri.isEmpty) {
    --- End diff --
    
    require() will throws IllegalArgumentException and exits the JVM here. 
Letting `delegationTokensRequired` return when metastoreUri is undefined (using 
JDBC to connect DB directly) only finishes this method (not set token in 
Credentials).


---

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org

Reply via email to