Commit fda6a81
compute: a shared-trace primitive for cross-thread arrangement reads
An arrangement is normally readable only from the timely worker that maintains
it, because its batches are `Rc`-backed and its trace handle is neither `Send`
nor `Sync`. This adds a publication point that carries `Arc`-backed batches
together with the trace's `since` and `upper`, so a reader on any thread can
mint a `Send` handle for the same arrangement and import it as a snapshot at a
chosen `as_of`. Nothing in the crate calls it yet, so the module is inert: it
compiles, its unit tests exercise publish, import, seal, and compaction
holdback, and no rendered dataflow reaches it.
The concrete `SharedOks*`/`SharedErrs*` type aliases live here rather than
alongside the registry that will consume them. They name a shared-trace handle
over `RowRowSpine` and `ErrSpine` and mention no registry type, so this is where
they belong.
`Published::diagnostics`, `note_writer_logical`, and `note_standing_hold` are
`pub` like the rest of the type's accessors. Scoping them to the crate would
make them unreachable for dead-code analysis while the only callers are the
tests.
Tests are out of line in `shared_trace/tests.rs`, per the convention in
`src/compute/AGENTS.md`.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>1 parent 87c4c30 commit fda6a81
3 files changed
Lines changed: 2499 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
| 24 | + | |
24 | 25 | | |
25 | 26 | | |
26 | 27 | | |
| |||
0 commit comments