[
https://issues.apache.org/jira/browse/HIVE-26443?focusedWorklogId=806308&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-806308
]
ASF GitHub Bot logged work on HIVE-26443:
-----------------------------------------
Author: ASF GitHub Bot
Created on: 06/Sep/22 08:58
Start Date: 06/Sep/22 08:58
Worklog Time Spent: 10m
Work Description: deniskuzZ commented on code in PR #3513:
URL: https://github.com/apache/hive/pull/3513#discussion_r963446189
##########
ql/src/java/org/apache/hadoop/hive/ql/txn/compactor/Initiator.java:
##########
@@ -259,15 +268,32 @@ private void scheduleCompactionIfRequired(CompactionInfo
ci, Table t, Partition
}
}
- private Table resolveTableAndCache(CompactionInfo ci) throws MetaException {
- if (tableCache.isPresent()) {
+ private String getPoolName(CompactionInfo ci, Table t) throws Exception {
+ String poolName =
t.getParameters().get(Constants.HIVE_COMPACTOR_WORKER_POOL);
+ if (StringUtils.isBlank(poolName)) {
+ poolName = obtainObject(ci.dbname, () ->
resolveDatabase(ci)).getParameters().get(Constants.HIVE_COMPACTOR_WORKER_POOL);
+ }
+ return poolName;
+ }
+
+ private <T extends TBase<T,?>> T obtainObject(String key, Callable<T>
callable) throws Exception {
Review Comment:
computeIfAbsent()?
Issue Time Tracking
-------------------
Worklog Id: (was: 806308)
Time Spent: 13h 50m (was: 13h 40m)
> Add priority queueing to compaction
> -----------------------------------
>
> Key: HIVE-26443
> URL: https://issues.apache.org/jira/browse/HIVE-26443
> Project: Hive
> Issue Type: New Feature
> Reporter: László Végh
> Assignee: László Végh
> Priority: Major
> Labels: pull-request-available
> Attachments: Pool based compaction queues.docx
>
> Time Spent: 13h 50m
> Remaining Estimate: 0h
>
> The details can be found in the attached design doc.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)