Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

track segments for snapshotting even if they lost all comparisons #13388

Merged
merged 3 commits into from
Jun 14, 2024

Conversation

klsince
Copy link
Contributor

@klsince klsince commented Jun 13, 2024

It's possible that docs from a segment lost all comparison with docs from other segments, thus not going to call any of those methods addDocId/replaceDocId where we track segments for snapshotting. So in this PR, we track segments for snapshotting in addSegment/replaceSegment high level entry methods, beside replaceDocId/removeDocId where the existing segments may be updated. This should keep a complete set of segments being updated since last snapshotting.

Also made a fix for another minor bug that some segments were not removed from the track Set after taking snapshot for them.

The batch mode of consistent view feature is also subject to this issue, i.e missing segment that lost all comparison. Will address that in separate RP so that changes can be reverted separately in case.

@codecov-commenter
Copy link

codecov-commenter commented Jun 13, 2024

Codecov Report

Attention: Patch coverage is 50.00000% with 9 lines in your changes missing coverage. Please review.

Project coverage is 62.03%. Comparing base (59551e4) to head (737a901).
Report is 623 commits behind head on master.

Files Patch % Lines
...cal/upsert/BasePartitionUpsertMetadataManager.java 64.28% 3 Missing and 2 partials ⚠️
...che/pinot/plugin/minion/tasks/MinionTaskUtils.java 0.00% 4 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##             master   #13388      +/-   ##
============================================
+ Coverage     61.75%   62.03%   +0.28%     
+ Complexity      207      198       -9     
============================================
  Files          2436     2550     +114     
  Lines        133233   140262    +7029     
  Branches      20636    21799    +1163     
============================================
+ Hits          82274    87014    +4740     
- Misses        44911    46647    +1736     
- Partials       6048     6601     +553     
Flag Coverage Δ
custom-integration1 <0.01% <0.00%> (-0.01%) ⬇️
integration <0.01% <0.00%> (-0.01%) ⬇️
integration1 <0.01% <0.00%> (-0.01%) ⬇️
integration2 0.00% <0.00%> (ø)
java-11 62.00% <50.00%> (+0.29%) ⬆️
java-21 61.91% <50.00%> (+0.29%) ⬆️
skip-bytebuffers-false 62.02% <50.00%> (+0.28%) ⬆️
skip-bytebuffers-true 61.87% <50.00%> (+34.14%) ⬆️
temurin 62.03% <50.00%> (+0.28%) ⬆️
unittests 62.03% <50.00%> (+0.28%) ⬆️
unittests1 46.58% <0.00%> (-0.31%) ⬇️
unittests2 27.69% <50.00%> (-0.04%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

@tibrewalpratik17 tibrewalpratik17 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM overall! Left a nit comment.

@klsince klsince merged commit 830388d into apache:master Jun 14, 2024
20 checks passed
@klsince klsince deleted the fix_missing_snasphot branch June 14, 2024 16:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants