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

prisma-risk / tsoracle / 26381549307
95%

Build:
DEFAULT BRANCH: main
Ran 25 May 2026 03:30AM UTC
Jobs 1
Files 82
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

25 May 2026 03:25AM UTC coverage: 94.826% (-0.01%) from 94.839%
26381549307

push

github

web-flow
fix(server): stop leader-watch task cooperatively via WatchGuard (#392)

`into_router` spawned `run_leader_watch` holding `Arc<Server>` and returned
a bare `JoinHandle`. A piggyback embedder who mounted the `Routes` and
dropped or merely stored the handle could not stop the task at their own
shutdown: it kept `Arc<Server>` (and the consensus driver) alive until the
leadership stream happened to close. The only other stop, `abort()`, is a
hard cancel that can drop the task mid-fence while it holds
`extension_gate.write()`.

Thread a cooperative cancel future into `run_leader_watch`, observed via a
biased arm in both `select!` boundaries (the event wait and the
transient-retry backoff) but never inside a fence attempt, so an in-flight
fence always runs to completion. On cancel the task publishes `NotServing`
and returns `Ok(())`.

`into_router` now returns a `WatchGuard` that owns the task: dropping it (or
calling `shutdown().await`) cancels cooperatively, tying task lifetime to
guard lifetime. The guard also exposes `abort()` and a read-only
`is_finished()` liveness probe. The cancel signal is a `oneshot`, so no new
dependency is added.

`serve_with_*` no longer abort the watch task on user shutdown; they drop
its cancel sender and await a clean drain. The spawn body is extracted into
a private `into_router_parts` so that path stays free of the guard's
`Option` fields. `join_to_server_result`'s `Ok(Ok(()))` arm is now reachable
as cooperative cancellation rather than an unreachable production case.

60 of 66 new or added lines in 2 files covered. (90.91%)

1 existing line in 1 file now uncovered.

12647 of 13337 relevant lines covered (94.83%)

409709.86 hits per line

Uncovered Changes

Lines Coverage ∆ File
6
96.56
-1.11% crates/tsoracle-server/src/server.rs

Coverage Regressions

Lines Coverage ∆ File
1
97.44
-0.32% benchmarks/stress/src/loadgen.rs
Jobs
ID Job ID Ran Files Coverage
1 26381549307.1 25 May 2026 03:30AM UTC 82
94.83
GitHub Action Run
Source Files on build 26381549307
  • Tree
  • List 82
  • Changed 5
  • Source Changed 3
  • Coverage Changed 5
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #26381549307
  • a0c96baf on github
  • Prev Build on main (#26381315822)
  • Next Build on main (#26381687665)
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