Skip to content

Conversation

@weiliu1031
Copy link
Contributor

issue: #45857

  • Create new assign package with unified AssignPolicy interface that abstracts segment and channel assignment logic
  • Implement three assign policies: RoundRobin (for fast loading), RowCount-based, and Score-based assignment strategies
  • Add AssignPolicyFactory for creating and caching policy instances
  • Introduce StoppingBalancer to centralize stopping node balance logic that was previously duplicated across multiple balancers
  • Add BalancerFactory for dynamic balancer creation and caching based on configuration
  • Refactor existing balancers (ScoreBased, RowCountBased, ChannelLevel) to use the new assign policy abstraction
  • Move priority_queue and streaming_query_node_channel_helper to assign package
  • Add comprehensive unit tests for all new components
  • Add new config parameter for StoppingBalanceAssignPolicy

@sre-ci-robot sre-ci-robot added the size/XXL Denotes a PR that changes 1000+ lines. label Nov 26, 2025
@mergify mergify bot added dco-passed DCO check passed. kind/enhancement Issues or changes related to enhancement labels Nov 26, 2025
@sre-ci-robot
Copy link
Contributor

[ci-v2-notice]
Notice: We are gradually rolling out the new ci-v2 system.

  • Legacy CI jobs remain unaffected, you can just ignore ci-v2 if you don't want to run it.
  • Additional "ci-v2/*" checkers will run for this PR to ensure the new ci-v2 system is working as expected.
  • For tests that exist in both v1 and v2, passing in either system is considered PASS.

To rerun ci-v2 checks, comment with:

  • /ci-rerun-code-check // for ci-v2/code-check
  • /ci-rerun-build // for ci-v2/build
  • /ci-rerun-ut-integration // for ci-v2/ut-integration
  • /ci-rerun-ut-go // for ci-v2/ut-go
  • /ci-rerun-ut-cpp // for ci-v2/ut-cpp
  • /ci-rerun-ut // for all ci-v2/ut-integration, ci-v2/ut-go, ci-v2/ut-cpp
  • /ci-rerun-e2e-arm // for ci-v2/e2e-arm [master branch only]
  • /ci-rerun-e2e-default // for ci-v2/e2e-default [master branch only]

If you have any questions or requests, please contact @zhikunyao.

@mergify
Copy link
Contributor

mergify bot commented Nov 26, 2025

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

@codecov
Copy link

codecov bot commented Nov 26, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 82.73%. Comparing base (4f080bd) to head (8eb630a).

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##           master   #45858   +/-   ##
=======================================
  Coverage   82.73%   82.73%           
=======================================
  Files         524      524           
  Lines       82326    82326           
=======================================
  Hits        68111    68111           
  Misses      14215    14215           
Components Coverage Δ
Client ∅ <ø> (∅)
Core 82.73% <ø> (ø)
Go ∅ <ø> (∅)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@liliu-z liliu-z self-assigned this Nov 26, 2025
- Create new assign package with unified AssignPolicy interface that
  abstracts segment and channel assignment logic
- Implement three assign policies: RoundRobin (for fast loading),
  RowCount-based, and Score-based assignment strategies
- Add AssignPolicyFactory for creating and caching policy instances
- Introduce StoppingBalancer to centralize stopping node balance logic
  that was previously duplicated across multiple balancers
- Add BalancerFactory for dynamic balancer creation and caching based
  on configuration
- Refactor existing balancers (ScoreBased, RowCountBased, ChannelLevel)
  to use the new assign policy abstraction
- Move priority_queue and streaming_query_node_channel_helper to assign
  package
- Add comprehensive unit tests for all new components
- Add new config parameter for StoppingBalanceAssignPolicy

Signed-off-by: Wei Liu <[email protected]>
@weiliu1031 weiliu1031 force-pushed the refine_segment_checker branch from 8cf553c to 8eb630a Compare November 28, 2025 02:14
@sre-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: weiliu1031
To complete the pull request process, please ask for approval from liliu-z after the PR has been reviewed.

The full list of commands accepted by this bot can be found 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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dco-passed DCO check passed. kind/enhancement Issues or changes related to enhancement size/XXL Denotes a PR that changes 1000+ lines.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants