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

fix: Fix chunked segment can not warmup using mmap #38492

Merged
merged 5 commits into from
Dec 17, 2024

Conversation

sunby
Copy link
Contributor

@sunby sunby commented Dec 16, 2024

issue: #38410

@sre-ci-robot sre-ci-robot added the size/L Denotes a PR that changes 100-499 lines. label Dec 16, 2024
@sunby sunby changed the title Fix no mmap chunk cache fix: Fix chunked segment can not warmup using mmap Dec 16, 2024
@mergify mergify bot added dco-passed DCO check passed. kind/bug Issues or changes related a bug labels Dec 16, 2024
@sunby
Copy link
Contributor Author

sunby commented Dec 16, 2024

ChunkedColumn does not use MmapChunkManager now so we use a file to mmap.
We will use MmapChunkManager to manage maped memory allocation and deallocation soon.

@czs007
Copy link
Collaborator

czs007 commented Dec 16, 2024

#38213

Copy link
Contributor

mergify bot commented Dec 16, 2024

@sunby E2e jenkins job failed, comment /run-cpu-e2e can trigger the job again.

Copy link
Contributor

mergify bot commented Dec 16, 2024

@sunby go-sdk check failed, comment rerun go-sdk can trigger the job again.

auto dir = path.parent_path();
std::filesystem::create_directories(dir);

auto file = File::Open(path.string(), O_CREAT | O_TRUNC | O_RDWR);
Copy link
Contributor

Choose a reason for hiding this comment

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

Use mmap manager?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Use mmap manager?

Chunk and ChunkedColumn will be changed a lot if I use mmap here. Will change it to MmapChunkManager later.

@bigsheeper
Copy link
Contributor

/lgtm

Copy link

codecov bot commented Dec 16, 2024

Codecov Report

Attention: Patch coverage is 71.79487% with 11 lines in your changes missing coverage. Please review.

Project coverage is 80.93%. Comparing base (3e2a2f2) to head (7a4c67f).
Report is 8 commits behind head on master.

Files with missing lines Patch % Lines
internal/core/src/storage/ChunkCache.cpp 71.87% 9 Missing ⚠️
...rnal/core/src/segcore/ChunkedSegmentSealedImpl.cpp 0.00% 2 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #38492      +/-   ##
==========================================
+ Coverage   80.91%   80.93%   +0.01%     
==========================================
  Files        1373     1373              
  Lines      193158   193191      +33     
==========================================
+ Hits       156295   156360      +65     
+ Misses      31349    31305      -44     
- Partials     5514     5526      +12     
Components Coverage Δ
Client 74.58% <ø> (ø)
Core 69.34% <71.79%> (+0.36%) ⬆️
Go 82.98% <ø> (-0.04%) ⬇️
Files with missing lines Coverage Δ
internal/core/src/storage/ChunkCache.h 100.00% <100.00%> (ø)
internal/core/src/storage/MmapManager.h 100.00% <100.00%> (ø)
...rnal/core/src/segcore/ChunkedSegmentSealedImpl.cpp 22.92% <0.00%> (ø)
internal/core/src/storage/ChunkCache.cpp 78.36% <71.87%> (+28.00%) ⬆️

... and 32 files with indirect coverage changes

@wangting0128
Copy link
Contributor

wangting0128 commented Dec 16, 2024

verify panic

image: PR-38492-20241216-0bba7866
image

Signed-off-by: sunby <[email protected]>
Signed-off-by: sunby <[email protected]>
Signed-off-by: sunby <[email protected]>
@sunby sunby force-pushed the fix_no_mmap_chunk_cache branch from a440190 to 5b9f6dd Compare December 16, 2024 14:38
@sre-ci-robot sre-ci-robot removed the lgtm label Dec 16, 2024
Signed-off-by: sunby <[email protected]>
Copy link
Contributor

mergify bot commented Dec 16, 2024

@sunby E2e jenkins job failed, comment /run-cpu-e2e can trigger the job again.

Copy link
Contributor

mergify bot commented Dec 16, 2024

@sunby go-sdk check failed, comment rerun go-sdk can trigger the job again.

@mergify mergify bot added the ci-passed label Dec 16, 2024
@czs007
Copy link
Collaborator

czs007 commented Dec 17, 2024

/approve
/lgtm

@sre-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: czs007, sunby

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@sre-ci-robot sre-ci-robot merged commit dd4f33a into milvus-io:master Dec 17, 2024
18 of 20 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved ci-passed dco-passed DCO check passed. kind/bug Issues or changes related a bug lgtm size/L Denotes a PR that changes 100-499 lines.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants