Reduce metadata IO during segment allocation#17496
Merged
kfaraz merged 5 commits intoapache:masterfrom Nov 26, 2024
Merged
Conversation
cryptoe
reviewed
Nov 22, 2024
| private long batchAllocationWaitTime = 0L; | ||
|
|
||
| @JsonProperty | ||
| private boolean batchAllocationReduceMetadataIO = false; |
Contributor
There was a problem hiding this comment.
Should this be always on and then we remove this config in next release ?
Contributor
Author
There was a problem hiding this comment.
Yeah, I guess the changes are safe enough. We can always keep it on. Let me try to run ITs with it turned on.
Contributor
Author
There was a problem hiding this comment.
Flag has been set to true by default.
cryptoe
approved these changes
Nov 25, 2024
AmatyaAvadhanula
approved these changes
Nov 26, 2024
Contributor
Author
|
Thanks for the reviews, @AmatyaAvadhanula , @cryptoe ! |
gianm
reviewed
Dec 4, 2024
| = versionIntervalToSmallestSegmentId.computeIfAbsent(segmentId.getVersion(), v -> new HashMap<>()); | ||
| final SegmentId value = map.get(segmentId.getInterval()); | ||
| if (value == null || value.getPartitionNum() > segmentId.getPartitionNum()) { | ||
| map.put(interval, segmentId); |
10 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.
Revives #17420
Description
The changes here try to reduce metadata IO during segment allocation by fetching segment payloads
for only the required segments. For other segments, only fetching the segment ID suffices.
Changes
druid.indexer.tasklock.batchAllocationReduceMetadataIO.Release note
Add Overlord runtime property
druid.indexer.tasklock.batchAllocationReduceMetadataIO.Setting this flag to true (default value) allows the Overlord to fetch only necessary segment payloads during segment allocation.
This PR has: