Skip to content

asim: add gateway-overload test for #162590#162592

Open
tbg wants to merge 1 commit intocockroachdb:masterfrom
tbg:asim-sql-only-pattern
Open

asim: add gateway-overload test for #162590#162592
tbg wants to merge 1 commit intocockroachdb:masterfrom
tbg:asim-sql-only-pattern

Conversation

@tbg
Copy link
Member

@tbg tbg commented Feb 6, 2026

Add an allocator simulation test that reproduces the scenario where SQL-only (gateway) nodes dilute the cluster-wide load mean, causing the store rebalancer to permanently consider all KV nodes overloaded and churn leases unnecessarily.

The test sets up 5 KV nodes + 3 gateway nodes with all ranges constrained to the KV region. Under SMA, the rebalancer performs 47 lease moves in 10 minutes with massive lease thrashing (1554%), while MMA correctly recognizes the situation and performs only 2 lease moves with stable lease placement.

A steady-state assertion on lease counts confirms that SMA fails to maintain stability while MMA passes.

Informs: #162590
Epic: CRDB-56265
Release note: None

Add an allocator simulation test that reproduces the scenario where
SQL-only (gateway) nodes dilute the cluster-wide load mean, causing
the store rebalancer to permanently consider all KV nodes overloaded
and churn leases unnecessarily.

The test sets up 5 KV nodes + 3 gateway nodes with all ranges
constrained to the KV region. Under SMA, the rebalancer performs 47
lease moves in 10 minutes with massive lease thrashing (1554%), while
MMA correctly recognizes the situation and performs only 2 lease moves
with stable lease placement.

A steady-state assertion on lease counts confirms that SMA fails to
maintain stability while MMA passes.

Informs: cockroachdb#162590
Epic: CRDB-56265
Release note: None

Co-authored-by: Cursor <cursoragent@cursor.com>
@tbg tbg requested review from a team as code owners February 6, 2026 13:51
@trunk-io
Copy link
Contributor

trunk-io bot commented Feb 6, 2026

❌ This pull request failed tests. It has been removed from the merge queue. This SHA was used for testing. See more details here.

Failed Required Status Conclusion
unit_tests Failure
  • To merge this pull request, check the box to the left or comment /trunk merge below.

@cockroach-teamcity
Copy link
Member

This change is Reviewable

Copy link
Collaborator

@sumeerbhola sumeerbhola left a comment

Choose a reason for hiding this comment

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

:lgtm:

@sumeerbhola reviewed 1 file and all commit messages, and made 1 comment.
Reviewable status: :shipit: complete! 1 of 0 LGTMs obtained (waiting on @tbg).

@5hubh4m
Copy link
Contributor

5hubh4m commented Feb 6, 2026

/trunk merge

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants