From cf362282f019ac70272bf88a58b861c0b0e7f9c4 Mon Sep 17 00:00:00 2001 From: Zhengchao An Date: Sun, 30 Aug 2026 10:42:23 +0800 Subject: [PATCH] fix(test): serialize transition matrix tests under nextest (#6874) The transition_matrix_tests use #[serial_test::serial] which has no effect under nextest (each test runs in a separate process). When running alongside thousands of other ecstore tests, the shared metadata cache generation counter can race, causing intermittent 'metadata read should publish the generation under test' panics. Add both tests to the ecstore-serial-flaky test group in both default and ci nextest profiles so they run single-threaded. --- .config/nextest.toml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/.config/nextest.toml b/.config/nextest.toml index 9907f4f4f..044a3ff47 100644 --- a/.config/nextest.toml +++ b/.config/nextest.toml @@ -100,6 +100,16 @@ test-group = 'embedded-test-ports' filter = 'package(rustfs-ecstore) & test(manual_transition_page_checkpoint_persists_durable_job_progress)' test-group = 'ecstore-serial-flaky' +# Serialize the transition matrix tests. They build a 4-disk hermetic erasure +# set, populate the get_object_metadata_cache, and assert generation lifecycle +# semantics. serial_test's #[serial] has no effect across nextest's process +# boundary, so concurrent execution races the shared metadata-cache generation +# counter and causes spurious "metadata read should publish the generation" +# panics. Preventive serialization, no retries. +[[profile.default.overrides]] +filter = 'package(rustfs-ecstore) & test(set_disk::transition_matrix_tests::)' +test-group = 'ecstore-serial-flaky' + # The durable ILM decommission regressions build isolated multi-pool stores and # deliberately take source or target disks offline while checking fencing. [[profile.default.overrides]] @@ -232,6 +242,12 @@ test-group = 'embedded-test-ports' filter = 'package(rustfs-ecstore) & test(manual_transition_page_checkpoint_persists_durable_job_progress)' test-group = 'ecstore-serial-flaky' +# Serialize the transition matrix tests under the ci profile too (see the +# matching default-profile override near the top). No retries. +[[profile.ci.overrides]] +filter = 'package(rustfs-ecstore) & test(set_disk::transition_matrix_tests::)' +test-group = 'ecstore-serial-flaky' + [[profile.ci.overrides]] filter = 'package(rustfs-ecstore) & (test(decommission_migrates_and_verifies_registered_durable_ilm_records) | test(decommission_durable_ilm_target_read_error_is_not_masked_by_peer_success) | test(decommission_durable_ilm_terminal_receipt_recovers_failed_source_cleanup) | test(decommission_durable_ilm_receipt_pagination_fails_closed_on_second_page) | test(decommission_durable_ilm_recovery_keeps_multiple_active_sources))' test-group = 'ecstore-serial-flaky'