dongjoon-hyun commented on a change in pull request #27349: [SPARK-30617][SQL] 
Stop check values of spark.sql.catalogImplementation to improve expansibility
URL: https://github.com/apache/spark/pull/27349#discussion_r370464970
 
 

 ##########
 File path: sql/core/src/main/scala/org/apache/spark/sql/SparkSession.scala
 ##########
 @@ -1026,6 +1026,12 @@ object SparkSession extends Logging {
     conf.get(CATALOG_IMPLEMENTATION) match {
       case "hive" => HIVE_SESSION_STATE_BUILDER_CLASS_NAME
       case "in-memory" => classOf[SessionStateBuilder].getCanonicalName
+      case other => 
conf.getOption(s"spark.sql.catalogImplementation.$other.builder")
+          .getOrElse {
+        throw new IllegalArgumentException(
+          "You need to configure spark.sql.catalogImplementation.xx.builder 
when xx configured by" +
 
 Review comment:
   The following will be better.
   ```scala
   - "You need to configure spark.sql.catalogImplementation.xx.builder when xx 
configured by" +
   + s"You need to configure spark.sql.catalogImplementation.$other.builder 
when $other configured by" +
   ```

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

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

Reply via email to