[HUDI-6882] Differentiate between replacecommits in cluster planning#9755
Merged
yihua merged 2 commits intoapache:masterfrom Sep 21, 2023
Merged
[HUDI-6882] Differentiate between replacecommits in cluster planning#9755yihua merged 2 commits intoapache:masterfrom
yihua merged 2 commits intoapache:masterfrom
Conversation
AlexandrKhabarov
approved these changes
Sep 20, 2023
yihua
approved these changes
Sep 20, 2023
...park-datasource/hudi-spark/src/test/scala/org/apache/hudi/functional/TestCOWDataSource.scala
Outdated
Show resolved
Hide resolved
...park-datasource/hudi-spark/src/test/scala/org/apache/hudi/functional/TestCOWDataSource.scala
Show resolved
Hide resolved
yihua
approved these changes
Sep 20, 2023
added 2 commits
September 21, 2023 08:00
b9218ae to
0d495d3
Compare
Collaborator
nsivabalan
pushed a commit
that referenced
this pull request
Nov 21, 2023
…9755) Cluster planning will run clustering every n commits. To do this, it gets the previous clustering instant and then finds the number of commits after that. However, it was finding the previous clustering instant just by finding the latest replacecommit. Replacecommit is also used for insert_overwrite. This commit fixes the logic to check the commit metadata to ensure it is a cluster commit. Co-authored-by: Jonathan Vexler <=>
yihua
reviewed
Mar 22, 2024
| .getReverseOrderedInstants() | ||
| .filter(i -> { | ||
| try { | ||
| HoodieCommitMetadata metadata = TimelineUtils.getCommitMetadata(i, this); |
Contributor
There was a problem hiding this comment.
This introduced a regression that the pending clustering is no longer considered when figuring out the lastClusteringInstant.
4 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Change Logs
Cluster planning will run clustering every n commits. To do this, it gets the previous clustering instant and then finds the number of commits after that. However, it was finding the previous clustering instant just by finding the latest replacecommit. Replacecommit is also used for insert_overwrite. Now we check the commit metadata to ensure it is a cluster commit.
Impact
clustering now works as expected if lots of insert_overwrite is used
Risk level (write none, low medium or high below)
low
Documentation Update
N/A
Contributor's checklist