pvary commented on a change in pull request #3131:
URL: https://github.com/apache/hive/pull/3131#discussion_r840383938



##########
File path: 
iceberg/iceberg-handler/src/main/java/org/apache/iceberg/mr/hive/HiveIcebergStorageHandler.java
##########
@@ -198,7 +206,10 @@ public void configureInputJobCredentials(TableDesc 
tableDesc, Map<String, String
   public void configureJobConf(TableDesc tableDesc, JobConf jobConf) {
     setCommonJobConf(jobConf);
     if (tableDesc != null && tableDesc.getProperties() != null &&
-        tableDesc.getProperties().get(WRITE_KEY) != null) {
+        tableDesc.getProperties().get(InputFormatConfig.OPERATION_TYPE_PREFIX 
+ tableDesc.getTableName()) != null) {
+      // set operation type into job conf too
+      jobConf.set(InputFormatConfig.OPERATION_TYPE_PREFIX + 
tableDesc.getTableName(),
+          
tableDesc.getProperties().getProperty(InputFormatConfig.OPERATION_TYPE_PREFIX + 
tableDesc.getTableName()));

Review comment:
       nit: Maybe just here, but it took me some time to put together what is 
this :)
   Basically:
   ```
   String key = InputFormatConfig.OPERATION_TYPE_PREFIX + 
tableDesc.getTableName();
   if (tableDesc.getProperties().get(key) != null) {
     jobConf.set(key, tableDesc.getProperties().get(key));
   ```




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