deniskuzZ commented on code in PR #5789:
URL: https://github.com/apache/hive/pull/5789#discussion_r2080077930


##########
iceberg/iceberg-handler/src/main/java/org/apache/iceberg/mr/hive/HiveIcebergStorageHandler.java:
##########
@@ -921,7 +921,8 @@ public DynamicPartitionCtx createDPContext(
     List<Function<List<ExprNodeDesc>, ExprNodeDesc>> customSortExprs = 
Lists.newLinkedList();
     dpCtx.setCustomSortExpressions(customSortExprs);
 
-    if (table.spec().isPartitioned()) {
+    if (table.spec().isPartitioned() &&
+          
hiveConf.getIntVar(ConfVars.HIVE_OPT_SORT_DYNAMIC_PARTITION_THRESHOLD) == 1) {

Review Comment:
   `HIVE_OPT_SORT_DYNAMIC_PARTITION_THRESHOLD` supports the flexibility
   1) -1 ,1 is static, used to turn on/off the optimization
   2) 0, however, does the decision based on 
`SortedDynPartitionOptimizer#shouldDo`, however, it's not yet adopted for 
iceberg



-- 
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: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


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

Reply via email to