youngxinler commented on code in PR #6886:
URL: https://github.com/apache/iceberg/pull/6886#discussion_r1172155596


##########
spark/v3.3/spark/src/main/java/org/apache/iceberg/spark/SparkCatalog.java:
##########
@@ -132,6 +132,9 @@ protected Catalog buildIcebergCatalog(String name, 
CaseInsensitiveStringMap opti
     optionsMap.putAll(options.asCaseSensitiveMap());
     optionsMap.put(CatalogProperties.APP_ID, 
SparkSession.active().sparkContext().applicationId());
     optionsMap.put(CatalogProperties.USER, 
SparkSession.active().sparkContext().sparkUser());
+    optionsMap.putIfAbsent(
+        CatalogProperties.WAREHOUSE_LOCATION,
+        SparkSession.active().sqlContext().conf().warehousePath());

Review Comment:
   HiveCatalog will use CatalogProperties.WAREHOUSE_LOCATION to set to 
HiveConf.ConfVars.METASTOREWAREHOUSE.varname during initialization, so I think 
it is better to use CatalogProperties.WAREHOUSE_LOCATION here.



-- 
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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


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

Reply via email to