mirror of
https://github.com/neondatabase/neon.git
synced 2026-01-15 01:12:56 +00:00
Revert "tests: improve stability of test_storage_controller_many_tenants (#…"
This reverts commit b7beaa0fd7.
This commit is contained in:
@@ -217,11 +217,7 @@ def test_storage_controller_many_tenants(
|
||||
# A reconciler operation: migrate a shard.
|
||||
shard_number = rng.randint(0, shard_count - 1)
|
||||
tenant_shard_id = TenantShardId(tenant_id, shard_number, shard_count)
|
||||
|
||||
# Migrate it to its secondary location
|
||||
desc = env.storage_controller.tenant_describe(tenant_id)
|
||||
dest_ps_id = desc["shards"][shard_number]["node_secondary"][0]
|
||||
|
||||
dest_ps_id = rng.choice([ps.id for ps in env.pageservers])
|
||||
f = executor.submit(
|
||||
env.storage_controller.tenant_shard_migrate, tenant_shard_id, dest_ps_id
|
||||
)
|
||||
@@ -235,11 +231,7 @@ def test_storage_controller_many_tenants(
|
||||
for f in futs:
|
||||
f.result()
|
||||
|
||||
# Some of the operations above (notably migrations) might leave the controller in a state where it has
|
||||
# some work to do, for example optimizing shard placement after we do a random migration. Wait for the system
|
||||
# to reach a quiescent state before doing following checks.
|
||||
env.storage_controller.reconcile_until_idle()
|
||||
|
||||
# Consistency check is safe here: all the previous operations waited for reconcile before completing
|
||||
env.storage_controller.consistency_check()
|
||||
check_memory()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user