rdblue commented on code in PR #9585:
URL: https://github.com/apache/iceberg/pull/9585#discussion_r1477126737


##########
docs/java-api-quickstart.md:
##########
@@ -38,37 +38,42 @@ The Hive catalog connects to a Hive metastore to keep track 
of Iceberg tables.
 You can initialize a Hive catalog with a name and some properties.
 (see: [Catalog properties](../configuration/#catalog-properties))
 
-**Note:** Currently, `setConf` is always required for hive catalogs, but this 
will change in the future.
+### Using a Hive catalog
+
+The Hive catalog connects to a Hive metastore to keep track of Iceberg tables.
+You can initialize a Hive catalog with a name and some properties.
+(see: [Catalog properties](../configuration/#catalog-properties))
 
 ```java
+import java.util.HashMap
+import java.util.Map
+
 import org.apache.iceberg.hive.HiveCatalog;
 
 HiveCatalog catalog = new HiveCatalog();
-catalog.setConf(spark.sparkContext().hadoopConfiguration());  // Configure 
using Spark's Hadoop configuration
 
 Map <String, String> properties = new HashMap<String, String>();
-properties.put("warehouse", "...");
-properties.put("uri", "...");
+properties.put("warehouse", "..."); // Override hive.metastore.warehouse.dir
+properties.put("uri", "..."); // Override hive.metastore.uris
 
-catalog.initialize("hive", properties);
+catalog.initialize("hive", properties); // Load default Hadoop and Hive 
configurations, and apply properties

Review Comment:
   We should not recommend loading "default" configurations, so I think the 
`setConf` line should be brought back and this comment removed.



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