Repository navigation
fix(dst): resolve Carbon audit P0/P1 quorum, lock, clock, network, concurrency, and tautology findings - #12
Merged
Conversation
…d tautology findings
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.
Closes #11
Summary
Resolves all P0, P1, and P2 findings identified in the independent Carbon audit across
rustfs-dst-runtime,rustfs-dst-faults,rustfs-dst-sim, andrustfs-dst-cli:[D-01] [P0]SimECStoreTwo-PhaseStageShard/CommitShard&k == m(3x2,4x2) Quorum Linearizability:StageShardin.rustfs.sys/tmp/<tx_id>) from Phase 2 (CommitShard), ensuring writes failing stage quorum never publish partialxl.metafiles on disk.votes + skipped_higher_votes + unreachable >= write_quorum) acrossget_object,list_objects, andheal_object, preventing sub-write-quorumk-shard orphans on3x2/4x2from shadowing older committed versions or being promoted during heal.[D-02] [P1]SimNetwork::callReplyDroppedAfterApplySoundness:ReplyDroppedAfterApplystrictly onresponse.is_ok()so failed remote handler executions are never misclassified as indeterminate applied writes.[D-03] [P1]Unconditional Backup-Less Rollback Cleanup:handle_rollbacknow removes uncommittedxl.metaand version directories wheneverxl.meta.bkpis absent, even whenfailed_generation > 1on a drive that missed earlier generations.[D-04] [P1]NodeLockServiceCrash-Safe Lease Recovery Grace & Epoch Bump:clear_on_crash(), preventing 3-node single-server crash/reboot split-brain.[D-05] [P1]SimClockMonotonicity Under Drift Changes &clear_faults():node_drift_ppmincrementally peradvance()step sonow_instant()never moves backward when faults are cleared.[D-06] [P1]ConcurrentJoinSetQuorum Fanouts & Multi-Writer CAS Race Test:for-loop quorum RPCs inSimECStoreandQuorumLockClientinto concurrentJoinSetfanouts while preserving deterministic slot-order aggregation.[D-07] [P2]Multi-Seed Must-Hit Enforcement forSometimes&ReachableProbes:rustfs-dst run(whenseeds >= 5) now fails closed if any registeredSometimesorReachableprobe haspass_count == 0.[S-01..S-04] [P1/P2]Replaced Tautological Constant Checks with Stateful Fault Simulations:scanner.rs,enterprise_data.rs,security_obs.rs,pools.rs, andreplication.rswith stateful 100s lease-heartbeat persistence, topology/load-aware Deep pacer, two-stepSimDiskIorestore copy-back barrier, lock-free status reads under held namespace quorum lock, realtry_delete_namespace, HLC causal stamps, and cross-pool generation union without omniscientglobal_deletedshortcuts.Verification
cargo fmt --all -- --check&cargo clippy --workspace --all-targets -- -D warnings— 0 warningscargo test --workspace— 38/38 unit & integration tests passrustfs-dst verify-determinism(4x4&3x2) — 33/33 bit-exact replay passrustfs-dst run --scenario all --seeds 25(4x4&3x2) — 1,650/1,650 runs pass, 0 unhit must-hit probes