Skip to content

feat(ingest): publish session-sharded WAL records into Lance - #450

Merged
beinan merged 1 commit into
mainfrom
codex/wal-rollout-materializer
Oct 22, 2026
Merged

beinan merged 1 commit into
mainfrom
codex/wal-rollout-materializer

Conversation

@beinan

@beinan beinan commented Oct 21, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Durable rollout ACKs need a recoverable path into queryable Lance files. The materializer selects bounded prefixes across session-sharded WAL groups, fetches their Arrow IPC, and writes Lance fragments with bounded parallelism. It records prepared descriptors before publication, reconciles uncertain outcomes, and retires source payloads with catalog-issued closure proofs. Takeover reuses prepared files or completes retirement without republishing rows.

Refs #378. Built on merged #449; the feature diff is unchanged when moved to main.

Testing

  • Real TLS replicas and complete rollout schemas: restart original directories after preparation and publication, verify descriptors and every row/column, reject stale owners, and preserve exact append retries.
  • Bounded manifest history, multi-round publication, and client/catalog/Lance reader regressions.
  • Previous feature revision passed repository Rust and Python checks (229 passed, 2 skipped, 1 xfailed), formatting, Clippy, Ruff and Pyright. CI must pass again for the new commit before merge.

These checks establish correctness; they do not establish sustained throughput.

@beinan
beinan force-pushed the codex/wal-rollout-ingress branch from 3374f9e to 14d76f5 Compare October 21, 2026 21:42
@beinan
beinan force-pushed the codex/wal-rollout-materializer branch from 09f02cd to bc4268f Compare October 21, 2026 21:42
@beinan
beinan force-pushed the codex/wal-rollout-ingress branch from 14d76f5 to e79c4a0 Compare October 21, 2026 21:54
@beinan
beinan force-pushed the codex/wal-rollout-materializer branch from bc4268f to 15deff2 Compare October 21, 2026 21:54
@beinan
beinan force-pushed the codex/wal-rollout-ingress branch from e79c4a0 to 1668847 Compare October 21, 2026 23:02
@beinan
beinan force-pushed the codex/wal-rollout-materializer branch from 15deff2 to 2130778 Compare October 21, 2026 23:02
@beinan
beinan force-pushed the codex/wal-rollout-ingress branch from 1668847 to bc71dd8 Compare October 22, 2026 00:41
@beinan
beinan changed the base branch from codex/wal-rollout-ingress to main October 22, 2026 02:11
@beinan
beinan force-pushed the codex/wal-rollout-materializer branch from 2130778 to 5593db4 Compare October 22, 2026 02:11
@beinan
beinan merged commit a2e52fb into main Oct 22, 2026
19 checks passed
beinan added a commit that referenced this pull request Oct 22, 2026
## Summary

Add an HTTP gateway for durable rollout ingestion and a Rust HTTP
producer that journals exact retry state. Gateways accept the original
Arrow IPC buffer, reserve memory before buffering, separate data/control
admission, and return 202 only after the WAL quorum has persisted the
append. Signed producer credentials work across gateways without another
producer-allocation RPC on each append.

Producer lanes share one bounded group-commit journal and HTTP pool.
Original bytes and sequence are durable before transmission; the ACK is
durable locally before the body is released or the sequence advances. An
uncertain network result preserves the original intent, a different body
cannot replace it, and local journal ambiguity fences the lane until
reopen. Large digest/byte comparisons run off the async executor.

The gateway takes authorized fixed table bindings and must sit behind
application access control. These are application library interfaces;
deployment, dynamic namespace integration and sustained performance
qualification remain follow-up work.

Refs #378. Built on merged #450. The feature diff is unchanged when
moved to main; all CI must pass on the new commit before merging.

## Testing

- Complete repository CI-equivalent script passed: Rust, Python (229
passed, 2 skipped, 1 xfailed), formatting, Clippy, Ruff and Pyright.
- HTTP and HTTP-client/materializer feature checks passed, along with
all five integration tests.
- Real HTTP to TLS replicas to Lance: inject an intermediary error after
a durable ACK, reopen the client journal/gateway/all original replica
directories, recover the exact ACK, reuse prepared Lance files after
another restart, and verify every row/column and subsequent producer
sequences.
- Data-lane saturation keeps control requests available; draining joins
a disconnected partial-body reader without advancing its sequence.
Producer/receipt domain separation and tampering checks remain required.
- Native client-journal recovery regressions passed (10 tests, with two
child fixtures invoked by their parent tests).

The new application restart tests use joined shutdown/reopen, not
application SIGKILL or throughput measurements.

APT wheel setup now uses only signed official distribution repositories
in an isolated metadata directory. This avoids unrelated PPA outages;
bounded network retries, HTTPS and archive signature verification remain
enabled. Bash/ShellCheck and a local Debian metadata/install simulation
passed; the Ubuntu cross-build installation is validated by remote CI.


CI runs the existing workspace, WAL, Lance, and etcd suites in separate
jobs so cold feature builds do not exhaust one shared 60-minute timeout.
Every original check command and the coverage jobs are preserved.
Checkpoint reopen cases are serialized around subprocess creation to
prevent inherited file locks; corruption cases must report the expected
validation error. Minimal-feature and all-feature checkpoint tests and
Clippy pass; the workflow passes actionlint. Final-commit CI is required
before merging.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant