Skip to content

Conversation

@jac0626
Copy link
Collaborator

@jac0626 jac0626 commented Nov 21, 2025

The async flush() method was returning immediately after the RPC call without waiting for segments to be actually flushed, causing num_entities to return incorrect values (usually 0) right after flush().

This commit:

  • Adds async get_flush_state() method to check flush status
  • Adds async _wait_for_flushed() method to wait for flush completion
  • Updates flush() to wait for all segments to be flushed in parallel using asyncio.gather()
  • Ensures async flush() behavior matches synchronous flush()

(cherry picked from commit bdbdc84)

The async flush() method was returning immediately after the RPC call
without waiting for segments to be actually flushed, causing num_entities
to return incorrect values (usually 0) right after flush().

This commit:
- Adds async get_flush_state() method to check flush status
- Adds async _wait_for_flushed() method to wait for flush completion
- Updates flush() to wait for all segments to be flushed in parallel
  using asyncio.gather()
- Ensures async flush() behavior matches synchronous flush()

Signed-off-by: silas.jiang <[email protected]>
(cherry picked from commit bdbdc84)
@codecov
Copy link

codecov bot commented Nov 21, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
⚠️ Please upload report for BASE (2.6@9b0f35d). Learn more about missing BASE report.

Additional details and impacted files
@@          Coverage Diff           @@
##             2.6    #3090   +/-   ##
======================================
  Coverage       ?   45.22%           
======================================
  Files          ?       65           
  Lines          ?    13796           
  Branches       ?        0           
======================================
  Hits           ?     6239           
  Misses         ?     7557           
  Partials       ?        0           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@mergify mergify bot added the ci-passed label Nov 21, 2025
Copy link
Contributor

@XuanYang-cn XuanYang-cn left a comment

Choose a reason for hiding this comment

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

/lgtm

@sre-ci-robot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: jac0626, XuanYang-cn

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 604b7f4 into milvus-io:2.6 Nov 21, 2025
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants