[
https://issues.apache.org/jira/browse/HIVE-22383?focusedWorklogId=853814&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-853814
]
ASF GitHub Bot logged work on HIVE-22383:
-----------------------------------------
Author: ASF GitHub Bot
Created on: 30/Mar/23 02:18
Start Date: 30/Mar/23 02:18
Worklog Time Spent: 10m
Work Description: rbalamohan commented on code in PR #4161:
URL: https://github.com/apache/hive/pull/4161#discussion_r1152661303
##########
ql/src/java/org/apache/hadoop/hive/ql/metadata/Hive.java:
##########
@@ -2951,9 +2951,11 @@ private void setStatsPropAndAlterPartitions(boolean
resetStatistics, Table tbl,
validWriteIdList = tableSnapshot.getValidWriteIdList();
writeId = tableSnapshot.getWriteId();
}
- getSynchronizedMSC().alter_partitions(tbl.getCatName(), tbl.getDbName(),
tbl.getTableName(),
-
partitions.stream().map(Partition::getTPartition).collect(Collectors.toList()),
- ec, validWriteIdList, writeId);
+ if (!conf.getBoolVar(ConfVars.HIVESTATSAUTOGATHER)){
Review Comment:
Should this be in the starting of the method itself?
Issue Time Tracking
-------------------
Worklog Id: (was: 853814)
Time Spent: 50m (was: 40m)
> `alterPartitions` is invoked twice during dynamic partition load causing
> runtime delay
> --------------------------------------------------------------------------------------
>
> Key: HIVE-22383
> URL: https://issues.apache.org/jira/browse/HIVE-22383
> Project: Hive
> Issue Type: Bug
> Reporter: Rajesh Balamohan
> Assignee: Dmitriy Fingerman
> Priority: Major
> Labels: performance, pull-request-available
> Time Spent: 50m
> Remaining Estimate: 0h
>
> First invocation in {{Hive::loadDynamicPartitions}}
> https://github.com/apache/hive/blob/master/ql/src/java/org/apache/hadoop/hive/ql/metadata/Hive.java#L2978
> https://github.com/apache/hive/blob/master/ql/src/java/org/apache/hadoop/hive/ql/metadata/Hive.java#L2638
> Second invocation in {{BasicStatsTask::aggregateStats}}
> https://github.com/apache/hive/blob/master/ql/src/java/org/apache/hadoop/hive/ql/stats/BasicStatsTask.java#L335
> This leads to good amount of delay in dynamic partition loading.
>
--
This message was sent by Atlassian Jira
(v8.20.10#820010)