You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2021/04/28 09:23:44 UTC

[GitHub] [spark] yaooqinn commented on a change in pull request #32364: [SPARK-35242][SQL] Support change catalog default database for spark

yaooqinn commented on a change in pull request #32364:
URL: https://github.com/apache/spark/pull/32364#discussion_r621989624



##########
File path: sql/catalyst/src/main/scala/org/apache/spark/sql/internal/StaticSQLConf.scala
##########
@@ -37,6 +37,12 @@ object StaticSQLConf {
     .stringConf
     .createWithDefault(Utils.resolveURI("spark-warehouse").toString)
 
+  val CATALOG_DEFAULT_DATABASE = buildStaticConf("spark.sql.catalog.default.database")
+    .doc("The default database for session catalog.")
+    .version("3.2.0")
+    .stringConf
+    .createWithDefault("default")

Review comment:
       Can we test this in `CliSuite`? AFAIK, spark actually never got a chance to create the default database if not exists, which will be done during hive metastore client initialization. If it is configured to `default2` for example, Spark now will get the opportunity to create and there might be 2 default databases then.




-- 
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:
users@infra.apache.org



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