milvus-io / milvus

A cloud-native vector database, storage for next generation AI applications
https://milvus.io
Apache License 2.0
27.29k stars 2.63k forks source link

fix: add request resource timeout for lazy load, refactor context usage in cache #32709

Closed chyezh closed 2 weeks ago

chyezh commented 3 weeks ago

issue: #32663

related dev pr: #32684

mergify[bot] commented 3 weeks ago

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

mergify[bot] commented 3 weeks ago

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

mergify[bot] commented 3 weeks ago

@chyezh ut workflow job failed, comment rerun ut can trigger the job again.

mergify[bot] commented 2 weeks ago

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

mergify[bot] commented 2 weeks ago

@chyezh ut workflow job failed, comment rerun ut can trigger the job again.

mergify[bot] commented 2 weeks ago

@chyezh ut workflow job failed, comment rerun ut can trigger the job again.

codecov[bot] commented 2 weeks ago

Codecov Report

Attention: Patch coverage is 46.31579% with 51 lines in your changes are missing coverage. Please review.

Project coverage is 81.71%. Comparing base (37a99ca) to head (7c285e4). Report is 21 commits behind head on master.

Additional details and impacted files [![Impacted file tree graph](https://app.codecov.io/gh/milvus-io/milvus/pull/32709/graphs/tree.svg?width=650&height=150&src=pr&token=XdCbzGJk2E&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=milvus-io)](https://app.codecov.io/gh/milvus-io/milvus/pull/32709?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=milvus-io) ```diff @@ Coverage Diff @@ ## master #32709 +/- ## ========================================== - Coverage 81.76% 81.71% -0.05% ========================================== Files 998 1002 +4 Lines 124284 125438 +1154 ========================================== + Hits 101621 102502 +881 - Misses 18795 19027 +232 - Partials 3868 3909 +41 ``` | [Files](https://app.codecov.io/gh/milvus-io/milvus/pull/32709?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=milvus-io) | Coverage Δ | | |---|---|---| | [internal/querynodev2/segments/manager.go](https://app.codecov.io/gh/milvus-io/milvus/pull/32709?src=pr&el=tree&filepath=internal%2Fquerynodev2%2Fsegments%2Fmanager.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=milvus-io#diff-aW50ZXJuYWwvcXVlcnlub2RldjIvc2VnbWVudHMvbWFuYWdlci5nbw==) | `76.48% <100.00%> (-2.52%)` | :arrow_down: | | [pkg/util/cache/cache.go](https://app.codecov.io/gh/milvus-io/milvus/pull/32709?src=pr&el=tree&filepath=pkg%2Futil%2Fcache%2Fcache.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=milvus-io#diff-cGtnL3V0aWwvY2FjaGUvY2FjaGUuZ28=) | `87.87% <100.00%> (-6.46%)` | :arrow_down: | | [pkg/util/paramtable/component\_param.go](https://app.codecov.io/gh/milvus-io/milvus/pull/32709?src=pr&el=tree&filepath=pkg%2Futil%2Fparamtable%2Fcomponent_param.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=milvus-io#diff-cGtnL3V0aWwvcGFyYW10YWJsZS9jb21wb25lbnRfcGFyYW0uZ28=) | `98.45% <100.00%> (+0.02%)` | :arrow_up: | | [internal/querynodev2/segments/utils.go](https://app.codecov.io/gh/milvus-io/milvus/pull/32709?src=pr&el=tree&filepath=internal%2Fquerynodev2%2Fsegments%2Futils.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=milvus-io#diff-aW50ZXJuYWwvcXVlcnlub2RldjIvc2VnbWVudHMvdXRpbHMuZ28=) | `29.35% <0.00%> (+3.35%)` | :arrow_up: | | [pkg/util/contextutil/context\_util.go](https://app.codecov.io/gh/milvus-io/milvus/pull/32709?src=pr&el=tree&filepath=pkg%2Futil%2Fcontextutil%2Fcontext_util.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=milvus-io#diff-cGtnL3V0aWwvY29udGV4dHV0aWwvY29udGV4dF91dGlsLmdv) | `75.51% <69.23%> (-2.27%)` | :arrow_down: | | [internal/querynodev2/segments/retrieve.go](https://app.codecov.io/gh/milvus-io/milvus/pull/32709?src=pr&el=tree&filepath=internal%2Fquerynodev2%2Fsegments%2Fretrieve.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=milvus-io#diff-aW50ZXJuYWwvcXVlcnlub2RldjIvc2VnbWVudHMvcmV0cmlldmUuZ28=) | `78.99% <0.00%> (-5.89%)` | :arrow_down: | | [internal/querynodev2/segments/search.go](https://app.codecov.io/gh/milvus-io/milvus/pull/32709?src=pr&el=tree&filepath=internal%2Fquerynodev2%2Fsegments%2Fsearch.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=milvus-io#diff-aW50ZXJuYWwvcXVlcnlub2RldjIvc2VnbWVudHMvc2VhcmNoLmdv) | `68.11% <0.00%> (-21.74%)` | :arrow_down: | | [pkg/util/paramtable/param\_item.go](https://app.codecov.io/gh/milvus-io/milvus/pull/32709?src=pr&el=tree&filepath=pkg%2Futil%2Fparamtable%2Fparam_item.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=milvus-io#diff-cGtnL3V0aWwvcGFyYW10YWJsZS9wYXJhbV9pdGVtLmdv) | `83.75% <33.33%> (-6.02%)` | :arrow_down: | | [internal/querynodev2/segments/segment\_loader.go](https://app.codecov.io/gh/milvus-io/milvus/pull/32709?src=pr&el=tree&filepath=internal%2Fquerynodev2%2Fsegments%2Fsegment_loader.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=milvus-io#diff-aW50ZXJuYWwvcXVlcnlub2RldjIvc2VnbWVudHMvc2VnbWVudF9sb2FkZXIuZ28=) | `71.25% <0.00%> (-0.84%)` | :arrow_down: | ... and [45 files with indirect coverage changes](https://app.codecov.io/gh/milvus-io/milvus/pull/32709/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=milvus-io)
czs007 commented 2 weeks ago

/approve /lgtm

sre-ci-robot commented 2 weeks ago

[APPROVALNOTIFIER] This PR is APPROVED

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

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: - ~~[configs/OWNERS](https://github.com/milvus-io/milvus/blob/master/configs/OWNERS)~~ [czs007] - ~~[internal/querynodev2/segments/OWNERS](https://github.com/milvus-io/milvus/blob/master/internal/querynodev2/segments/OWNERS)~~ [czs007] - ~~[pkg/util/OWNERS](https://github.com/milvus-io/milvus/blob/master/pkg/util/OWNERS)~~ [czs007] Approvers can indicate their approval by writing `/approve` in a comment Approvers can cancel approval by writing `/approve cancel` in a comment