rdblue commented on a change in pull request #416: Adding docs on how to use 
custom catalog with iceberg
URL: https://github.com/apache/incubator-iceberg/pull/416#discussion_r317823840
 
 

 ##########
 File path: site/docs/custom-catalog.md
 ##########
 @@ -0,0 +1,134 @@
+# Custom Catalog Implementation
+
+It's possible to read an iceberg table either from an hdfs path or from a hive 
table. It's also possible to use a custom metastore in place of hive. The steps 
to do that are as follows.
+
+- [Custom TableOperations](#custom-table-operations-implementation)
+- [Custom Catalog](#custom-table-implementation)
+- [Custom IcebergSource](#custom-icebergsource)
+
+### Custom table operations implementation
+Extend `BaseMetastoreTableOperations` to provide implementation on how to read 
and write metadata
+
+Example:
+```java
+class CustomTableOperations extends BaseMetastoreTableOperations {
+  private String dbName;
+  private String tableName;
+  private Configuration conf;
+
+  protected CustomTableOperations(Configuration conf, String dbName, String 
tableName) {
 
 Review comment:
   `BaseMetastoreTableOperations` was recently refactored to avoid passing a 
Hadoop `Configuration`. So now this also requires implementing `io` to return a 
`HadoopFileIO`, like this: 
https://github.com/apache/incubator-iceberg/blob/master/hive/src/main/java/org/apache/iceberg/hive/HiveTableOperations.java#L79-L85

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


With regards,
Apache Git Services

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

Reply via email to