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

prisma-risk / tsoracle / 26342019289
95%

Build:
DEFAULT BRANCH: main
Ran 23 May 2026 07:57PM UTC
Jobs 1
Files 74
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

23 May 2026 07:52PM UTC coverage: 94.792% (-0.004%) from 94.796%
26342019289

push

github

web-flow
fix(core)!: widen Epoch to u128 for lossless leader-epoch encoding (#221)

The paxos driver packed an OmniPaxos Ballot — identity (config_id: u32,
n: u32, pid: u64), 128 bits — into a 64-bit Epoch by masking config_id and
pid to 16 bits each. Distinct ballots could collide onto the same Epoch
(e.g. pid 1 and pid 65537), and that value is load-bearing: the fence in
PaxosDriver::persist_high_water and Allocator::try_commit_window_extension
distinguishes leaders by exact equality, and the client's leader cache
orders leader observations by it. A collision lets a superseded leader's
persisted high-water pass the fence and silently advance the durable bound.

A u64 cannot injectively hold the full ballot domain, so widen Epoch to
u128. The paxos encoding becomes lossless and total — config_id<<96 |
n<<64 | pid, no truncation, no validation — while staying monotonic, which
the equality fence and the client's monotone-forward cache both rely on.
decode_epoch is now an exact inverse. priority remains intentionally
unencoded (a static per-node tiebreaker determined by pid).

The on-wire epoch carries the full value as two uint64 halves rather than
truncating at the boundary: GetTsResponse.epoch becomes epoch_hi/epoch_lo
and LeaderHint.leader_epoch becomes leader_epoch_hi/leader_epoch_lo, with
lexicographic (hi, lo) order equal to numeric order. The file and openraft
drivers zero-extend their existing u64 epochs (no behaviour change).

Property tests cover the lossless round-trip and order-preservation
(injectivity + monotonicity) over the full ballot domain, and the
to_wire/from_wire round-trip and ordering across the 64-bit boundary.

BREAKING CHANGE: the GetTs gRPC response and the leader-hint trailer split
their u64 epoch field into two uint64 halves. Clients and servers must be
upgraded together.

Closes #206

92 of 92 new or added lines in 10 files covered. (100.0%)

3 existing lines in 1 file now uncovered.

10120 of 10676 relevant lines covered (94.79%)

539999.84 hits per line

Coverage Regressions

Lines Coverage ∆ File
3
84.37
-0.81% benchmarks/stress/src/topology/paxos.rs
Jobs
ID Job ID Ran Files Coverage
1 26342019289.1 23 May 2026 07:57PM UTC 74
94.79
GitHub Action Run
Source Files on build 26342019289
  • Tree
  • List 74
  • Changed 11
  • Source Changed 10
  • Coverage Changed 10
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #26342019289
  • cc3a3d44 on github
  • Prev Build on main (#26341753400)
  • Next Build on main (#26342927768)
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