Skip to content

Add pipelined artifact receivers - #562

Draft
haoweiyu-kumo wants to merge 1 commit into
split/pr203-03-worker-placementfrom
split/pr203-04-artifact-receiver
Draft

haoweiyu-kumo wants to merge 1 commit into
split/pr203-03-worker-placementfrom
split/pr203-04-artifact-receiver

Conversation

@haoweiyu-kumo

@haoweiyu-kumo haoweiyu-kumo commented Nov 30, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Add a regular ArtifactReceiver component with publication-scoped download pools, checksum verification, inventory barriers, and abort cleanup. Replicator broadcasts completed uploads without introducing an Engine dependency.

Part 4/7 of the #203 stack. Review against the listed base; later PRs are not required for this layer.

Change map

Maintained file-by-file change map.

Testing Done

26 distributed placement/receiver tests passed.

Stack

  1. Share snapshot and training-table publication with MLOps
  2. Restore connector identities after serialization
  3. Add reusable Ray worker placement
  4. Add pipelined artifact receivers — this PR
  5. Add portable graph and training-table handles
  6. Compose Engine artifact production with the shared receiver
  7. Integrate remote artifact preparation with ComputeCluster

#563 is consolidated into #559. Remote sampling remains in #483.

@copy-pr-bot

copy-pr-bot Bot commented Nov 30, 2026

Copy link
Copy Markdown

This pull request requires additional validation before any workflows can run on NVIDIA's runners.

Pull request vetters can view their responsibilities here.

Contributors can view more details about this message here.

@haoweiyu-kumo
haoweiyu-kumo temporarily deployed to gha-kumo-workflow-tests November 30, 2026 23:47 — with GitHub Actions Inactive
@coderabbitai

coderabbitai Bot commented Nov 30, 2026 •

Copy link
Copy Markdown

Important

Draft PR not reviewed

Draft PRs are not automatically reviewed by default.

  • Trigger a manual review

To automatically review draft PRs, update your CodeRabbit configuration:

reviews:
  auto_review:
    drafts: true

Note

.coderabbit.yaml has unrecognized properties

CodeRabbit is using all valid settings from your configuration. Unrecognized properties (listed below) have been ignored and may indicate typos or deprecated fields that can be removed.

Parsing warnings: 1

Validation error: Unrecognized key: "tone_instructions" at "reviews"
Configuration instructions

  • Please see the configuration documentation for more information.
  • You can also validate your configuration using the online YAML validator.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json
Pre-merge checks: Passed 2 · Failed 1

Failed Failed checks: 1 warning

Check name Status Explanation Resolution
Change Map Design Review Warning The change map is the provider-reported comment with marker <!-- kumo-pr-change-map --> on PR #562 (NVIDIA/kumo-engine, author haoweiyu-kumo). It has two table rows: replication.py (Replicator; Ar… Correct the change map comment (marker <!-- kumo-pr-change-map -->, issuecomment-7295540654) as follows: 1. Split the replication.py row by function or class member: - Replicator.__init__, uploaded, finish, __exit__: sends begin…
Passed Passed checks: 2 passed

Check name Status Explanation
Pr Size Passed The PR size check passes. The file count is 2, which does not exceed the threshold of 40. Evidence: - The local checkout is at HEAD fdf8ecd ("Add publication-scoped parallel artifact receivers"). Its …
Public Resource Access Passed The check applies only to external resource references (URLs, repository locations, package source locations) added or modified by this pull request. I compared the checked-out head commit (fdf8ecd, "…
Full details: Pr Size

Explanation

The PR size check passes. The file count is 2, which does not exceed the threshold of 40. Evidence: - The local checkout is at HEAD fdf8ecd ("Add publication-scoped parallel artifact receivers"). Its parent is 8498963 ("Add reusable remote node placement and worker ownership"), which matches the base PR's content (#561). - git diff --name-status -M HEAD^ HEAD lists two added files: packages/kumo-core/src/kumo_core/distributed/replication.py and packages/kumo-core/tests/distributed/test_replication.py. - The count is the same with rename detection disabled (--no-renames). Caveat: the base branch split/pr203-03-worker-placement is not present locally. The count assumes the local parent commit is the PR base. The provider-side diff was not checked, so this count could differ from the provider's file list. The result would change only if the provider diff exceeded 40 files, which is unlikely for a two-file local diff. Ignoring line counts, as the check requires.

Full details: Public Resource Access

Explanation

The check applies only to external resource references (URLs, repository locations, package source locations) added or modified by this pull request. I compared the checked-out head commit (fdf8ecd, "Add publication-scoped parallel artifact receivers") with its parent (8498963, "Add reusable remote node placement and worker ownership"). The parent matches the stack's base PR #561. The diff touches only two files: packages/kumo-core/src/kumo_core/distributed/replication.py (+261) and packages/kumo-core/tests/distributed/test_replication.py (+170). A search of every added line for http(s) URLs, git/ssh URLs, package index or find-links settings, registry or artifact hosts, bucket URIs, and hosting domains found no matches. The only added lines that name external code are Python imports of ray, pyarrow, and kumo_core modules. Those are code dependencies, not URLs or package source locations, and the diff does not change any dependency manifest or lockfile. No external resource reference was added or modified, so the check passes.

Full details: Change Map Design Review

Explanation

The change map is the provider-reported comment with marker &lt;!-- kumo-pr-change-map --&gt; on PR #562 (NVIDIA/kumo-engine, author haoweiyu-kumo). It has two table rows: replication.py (Replicator; ArtifactReceiver) and test_replication.py (focused regression coverage). The diff against base 8498963 adds 431 lines in those two files. Both files are new. The change size is under 1000 lines, so the map should describe function or scope-level changes. Substantive design issues: 1. Misattributed responsibility. The row says "Replicator; ArtifactReceiver: Queue verified downloads and drain publication state." In replication.py, Replicator only sends begin, receive, complete, and abort RPCs to peers. Only ArtifactReceiver.receive calls downloads.pool.submit(...). The map gives the download queue to the wrong component. 2. Scope claims not reflected in the table. The Scope names "checksum verification," "inventory barriers," and "abort cleanup." The table does not describe any of them. The code does provide the first two. download_file in kumo_core/io/artifact.py checks size and SHA-256 before os.replace. ArtifactReceiver.seal raises when the scheduled files differ from the producer inventory. 3. "Abort cleanup" is not clearly supported by the code. ArtifactReceiver.abort pops the publication, then calls pool.shutdown(wait=True, cancel_futures=True). It does not remove root/downloads/&lt;publication&gt;. Files that finished before the abort stay on the node-local scratch root. This may be intended. The map should either state that files are retained, or the code should delete the publication directory on abort. This is an open design question, not a proven defect. 4. Material behavior omitted. - Replicator.__init__ drops any peer whose begin fails. It logs the error and continues with fewer peers. - Replicator.finish logs complete failures and returns. The producer does not raise. Recovery depends on a later readiness check against shared storage. The docstring states this, but the map does not. - Replicator.uploaded waits on ray.get for pending notifications while it holds self._lock (flush at 128 per peer). - ArtifactReceiver.seal removes the publication from _downloads before it validates the inventory. A failed seal cannot be retried. 5. No observed failure or inspected existing behavior. The "Requirement" line describes the whole stack. It names no observed failure in this layer. It does not explain why the existing kumo-engine artifact path (for example _artifact_io.py, which already calls download_file) cannot serve the receiver role. The map should state that comparison. 6. Vague test row. "focused regression coverage" and "Verify this layer and its compatibility boundaries" do not name the behavior covered. The five tests cover streaming overlap, inventory and checksum failure, unfinished-producer abort, notification failure not retried, and CPU budget. None is labeled as a compatibility test. "Catch failures without requiring subsequent PRs" is a stacking note, not a design reason. 7. Stopping condition and unwired layer. In this commit, Replicator and ArtifactReceiver are referenced only by test_replication.py. No production caller exists yet. The map does not say so. It also does not name the peer RPC contract (begin, receive, complete, abort) that the containing actor must provide in a later PR. That contract is the real compatibility boundary. Verified claims: the Replicator is free of Engine imports (it imports only kumo_core, ray, and pyarrow). The "26 tests passed" claim was not reproduced, because build and test tools are not available in this sandbox. I could not retrieve the previous failure details, so I did not dispose of them. This FAIL rests on the current map and code.

Resolution

Correct the change map comment (marker &lt;!-- kumo-pr-change-map --&gt;, issuecomment-7295540654) as follows: 1. Split the replication.py row by function or class member: - Replicator.__init__, uploaded, finish, __exit__: sends begin, receive, complete, and abort RPCs to peers. Notification batching is 128 per peer. Failed peers are dropped. Complete failures are logged and not raised. - ArtifactReceiver.begin, receive, _download: opens a publication-scoped pool and queues verified downloads. - ArtifactReceiver.seal: enforces the exact inventory barrier and returns the directory. - ArtifactReceiver.abort: drains the pool. State whether completed files are retained or removed. 2. Name the peer RPC contract (begin, receive, complete, abort) and say which later PR supplies the containing actor. 3. State that no production caller exists in this PR. Name the test that exercises finish. 4. Replace "focused regression coverage" with the five named behaviors from test_replication.py. Remove the stacking rationale. 5. Add the observed failure or the release requirement. State why kumo_core.io.artifact.download_file and the existing _artifact_io.py path are or are not sufficient. Then either change the code or change the Scope text so that "abort cleanup" matches the actual abort behavior. Decide whether abort should remove root/downloads/&lt;publication&gt;. Decide whether a failed seal should keep the publication open for retry.

  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

@haoweiyu-kumo

haoweiyu-kumo commented Nov 30, 2026 •

Copy link
Copy Markdown
Collaborator Author

Change map

Requirement: Share artifact publication across MLOps and compute workers through a stack of separately reviewable changes.

Scope: Add a regular ArtifactReceiver component with publication-scoped download pools, checksum verification, inventory barriers, and abort cleanup. Replicator broadcasts completed uploads without introducing an Engine dependency.

Verification: 26 distributed placement/receiver tests passed.

File Function / scope What changed Why
packages/kumo-core/src/kumo_core/distributed/replication.py Replicator; ArtifactReceiver Queue verified downloads and drain publication state Overlap uploads and downloads without exposing incomplete artifacts
packages/kumo-core/tests/distributed/test_replication.py focused regression coverage Verify this layer and its compatibility boundaries Catch failures without requiring subsequent PRs

@haoweiyu-kumo
haoweiyu-kumo force-pushed the split/pr203-04-artifact-receiver branch from fdf8ecd to b331339 Compare December 1, 2026 23:31
@haoweiyu-kumo
haoweiyu-kumo force-pushed the split/pr203-03-worker-placement branch from 8498963 to abf8a15 Compare December 1, 2026 23:31
@haoweiyu-kumo
haoweiyu-kumo temporarily deployed to gha-kumo-workflow-tests December 1, 2026 23:32 — with GitHub Actions Inactive

This branch was previously deployed

1 inactive deployment
gha-kumo-workflow-tests — b331339b Deployed Dec 1, 2026 by haoweiyu-kumo via import #3531
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