expose DatabaseScanner::ingest_batch as public ingestion API#3358
Open
shayne-fletcher wants to merge 5 commits intometa-pytorch:mainfrom
Open
expose DatabaseScanner::ingest_batch as public ingestion API#3358shayne-fletcher wants to merge 5 commits intometa-pytorch:mainfrom
shayne-fletcher wants to merge 5 commits intometa-pytorch:mainfrom
Conversation
Summary: pesky lints. we hates them precious. Differential Revision: D99460173
…eta-pytorch#3353) Summary: this diff adds the monarch_introspection_snapshot conversion layer from typed mesh-admin NodePayload values into the normalized snapshot row schema. it introduces convert.rs, with a typed ConvertedNode / NodeKindRow algebra, one conversion entry point for all node variants, link-level child classification, fallible time conversion to microseconds, and focused conversion tests covering subtype selection, failure projection, child ordering, child classification, and the fact that parent is not materialized into the snapshot schema. it also tightens and corrects the source invariants in hyperactor_mesh that the snapshot projection depends on. in particular, it fixes the navigation docs to distinguish canonical containment parent from the admin navigation graph, records the link-classification invariants for system_children and stopped_children, removes stale root-node documentation, and adds assertions for the root and host empty-classification cases. the snapshot schema docs are updated to explain that ChildRow models the admin navigation graph rather than a strict tree, and the snapshot crate docs and BUCK deps are updated accordingly. Differential Revision: D99452318
…t with proc membership (meta-pytorch#3355) Summary: this diff adds a live integration proof for the mesh-admin supervision invariants over the existing Rust sieve workload. it extends mesh_admin_integration with a new supervision.rs scenario that launches sieve, discovers a concrete proc -> actor A -> actor B chain, and proves the two intended facts together: actor-to-actor supervision edges and proc-to-actor membership edges coexist in children, while resolving B still yields parent = Some(NodeRef::Proc(...)) rather than the supervising actor. it also wires the new proof into the integration suite by adding the sieve binary as a Buck resource, exposing it from the test harness, and registering the new MIT-71 / MIT-72 invariants and test entrypoint in main.rs. the test is kept typed internally, filters explicitly to sieve actors, and uses bounded readiness/retry constants so the proof remains focused on the NI-2 / NI-3 contract rather than incidental topology details. Differential Revision: D99456727
…set dedup (meta-pytorch#3357) Summary: this diff adds the capture layer in monarch_introspection_snapshot. it introduces capture.rs, defines SnapshotData as the typed per-snapshot accumulator, and adds capture_snapshot, which performs a bfs from NodeRef::Root, resolves each typed node reference at most once, projects each NodePayload through the existing convert_node path, and folds the result through a single SnapshotData::push_converted seam. the traversal stays imperative, while subtype routing is confined to the fold target. the new module also documents and tests the capture invariants directly. the tests use stub resolvers rather than a live mesh and cover the intended semantics: one snapshot row per capture, capture-start timestamp distinct from node as_of, typed visited-set dedup, per-parent edge emission order, duplicate nodes producing one node row but multiple child edges, full NodeKindRow routing through the fold seam, resolver failures aborting capture, and successfully resolved NodeProperties::Error payloads producing ResolutionErrorRow rather than failing capture. lib.rs, BUCK, and the shared to_micros visibility were updated accordingly to wire the new module in cleanly. Differential Revision: D99473110
Summary: this diff adds the narrow public ingestion seam needed by the snapshot bridge without changing telemetry ingestion semantics. it exposes DatabaseScanner::ingest_batch as a thin public wrapper over the existing internal named-batch insertion path, keeping ingestion ownership in monarch_distributed_telemetry while avoiding direct construction or manipulation of LiveTableData from the bridge crate. it also adds focused unit tests that pin down the contract of that public seam: first ingest creates a table from the batch schema, empty batches still register schema without appending rows, repeated ingests to the same table reuse the existing entry and accumulate rows, and the “empty first, non-empty later” path works correctly. that empty-batch schema-registration behavior is the key guarantee the snapshot ingestion path needs so all snapshot tables can be registered in DataFusion even when a given capture has zero rows for some table. Differential Revision: D99477096
|
@shayne-fletcher has exported this pull request. If you are a Meta employee, you can view the originating Diff in D99477096. |
shayne-fletcher
added a commit
to shayne-fletcher/monarch-1
that referenced
this pull request
Apr 3, 2026
…torch#3358) Summary: this diff adds the narrow public ingestion seam needed by the snapshot bridge without changing telemetry ingestion semantics. it exposes DatabaseScanner::ingest_batch as a thin public wrapper over the existing internal named-batch insertion path, keeping ingestion ownership in monarch_distributed_telemetry while avoiding direct construction or manipulation of LiveTableData from the bridge crate. it also adds focused unit tests that pin down the contract of that public seam: first ingest creates a table from the batch schema, empty batches still register schema without appending rows, repeated ingests to the same table reuse the existing entry and accumulate rows, and the “empty first, non-empty later” path works correctly. that empty-batch schema-registration behavior is the key guarantee the snapshot ingestion path needs so all snapshot tables can be registered in DataFusion even when a given capture has zero rows for some table. Differential Revision: D99477096
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary:
this diff adds the narrow public ingestion seam needed by the snapshot bridge without changing telemetry ingestion semantics. it exposes DatabaseScanner::ingest_batch as a thin public wrapper over the existing internal named-batch insertion path, keeping ingestion ownership in monarch_distributed_telemetry while avoiding direct construction or manipulation of LiveTableData from the bridge crate.
it also adds focused unit tests that pin down the contract of that public seam: first ingest creates a table from the batch schema, empty batches still register schema without appending rows, repeated ingests to the same table reuse the existing entry and accumulate rows, and the “empty first, non-empty later” path works correctly. that empty-batch schema-registration behavior is the key guarantee the snapshot ingestion path needs so all snapshot tables can be registered in DataFusion even when a given capture has zero rows for some table.
Differential Revision: D99477096