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

[ISSUE #7345] Fix wrong result of searchOffset in tiered storage #7346

Merged
merged 1 commit into from
Sep 12, 2023

Conversation

yuz10
Copy link
Member

@yuz10 yuz10 commented Sep 11, 2023

Which Issue(s) This PR Fixes

Fixes #7345

Brief Description

How Did You Test This Change?

@codecov-commenter
Copy link

Codecov Report

Merging #7346 (96e26a5) into develop (57f04c9) will decrease coverage by 0.05%.
The diff coverage is 100.00%.

@@              Coverage Diff              @@
##             develop    #7346      +/-   ##
=============================================
- Coverage      42.65%   42.61%   -0.05%     
+ Complexity      9473     9456      -17     
=============================================
  Files           1150     1150              
  Lines          82754    82756       +2     
  Branches       10789    10790       +1     
=============================================
- Hits           35300    35265      -35     
- Misses         43043    43074      +31     
- Partials        4411     4417       +6     
Files Changed Coverage Δ
...ache/rocketmq/tieredstore/file/TieredFlatFile.java 78.54% <100.00%> (+0.13%) ⬆️

... and 28 files with indirect coverage changes

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

return fileSegmentList.isEmpty() ? null : fileSegmentList.get(fileSegmentList.size() - 1);
if (fileSegmentList.isEmpty()) {
return null;
}
Copy link
Contributor

Choose a reason for hiding this comment

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

fileSegmentList并非排序过滤后的,segmentList才是

Copy link
Member Author

Choose a reason for hiding this comment

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

这里应该是排序好了的,segmentList为空才走到这里

Copy link
Contributor

Choose a reason for hiding this comment

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

在这个上下文中我没有看到fileSegmentList排序的依据,辛苦贴一下相关代码位置

Copy link
Member

Choose a reason for hiding this comment

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

他是按照 base offset 来排序的

@lizhimins lizhimins changed the title [ISSUE #7345] fix wrong result of searchOffset in tiered storage [ISSUE #7345] Fix wrong result of searchOffset in tiered storage Sep 12, 2023
@lizhimins lizhimins merged commit 1a8e7cb into apache:develop Sep 12, 2023
9 of 10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug] wrong result of searchOffset in tiered storage
4 participants