Repository navigation
feat(dst): add RustFS Deterministic Simulation Testing framework and multi-seed runner - #4
Merged
Merged
Conversation
…and RustFS DST suite
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Implements the official Deterministic Simulation Testing (DST) framework, unified runtime abstraction traits, virtual fault simulators, simulated RustFS erasure-coded storage & lock suite, and Joshua-style multi-seed CLI runner for RustFS.
Key Components
crates/rustfs-dst-runtime— Unified non-determinism abstraction traits:Clock(RealClock/SimClockwith per-node wall-clock skew and monotonic drift injection)RngSource(RealRng/SimRngbacked byChaCha8Rngwith SHA-256 domain-separatedfork(label)and deterministic RFC 4122 UUID v4)Network(SimNetworksupporting symmetric/asymmetric partitions, Swizzle-Clog link jitter, packet loss, node crashes, and post-apply reply drops) + real Tokioturmoil0.7 virtual-TCP adapter (turmoil_net) +madsimcompatibility guidanceDiskIo(RealDiskIo/SimDiskIowith explicit volatile page-cache vs durablefsync_file/fsync_dirsplit, power-losscrash_and_reboot, torn writes, deterministic bitrot,ENOSPC, and offline drives)crates/rustfs-dst-faults— Fault & assertion infrastructure:BuggifyinjectorCodeProbecoverage tracker (always,sometimes,reachable,unreachable) with automatic Antithesis-compatible JSONL output (ANTITHESIS_OUTPUT_DIR/sdk.jsonl)CrashPointregistry mirroringrustfs/rustfs/crates/ecstore/src/crash_inject.rsSwizzleClogSchedulercrates/rustfs-dst-sim— Simulated RustFS cluster & 6-invariant oracle:4x4(16 drives, EC:4, R=12, W=12),3x2(6 drives, EC:3, R=3, W=4), and4x2(8 drives, EC:4, R=4, W=5)SimECStoreimplementing RustFS's two-phasexl.metacommit, write-quorum rollback, orphan generation reconciliation,If-Match/If-None-Match, multipart staging/commit/abort, bitrot detection, and online healingQuorumLockClient/NodeLockServiceverifying monotonic-clock quorum leases under wall-clock skewturmoil::Sim4-node virtual-TCP quorum cluster simulation (turmoil_cluster)crates/rustfs-dst-cli(rustfs-dst) + Antithesis manifests + CI workflows (ci.yml,nightly-dst.yml).Related Issues
Closes #1
Closes #2
Verification
cargo fmt --all -- --check: passedcargo clippy --workspace --all-targets -- -D warnings: passed (0 warnings)cargo test --workspace: 13/13 unit & integration tests passedrustfs-dst verify-determinism: bit-identical SHA-256 trace hashes confirmed across all 7 scenarios on4x4and3x2rustfs-dst run --scenario all --seeds 25: 525/525 runs passed (175 each on4x4,3x2, and4x2, 9,225 operations, 0 invariant violations)