veghlaci05 commented on code in PR #3935:
URL: https://github.com/apache/hive/pull/3935#discussion_r1071135779
##########
ql/src/java/org/apache/hadoop/hive/ql/txn/compactor/Worker.java:
##########
@@ -315,10 +315,14 @@ protected Boolean findNextCompactionAndExecute(boolean
collectGenericStats, bool
return false;
}
- if (!ci.type.equals(CompactionType.REBALANCE) && ci.numberOfBuckets > 0)
{
- if (LOG.isWarnEnabled()) {
- LOG.warn("Only the REBALANCE compaction accepts the number of
buckets clause (CLUSTERED INTO {N} BUCKETS). " +
- "Since the compaction request is {}, it will be ignored.",
ci.type);
+ boolean insertOnly = AcidUtils.isInsertOnlyTable(table.getParameters());
+ if (LOG.isWarnEnabled() && ci.type.equals(CompactionType.REBALANCE) &&
insertOnly) {
+ LOG.warn("REBALANCE compaction requested on an insert-only table ({}).
Falling back to MAJOR compaction as " +
+ "REBALANCE compaction is supported only on full-acid tables",
table.getTableName());
+ if (ci.numberOfBuckets > 0) {
Review Comment:
Yes, during the implementation of the insert-only REBALANCE, two things
turned out:
- only in case of full-acid tables were are accepting the number of buckets
- in case of insert-only tables the number of buckets are ignored like for
non REBALANCE compactions, and we are falling back to MM MAJOR compaction.
This logging block has been adjusted to reflect the changes above.
--
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]