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

bedrock-kv / bedrock / 930cbbab54ac6d13010f567b9dbfa2cc8ea8d3c7
82%

Build:
DEFAULT BRANCH: develop
Ran 05 Sep 2026 04:07PM UTC
Jobs 1
Files 213
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

05 Sep 2026 04:06PM UTC coverage: 80.621% (+0.2%) from 80.415%
930cbbab54ac6d13010f567b9dbfa2cc8ea8d3c7

push

github

web-flow
gh-141: Guard fresh-cluster shard boundaries with regression tests (#231)

The fresh-cluster failure in #141 is reproducible in 0.6.0. Current
`develop` already avoids it: #194 replaced the bulk layout builder with
an index that inserts one fetched shard at a time. This PR adds the
missing regression coverage and documents the tested toolchains; it does
not change runtime behavior or backport a fix to 0.6.x.

### Why

Think of the default layout as two neighboring rooms sharing a doorway
at `0xFF`:

- User data occupies `[empty, 0xFF)`.
- Metadata starts at `0xFF` and runs to the end-of-keyspace sentinel.

The old builder collected both rooms' start and end points. The shared
doorway appeared twice, so it invented a third room with no space
inside: `[0xFF, 0xFF)`. That also gave the tree two entries with the
same end key. OTP 28 accepted the malformed tree; OTP 29 rejects it with
`:not_orddict`.

### What changed and how it works

The new tests call `InitializationPhase.execute/2` to obtain recovery's
real default shards, then insert those entries through today's
`LayoutIndex` API. Using the actual initialization result prevents a
copied test fixture from drifting away from what a fresh cluster
creates.

Both fetch orders are tested. The assertions require exactly two tree
entries and use different materializer references to verify the routing:
`"banana"` goes to the data shard, while the shared `0xFF` boundary
belongs to metadata. Empty-key, neighboring byte values, and the
existing inclusive end-of-keyspace sentinel behavior are covered too.

Today's `:gb_trees.enter/3` stores each shard under its own end key;
there is no combined boundary list to duplicate. No deduplication patch
is needed in this implementation. OTP 29 is already in CI. The README
now states the minimum Elixir version and the three CI-tested Elixir/OTP
pairings.

### Validation

- Historical red: extracted the unmodified `LayoutIndex` from
`a22a1516`, supplied the report's default... (continued)

7039 of 8731 relevant lines covered (80.62%)

1169.55 hits per line

Jobs
ID Job ID Ran Files Coverage
1 930cbbab54ac6d13010f567b9dbfa2cc8ea8d3c7.1 05 Sep 2026 04:07PM UTC 213
80.62
GitHub Action Run
Source Files on build 930cbbab54ac6d13010f567b9dbfa2cc8ea8d3c7
  • Tree
  • List 213
  • Changed 4
  • Source Changed 0
  • Coverage Changed 4
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • 930cbbab on github
  • Prev Build on develop (#ABC99FAA...)
  • Next Build on develop (#8F962E09...)
  • Delete
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc