-
Type:
Task
-
Resolution: Unresolved
-
Priority:
Major - P3
-
None
-
Affects Version/s: None
-
Component/s: Test Model
-
None
-
Storage Engines - Persistence
-
195.961
-
StorEng - Defined Pipeline
-
None
Larger Context
This ticket adds switch_role from WT-18868 to probability-based workload generation. It builds on the follower-mode foundation from WT-18867 and can adopt verified relaxations from WT-18869.
Motivation
Randomised workloads are required to exercise repeated role transitions with transactions, timestamps, checkpoints, crashes, and restarts.
Scope
Add a switch_role probability and generate workloads with zero, one, or multiple transitions. Track the current role while building the serial-equivalent workload. Reuse the sequence dependency graph to make each synchronous transition a full transaction barrier, and extend timestamp-block assignment for role-specific stable and checkpoint preparation.
Keep crash and restart generation enabled in both roles. Add counterexample-reduction tests, preserve deterministic replay through expanded workload files and recorded seeds, and add one Evergreen task named model-test-switch.
Acceptance Criteria
- Seeded generation produces valid workloads with zero, one, and multiple role transitions.
- Transition barriers, timestamps, crashes, and restarts behave correctly in both roles.
- Counterexample reduction completes with valid switch_role workloads.
- Model and WiredTiger return codes and final recovered data match.
- model-test-switch runs the randomised workload in Evergreen.
Outcome
Evergreen continuously runs reproducible and reducible randomised single-node switch-mode workloads.