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: query iterator lack results(#33137) #33422

Merged
merged 1 commit into from
May 30, 2024

Conversation

MrPresent-Han
Copy link
Contributor

@MrPresent-Han MrPresent-Han commented May 28, 2024

related: #33137
adding has_more_result_tag for various level's reduce to rectify reduce_stop_for_best

@sre-ci-robot sre-ci-robot added size/L Denotes a PR that changes 100-499 lines. area/internal-api labels May 28, 2024
@mergify mergify bot added dco-passed DCO check passed. kind/bug Issues or changes related a bug do-not-merge/missing-related-issue labels May 28, 2024
Copy link
Contributor

mergify bot commented May 28, 2024

@MrPresent-Han Please associate the related issue to the body of your Pull Request. (eg. “issue: #”)

Copy link
Contributor

mergify bot commented May 28, 2024

@MrPresent-Han ut workflow job failed, comment rerun ut can trigger the job again.

Copy link
Contributor

mergify bot commented May 28, 2024

@MrPresent-Han ut workflow job failed, comment rerun ut can trigger the job again.

Copy link

codecov bot commented May 29, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 82.23%. Comparing base (970bf18) to head (b600c4a).
Report is 35 commits behind head on master.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #33422      +/-   ##
==========================================
+ Coverage   82.16%   82.23%   +0.07%     
==========================================
  Files        1012     1003       -9     
  Lines      128850   129480     +630     
==========================================
+ Hits       105868   106477     +609     
- Misses      19007    19023      +16     
- Partials     3975     3980       +5     
Files Coverage Δ
internal/core/src/common/QueryResult.h 96.87% <ø> (-1.59%) ⬇️
...al/core/src/query/visitors/ExecPlanNodeVisitor.cpp 97.82% <100.00%> (-0.77%) ⬇️
internal/core/src/segcore/InsertRecord.h 90.98% <100.00%> (+0.14%) ⬆️
internal/core/src/segcore/SegmentGrowingImpl.h 81.03% <ø> (+0.67%) ⬆️
internal/core/src/segcore/SegmentInterface.cpp 88.13% <100.00%> (-0.24%) ⬇️
internal/core/src/segcore/SegmentInterface.h 100.00% <ø> (ø)
internal/core/src/segcore/SegmentSealedImpl.h 80.00% <ø> (ø)
internal/proxy/task_query.go 81.49% <100.00%> (-0.22%) ⬇️
internal/querynodev2/segments/result.go 74.41% <100.00%> (+0.36%) ⬆️
internal/querynodev2/tasks/query_task.go 91.83% <100.00%> (+0.08%) ⬆️
... and 1 more

... and 256 files with indirect coverage changes

@mergify mergify bot added the ci-passed label May 29, 2024
Copy link
Contributor Author

@MrPresent-Han MrPresent-Han left a comment

Choose a reason for hiding this comment

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

review

@@ -228,6 +228,7 @@ struct RetrieveResult {
void* segment_;
std::vector<int64_t> result_offsets_;
std::vector<DataArray> field_data_;
bool has_more_result;
};
Copy link
Contributor Author

Choose a reason for hiding this comment

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

actually, this should be 'maybe_has_more_result', when it's true, we cannot discard all possible following results from this source, when it's false, it's definitely ok to ignore results from this source.

@@ -274,7 +274,7 @@ class OffsetOrderedArray : public OffsetMap {
hit_num++;
}
}
return seg_offsets;
return {seg_offsets, it != array_.end()};
}
Copy link
Contributor Author

Choose a reason for hiding this comment

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

here, it may not be very accurate because when bitset.count() is 0, it will not move to the end of the array neither. But has_more_result is a 'possible and vague' tag as explained before, so it's ok to simplify here like this

Copy link
Contributor

@longjiquan longjiquan left a comment

Choose a reason for hiding this comment

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

/lgtm

adding has_more_result_tag for various level's reduce to rectify reduce_stop_for_best

Signed-off-by: MrPresent-Han <chun.han@zilliz.com>
@congqixia
Copy link
Contributor

/approve

@sre-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: congqixia, MrPresent-Han

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

@longjiquan
Copy link
Contributor

/lgtm

@sre-ci-robot sre-ci-robot merged commit 416a2cf into milvus-io:master May 30, 2024
15 checks passed
sre-ci-robot pushed a commit that referenced this pull request May 31, 2024
related: #33137
pr: #33422

Signed-off-by: MrPresent-Han <chun.han@zilliz.com>
MrPresent-Han added a commit to MrPresent-Han/milvus that referenced this pull request May 31, 2024
related: milvus-io#33137 
adding has_more_result_tag for various level's reduce to rectify
reduce_stop_for_best

Signed-off-by: MrPresent-Han <chun.han@zilliz.com>
MrPresent-Han added a commit to MrPresent-Han/milvus that referenced this pull request May 31, 2024
pr: milvus-io#33422
issue: milvus-io#33137

Signed-off-by: MrPresent-Han <chun.han@zilliz.com>
MrPresent-Han added a commit to MrPresent-Han/milvus that referenced this pull request May 31, 2024
sre-ci-robot pushed a commit that referenced this pull request Jun 5, 2024
related: #33137 
pr: #33422

Signed-off-by: MrPresent-Han <chun.han@zilliz.com>
yellow-shine pushed a commit to yellow-shine/milvus that referenced this pull request Jul 2, 2024
related: milvus-io#33137 
adding has_more_result_tag for various level's reduce to rectify
reduce_stop_for_best

Signed-off-by: MrPresent-Han <chun.han@zilliz.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved area/internal-api 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.

4 participants