difin commented on code in PR #4645:
URL: https://github.com/apache/hive/pull/4645#discussion_r1314963426


##########
iceberg/iceberg-handler/src/main/java/org/apache/iceberg/mr/InputFormatConfig.java:
##########
@@ -85,6 +85,7 @@ private InputFormatConfig() {
   public static final String CATALOG_WAREHOUSE_TEMPLATE = 
"iceberg.catalog.%s.warehouse";
   public static final String CATALOG_CLASS_TEMPLATE = 
"iceberg.catalog.%s.catalog-impl";
   public static final String CATALOG_DEFAULT_CONFIG_PREFIX = 
"iceberg.catalog-default.";
+  public static final String SERIALIZED_TABLE = "serialized.table";

Review Comment:
   fixed



##########
iceberg/iceberg-handler/src/main/java/org/apache/iceberg/mr/hive/HiveIcebergInputFormat.java:
##########
@@ -136,7 +139,10 @@ public InputSplit[] getSplits(JobConf job, int numSplits) 
throws IOException {
     if (filter != null) {
       job.set(InputFormatConfig.FILTER_EXPRESSION, 
SerializationUtil.serializeToBase64(filter));
     }
-
+    Table table = Optional
+            .ofNullable(HiveIcebergStorageHandler.table(job, 
job.get(InputFormatConfig.TABLE_IDENTIFIER)))
+            .orElseGet(() -> Catalogs.loadTable(job));
+    job.set(InputFormatConfig.SERIALIZED_TABLE, 
SerializationUtil.serializeToBase64(table));

Review Comment:
   done



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