Take-in holds a merge by reference, so a mesh-catalog merge over the state value cap is taken in (issue 1585, ADR 0633) #154

Merged
mesh-tools merged 5 commits from fix/1585-pending-by-reference into main 2026-11-05 10:48:58 +00:00
Member

Blocking fault of the take-in step (issue 1585, ADR 0633; notes 63-65): since mesh-delivery#153 went live no mesh-catalog merge was taken in. The indexer copied each merged message whole into its pending state, and a mesh-catalog message (about 548 KB) is over the 256 KiB cap every state value has; the create failed and the message was left for redelivery until the bus gave up. Recovered meanwhile by indexer_take_in per module (nfs-server, mesh-build-go, mesh-knowledge, messenger run their new builds).

What changes:

  • The pending value holds a reference (the FORGE sequence, repository, number, merge, branch, group, members), well under 4 KiB; an old value holding the message whole still reads.
  • The message in hand stays in memory as the first source. A held merge the indexer does not hold (a new indexer build, a restart) is asked of the forge bridge's new tool bridge_merged_message {repository, merge}, built as the bridge builds the message it publishes; the indexer names it in its invokes. No read of another module's stream, no mesh-sdk change.
  • Of a repository's ready merges only the newest is applied: a merged message carries every manifest, so it covers the older ones (deletions and moves included). A covered merge runs only its candidate removal.
  • A merge the bridge cannot answer is said once (Lost, with the bridge's words, in indexer_pending and on the take-in event) and waits; it is never taken in silently. A newer merge covers it, or indexer_drop_pending drops it.
  • New hand tool indexer_take_in_merge {repository, merge, sequence, why}: takes one merge in through the bridge, the ask-again tool a held message lacked. After delivery it takes mesh-catalog 559939aa (#616, sequence 3153) in.

Quick fix weighed and refused: raising the pending bucket's value cap (the cap is the mesh's rule for every bucket). Shapes weighed and refused on the way: a read of the forge bridge's stream by sequence (no consumer has the grant, and it reads another module's bus state, ADR 0596); the objects form (ADR 0595, not built yet, issue 1966); the indexer's own log (entries capped at 256 KiB too).

Tests: the 1585 row of TestTakeIn (a 300 KiB merge against a store enforcing the cap; a second indexer with an empty memory taking a held merge in through the bridge; a covered merge leaving its candidate; Lost said with the bridge down); a subtest of the bridge's tools test comparing bridge_merged_message byte for byte with the published message; TestIndexerWhole takes a restart through a real tool call. No new test function (875, as main). Locally: go vet, go vet -tags integration, go test in the indexer, its takein module, mesh-delivery-view, mesh-delivery-watchman and the bridge; the manifest validator on both changed manifests: accepted.

Noted for later on issue 1585 (not in this change): the bridge tool passes no kept inputs, so it reads about 433 forge files within the indexer's 30 s call bound (a timeout is said and asked again); a merge the gate's merges do not hold answers Lost until a newer one covers it.

Reviewed-by: review-1585-size@shanks at 655791b8a3

https://claude.ai/code/session_01JG73KG7AfSdh6FP8VrBqCn

Blocking fault of the take-in step (issue 1585, ADR 0633; notes 63-65): since mesh-delivery#153 went live no mesh-catalog merge was taken in. The indexer copied each merged message whole into its pending state, and a mesh-catalog message (about 548 KB) is over the 256 KiB cap every state value has; the create failed and the message was left for redelivery until the bus gave up. Recovered meanwhile by indexer_take_in per module (nfs-server, mesh-build-go, mesh-knowledge, messenger run their new builds). What changes: - The pending value holds a reference (the FORGE sequence, repository, number, merge, branch, group, members), well under 4 KiB; an old value holding the message whole still reads. - The message in hand stays in memory as the first source. A held merge the indexer does not hold (a new indexer build, a restart) is asked of the forge bridge's new tool bridge_merged_message {repository, merge}, built as the bridge builds the message it publishes; the indexer names it in its invokes. No read of another module's stream, no mesh-sdk change. - Of a repository's ready merges only the newest is applied: a merged message carries every manifest, so it covers the older ones (deletions and moves included). A covered merge runs only its candidate removal. - A merge the bridge cannot answer is said once (Lost, with the bridge's words, in indexer_pending and on the take-in event) and waits; it is never taken in silently. A newer merge covers it, or indexer_drop_pending drops it. - New hand tool indexer_take_in_merge {repository, merge, sequence, why}: takes one merge in through the bridge, the ask-again tool a held message lacked. After delivery it takes mesh-catalog 559939aa (#616, sequence 3153) in. Quick fix weighed and refused: raising the pending bucket's value cap (the cap is the mesh's rule for every bucket). Shapes weighed and refused on the way: a read of the forge bridge's stream by sequence (no consumer has the grant, and it reads another module's bus state, ADR 0596); the objects form (ADR 0595, not built yet, issue 1966); the indexer's own log (entries capped at 256 KiB too). Tests: the 1585 row of TestTakeIn (a 300 KiB merge against a store enforcing the cap; a second indexer with an empty memory taking a held merge in through the bridge; a covered merge leaving its candidate; Lost said with the bridge down); a subtest of the bridge's tools test comparing bridge_merged_message byte for byte with the published message; TestIndexerWhole takes a restart through a real tool call. No new test function (875, as main). Locally: go vet, go vet -tags integration, go test in the indexer, its takein module, mesh-delivery-view, mesh-delivery-watchman and the bridge; the manifest validator on both changed manifests: accepted. Noted for later on issue 1585 (not in this change): the bridge tool passes no kept inputs, so it reads about 433 forge files within the indexer's 30 s call bound (a timeout is said and asked again); a merge the gate's merges do not hold answers Lost until a newer one covers it. Reviewed-by: review-1585-size@shanks at 655791b8a351e178ef5b73983fa8abcc0e6f2f54 https://claude.ai/code/session_01JG73KG7AfSdh6FP8VrBqCn
mesh-tools added 5 commits 2026-11-05 10:43:10 +00:00
The pending value holds the stream sequence and the small fields the waits read; the take-in reads the message from the
forge bridge's stream by sequence. A message the stream no longer holds is said (take-in.pending lost, indexer_pending)
and never taken in silently. indexer_take_in_forge takes one forge message in by its sequence.

Claude-Session: https://claude.ai/code/session_01JG73KG7AfSdh6FP8VrBqCn
The take-in unblocks merges without the read grant on the forge bridge's stream: the message Arrive was handed is used,
the stream is read only for a pending merge not held in memory, and older merges of a repository in a revision are
covered by its newest and never read.

Claude-Session: https://claude.ai/code/session_01JG73KG7AfSdh6FP8VrBqCn
Claude-Session: https://claude.ai/code/session_01JG73KG7AfSdh6FP8VrBqCn
Claude-Session: https://claude.ai/code/session_01JG73KG7AfSdh6FP8VrBqCn
Bridge tool test: the merged-message rows are a subtest of the existing tools test, within the test budget (issue 1585)
mesh/check being carried to 655791b8a351 on 2fcd61baa6eb | from 4596fbe1b7ac
mesh/delivery merged: source.main moved to novox/mesh-delivery@2fcd61baa6eb
655791b8a3
Claude-Session: https://claude.ai/code/session_01JG73KG7AfSdh6FP8VrBqCn
Author
Member

Delivery novox/mesh-delivery@655791b8a351 — merged since 2026-11-05T10:48:59Z

Source — source.main moved to novox/mesh-delivery@2fcd61baa6. Whether it reached the machines is mesh-delivery-view's, derived from source.main, the wants and the haves.

Transitions

  • 2026-11-05 10:43 (new) → proposed (announced): novox/mesh-delivery#154's head announced
  • 2026-11-05 10:43 proposed → ready (accepted): a verdict names this commit and the trunk's head as its trunk commit, the gate passed or warned, and the repository's own check did not fail; or the check gates no merge (check-gates-merge false)
  • 2026-11-05 10:48 ready → merged (merged): on the trunk its modules follow: merged there

The commit's note under refs/notes/mesh-plan keeps every transition of this change up to its merge: git log --notes=mesh-plan.

<!-- mesh-delivery:view --> **Delivery** `novox/mesh-delivery@655791b8a351` — **merged** since 2026-11-05T10:48:59Z **Source** — source.main moved to novox/mesh-delivery@2fcd61baa6eb. Whether it reached the machines is `mesh-delivery-view`'s, derived from `source.main`, the wants and the haves. **Transitions** - 2026-11-05 10:43 (new) → proposed (announced): novox/mesh-delivery#154's head announced - 2026-11-05 10:43 proposed → ready (accepted): a verdict names this commit and the trunk's head as its trunk commit, the gate passed or warned, and the repository's own check did not fail; or the check gates no merge (check-gates-merge false) - 2026-11-05 10:48 ready → merged (merged): on the trunk its modules follow: merged there The commit's note under `refs/notes/mesh-plan` keeps every transition of this change up to its merge: `git log --notes=mesh-plan`.
mesh-tools merged commit 2fcd61baa6 into main 2026-11-05 10:48:58 +00:00
mesh-tools deleted branch fix/1585-pending-by-reference 2026-11-05 10:48:58 +00:00
Sign in to join this conversation.
No Reviewers
No labels
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: novox/mesh-delivery#154