• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

prisma-risk / tsoracle / 26245990416
95%

Build:
DEFAULT BRANCH: main
Ran 21 May 2026 06:44PM UTC
Jobs 1
Files 46
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

21 May 2026 06:42PM UTC coverage: 95.274% (+0.02%) from 95.253%
26245990416

push

github

web-flow
feat(stress): in-process raft topology for the stress harness (#37)

* build(stress): add openraft deps for raft topology

* feat(stress): RaftTopology spawn boots in-process openraft cluster

Replaces the stub in `benchmarks/stress/src/topology/raft.rs` with a real
N-node implementation backed by `openraft_toolkit::test_fakes::MemNetwork`.
Each node owns a `RocksdbLogStore` in a tempdir, a `HighWaterStateMachine`,
and a dedicated `tsoracle::Server` bound to a loopback port via
`StandaloneHost` + `OpenraftDriver`. Membership is initialized on node 1
once every node is registered with the shared network, and `spawn` waits
up to 2 seconds for an initial leader before returning.

`RaftController` exposes `endpoints()`, `current_leader()` (reads
`Raft::metrics().current_leader`), and `shutdown()` (drains each node's
oneshot shutdown sender). Chaos primitives (`kill_leader`, `pause_leader`,
arm/disarm failpoints) return `ChaosOutcome::Skipped` for now and will be
replaced in follow-up PRs with `MemNetwork` partition-based chaos.

Adds `rocksdb` and `tempfile` to `[dependencies]` (the toolkit's log store
requires both, and they are not test-only here since `spawn` is library
code). One test boots a 3-node cluster, asserts three endpoints and a
leader, and shuts down — runs in ~80 ms.

* feat(stress): raft topology kill_leader via network partition

Replaces the Skipped placeholder on RaftController::kill_leader with a real
chaos op: read the current openraft leader from any node's metrics, isolate
that NodeId on the shared MemNetwork PartitionController for ~1.5s so the
remaining quorum elects a fresh leader, then heal so the next chaos op still
has a quorum to work with.

The 750ms isolation window from the original sketch flaked locally — the
followers in openraft 0.10 need a few heartbeat-interval ticks after the
election-timeout window before they actually escalate to Candidate, so the
sleep is bumped to 1500ms (still well inside a chaos cycle, but stab... (continued)

372 of 395 new or added lines in 2 files covered. (94.18%)

1 existing line in 1 file now uncovered.

5302 of 5565 relevant lines covered (95.27%)

97164.2 hits per line

Uncovered Changes

Lines Coverage ∆ File
23
94.09
benchmarks/stress/src/topology/raft.rs

Coverage Regressions

Lines Coverage ∆ File
1
94.97
0.48% benchmarks/stress/src/lib.rs
Jobs
ID Job ID Ran Files Coverage
1 26245990416.1 21 May 2026 06:44PM UTC 46
95.27
GitHub Action Run
Source Files on build 26245990416
  • Tree
  • List 46
  • Changed 3
  • Source Changed 1
  • Coverage Changed 3
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #26245990416
  • d2d83a22 on github
  • Prev Build on main (#26244601870)
  • Next Build on main (#26246147346)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc