Skip to content

ci(grpc): provision protobuf tools and stabilize daemon checks - #1632

Merged
willkill07 merged 8 commits into
mainfrom
feat/relay-1184-ci
Nov 4, 2026
Merged

willkill07 merged 8 commits into
mainfrom
feat/relay-1184-ci

Conversation

@willkill07

@willkill07 willkill07 commented Nov 3, 2026 •

Copy link
Copy Markdown
Member

Overview

Provision protobuf build prerequisites and make daemon provider checks deterministic before adding validation dependencies. This is the bottom layer of the worker protocol stack and supersedes #1627.

  • I confirm this contribution is my own work, or I have the right to submit it under this project's license.
  • I searched existing issues and open pull requests, and this does not duplicate existing work.

Details

  • Export the pinned Buf and Protoc versions from the shared CI configuration action. Protoc 31.1 matches the crate’s vendored compiler and is required by the validation dependency’s own build script.
  • Install Buf and Protoc for Rust, Python, Node, Go, pre-commit, and documentation jobs.
  • Make Buf, the statically linked Protoc executable, and its Google protobuf include files available inside Rust and Python Linux build containers.
  • Document both build prerequisites in CONTRIBUTING.md and provision them for source Quick Starts.
  • Route workspace-root and worker-module Buf policy/lockfiles to the relevant checks. Skip source-tool setup in musl wheel smoke tests and historical docs tags without Buf/Protoc version outputs.
  • Avoid synchronous TLS trust-store setup for plaintext provider dispatch; keep the no-replay HTTP policy.
  • Bind HTTP-policy fixtures locally instead of selecting a VPN interface, prepare deadline-test clients outside timed work, and isolate Python tests from installed system plugins.

Validation: provider/deadline/transport regressions passed with retries disabled, including five fresh-process iterations each of both cancellation checks and the plaintext routing guard. Scoped hooks, actionlint, clippy, cargo check, and dependency audits passed; the advisory audit used a fresh isolated RustSec cache. The combined adoption head also passed 6,643 Rust tests without retries and the canonical Python suite. GitHub CI is pending.

Where should the reviewer start?

.github/actions/load-ci-tool-versions/action.yml, then .github/workflows/ci_rust.yml and .github/workflows/ci_python.yml for container handling. The second commit covers crates/cli/src/daemon/common/transport.rs and its local-provider test fixtures.

Related Issues: (use one of the action keywords Closes / Fixes / Resolves / Relates to)

  • Relates to: RELAY-1184

Summary by CodeRabbit

  • Bug Fixes
    • Remote HTTP provider requests now use a plaintext-only connection path, allowing them to succeed without initializing TLS support.
  • Chores
    • CI workflows now install pinned versions of Protoc and Buf for checks, tests, packaging, quick starts, and documentation builds.
    • Linux packaging builds make these tools and Protoc’s required include files available inside build containers.
    • CI path filters now account for Protocol Buffers dependency and configuration files.
  • Documentation
    • Source development requirements now list Protoc 31.1 or later and Buf 1.75.0 or later.

@willkill07
willkill07 requested a review from a team as a code owner November 3, 2026 21:31
@coderabbitai

coderabbitai Bot commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

Explain Change →

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • Resume reviews
  • Trigger review

No actionable comments were generated in the recent review.

Walkthrough

The pull request pins Protoc and Buf versions for CI, installs them in workflows, and updates Buf-related path filters. It changes remote HTTP provider routing to use a cached plaintext client and updates related tests. The Python test command now exports a temporary system configuration directory.

Changes

Protoc and Buf CI setup

Layer / File(s) Summary
Version configuration and outputs
.github/ci-tool-versions.env, .github/actions/load-ci-tool-versions/action.yml, CONTRIBUTING.md
CI pins Buf 1.75.0 and Protoc 31.1. The action validates and exposes both versions. Source development requirements list minimum versions.
Workflow tool installation
.github/workflows/ci_check.yml, .github/workflows/ci_go.yml, .github/workflows/ci_node.yml, .github/workflows/ci_python.yml, .github/workflows/ci_rust.yml, .github/workflows/fern-docs.yml, .github/workflows/quickstarts.yml
The workflows install the configured tools. Linux package builds mount Buf, Protoc, and Protoc’s Google include files into their build containers.
Buf change path filters
.github/ci-path-filters.yml
The filters include Buf lockfile changes. The Python filter also includes Buf policy and dependency-resolver files.

Remote HTTP provider transport

Layer / File(s) Summary
Plaintext client and request routing
crates/cli/src/daemon/common/transport.rs
Eligible remote HTTP provider requests use a cached HTTP-only client. Client-named and other requests retain their existing routing.
HTTP transport tests and helpers
crates/cli/tests/coverage/daemon/transport_tests.rs, crates/cli/tests/coverage/daemon/server_tests.rs, crates/cli/tests/coverage/daemon/worker_managed_tests.rs, crates/cli/tests/coverage/daemon/worker_runtime_tests.rs, crates/cli/tests/coverage/shared/test_support.rs, crates/cli/tests/coverage/shared/websocket_tests.rs
A subprocess test checks plaintext requests without initializing the default rustls crypto provider. The HTTP test helper binds to 127.0.0.1 and uses a localhost. authority. Related tests update host allowlists and pooled-client setup.

Python test environment

Layer / File(s) Summary
Temporary system configuration
justfile
The test-python command creates a temporary system configuration directory and exports its path through NEMO_RELAY_TEST_SYSTEM_CONFIG_DIR.

Estimated code review effort: 3 (Moderate) | ~25 minutes

Change: Other

Merge Risk: Minimal · up to 79a2b

No concrete current-head correctness, availability, or validation failure remains; the change is mergeable with normal CI checks.

Pre-merge checks: Passed 4 · Failed 1

Failed Failed checks: 1 warning

Check name Status Explanation Resolution
Docstring Coverage Warning Docstring coverage is 30.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documenta… Write docstrings for the functions missing them to satisfy the coverage threshold.
Passed Passed checks: 4 passed
Check name Status Explanation
Title check Passed The title follows Conventional Commits format with the lowercase type and scope ci(grpc), uses an imperative summary, stays under 72 characters, and has no trailing period.
Description check Passed The description includes the required Overview, Details, reviewer-start, and Related Issues sections. It provides specific implementation details, validation results, and a Relates to issue referenc…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Description check

Explanation

The description includes the required Overview, Details, reviewer-start, and Related Issues sections. It provides specific implementation details, validation results, and a Relates to issue reference. The checklist items are completed.

Full details: Docstring Coverage

Explanation

Docstring coverage is 30.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 10 functions across 8 files. (1 skipped: 1 unsupported.)

Resolution

Write docstrings for the functions missing them to satisfy the coverage threshold.

Finishing Touches
Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Recent review info
Run configuration
Commits

Reviewing files that changed from the base of the PR and between e67a290 and 79a2b44.

Files selected for processing: 1
  • CONTRIBUTING.md

Included review availability: This review used your included allowance. Your plan provides up to 12 included reviews per hour; 8 remain after this review.

Recent review details
Context from checks skipped due to timeout: 2
  • GitHub Check: Changes / Detect
  • GitHub Check: Detect docs changes
Additional context used
Code guidelines: 1
RELEASING.md — auto-discovered
Path-based instructions: 2
Review documentation for technical accuracy against the current API, command correctness, and consistency across language bindings.

CodeRabbit configuration file

Files:

  • CONTRIBUTING.md
Applicability reference: AGENTS.md: # NeMo Relay Repository Guidance Keep release-process policy in maintainer sources such as `RELEASING.md` and Source excerpt: Select documentation versions according to the intended audience and package a...

CodeRabbit inference engine (RELEASING.md)

Files:

  • CONTRIBUTING.md
Additional comments: 1
CONTRIBUTING.md: 1

31-32: LGTM!

@willkill07 willkill07 added this to the 1.0 milestone Nov 3, 2026
@willkill07 willkill07 self-assigned this Nov 3, 2026
@willkill07
willkill07 added this pull request to stack #1633 November 3, 2026 21:34
@willkill07 willkill07 changed the title ci: provision protobuf tools and stabilize daemon checks ci(grpc): provision protobuf tools and stabilize daemon checks Nov 3, 2026

@coderabbitai coderabbitai Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • Fix comments: Fix CodeRabbit comments on this PR

Comment thread .github/ci-path-filters.yml Resolved
Comment thread .github/workflows/ci_python.yml Resolved
Comment thread .github/workflows/fern-docs.yml Resolved
@github-actions github-actions Bot added size:M PR is medium Maintenance CI or Build or general repository maintenance lang:rust PR changes/introduces Rust code labels Nov 3, 2026
@github-actions

github-actions Bot commented Nov 3, 2026

Copy link
Copy Markdown

@mnajafian-nv mnajafian-nv left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@willkill07
willkill07 merged commit f22965c into main Nov 4, 2026
92 checks passed
greysonlalonde pushed a commit that referenced this pull request Nov 20, 2026
#### Overview

Unread model responses can exhaust the shared daemon-to-worker HTTP/2
response window, stalling hook verdicts while `/healthz` remains
healthy. Give hooks and readiness probes a separate persistent pool. The
regression starves hooks with eight unread responses before the fix and
completes hooks with 128 after it.

- [x] I confirm this contribution is my own work, or I have the right to
submit it under this project's license.
- [x] I searched existing issues and open pull requests, and this does
not duplicate existing work.

#### Details

- Preserve worker credentials, pinned TLS trust, streaming backpressure,
and cancellation cleanup.
- Cache model and hook pools together under the existing root-cache
bound; reuse both pools across requests.
- This adds a persistent connection when both traffic classes are used;
it does not shorten guardrail timeouts.

Validation: 30 focused transport/TLS tests, staged pre-commit hooks, and
docs checks passed. Full `NEXTEST_TEST_THREADS=4 just test-rust`: 6,724
passed, 4 failed, 4 skipped. The same four HTTP-model provider timeouts
reproduce on untouched release `6b7afd500` with workspace features; main
stabilizes those unrelated paths in #1632. Fern skipped authenticated
redirect checking.

#### Where should the reviewer start?

Start with `WorkerClientPool` in
`crates/cli/src/daemon/common/worker_tls.rs`, `forward_to_worker` in
`crates/cli/src/daemon/broker/server.rs`, and
`crates/cli/tests/coverage/daemon/hook_pool_isolation_tests.rs`. The
regression uses production worker staging.

#### Related Issues: (use one of the action keywords Closes / Fixes /
Resolves / Relates to)

- Relates to [AEP-278](https://linear.app/nvidia/issue/AEP-278). The
synthetic reproduction does not establish the original incident's
trigger.


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
<!-- coderabbit-ai-generated:v1 -->

## Summary by CodeRabbit

* **Reliability**
* Hook requests and worker readiness checks use connection pools
separate from model traffic, helping them remain responsive when model
responses are delayed or stalled.
* Separate pools retain the worker authentication and TLS trust settings
used for model traffic, and are reused rather than opened for each hook
request.
* Hook traffic uses its own connection pool for both cleartext and TLS
connections, with TLS connections isolated by trusted certificate.

* **Documentation**
* Updated the daemon architecture guide to explain connection separation
and its effects on traffic handling.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Signed-off-by: Bryan Bednarski <[email protected]>
@willkill07
willkill07 deleted the feat/relay-1184-ci branch November 24, 2026 15:27

This branch was previously deployed

1 inactive deployment
fern — 79a2b445 Deployed Nov 4, 2026 by willkill07 via Clean up docs preview #7004
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

lang:rust PR changes/introduces Rust code Maintenance CI or Build or general repository maintenance size:M PR is medium

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants