From a1d75229ef459235cd802f0d59e97798d43761f7 Mon Sep 17 00:00:00 2001 From: Congqi Xia Date: Wed, 25 Sep 2024 11:55:08 +0800 Subject: [PATCH] enhance: Return segment id hint in QueryStream response Related to #36482 This PR reuses `SealedSegmentIDsRetrieved` field in `RetrieveResults` struct to store segment id hint. Signed-off-by: Congqi Xia --- internal/querynodev2/segments/retrieve.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/internal/querynodev2/segments/retrieve.go b/internal/querynodev2/segments/retrieve.go index d47388aad8c98..6629106257dd0 100644 --- a/internal/querynodev2/segments/retrieve.go +++ b/internal/querynodev2/segments/retrieve.go @@ -124,7 +124,8 @@ func retrieveOnSegmentsWithStream(ctx context.Context, mgr *Manager, segments [] CostAggregation: &internalpb.CostAggregation{ TotalRelatedDataSize: GetSegmentRelatedDataSize(segment), }, - AllRetrieveCount: result.GetAllRetrieveCount(), + SealedSegmentIDsRetrieved: []int64{segment.ID()}, + AllRetrieveCount: result.GetAllRetrieveCount(), }); err != nil { errs[i] = err }