Repository navigation
feat(server): finish async unary execution with native gRPC callbacks - #317
Merged
Merged
Conversation
MisterVVP
marked this pull request as draft
October 28, 2026 16:40
Owner
Author
|
@codex review this PR |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Codex Review: Didn't find any major issues. Can't wait for the next one! Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
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
Completes the remaining PR 3 and PR 4 scope of #268 in one PR, targeting
feat/async-server, as requested.Adds opt-in
AsyncGrpcServerTransportfor all nine unary RPCs. It connects the existing async engine to native gRPC callbacks, copies metadata/auth, propagates deadlines and cancellation, and queues application execution, stop observers, interceptors, and response finalization on the bounded SDK worker pool. Shared helpers preserve synchronous validation, status/ErrorInfo mapping, extension trailers, and ListTasks conversion.Adds explicit service shutdown, native lifecycle/concurrency tests, an installed-package consumer example, a platform availability guide, async unary TCK profiles for both stores, and reproducible sync/async thread and latency evidence. Existing synchronous registration remains available. Streaming, HTTP scheduling, outbound clients, and async database I/O remain outside #268.
Older gRPC releases receive the exported stable-callback API opt-in. Installed-package dependency discovery resolves gRPC before a Protobuf fallback, avoiding partial target exports. Request envelopes initialize the operation directly before payload conversion, and the server-deadline test disables the competing client timer.
The test and measurement clients use one explicitly polled completion queue per fixture, keeping client thread counts fixed across both service paths and supporting legacy Windows gRPC. Installed-consumer validation generates only the SDK configuration installed for the test. Windows scratch cleanup is best-effort when build tools retain directory handles; installation, build, and smoke-test errors still propagate. Lifecycle assertions are grouped into focused helpers so Ubuntu's GTest 1.14 macro expansions remain within the lint complexity limit.
Evidence
With two SDK workers and controller-held pending replies, 32/128 concurrent async requests used two application threads in both cases; the equivalent synchronous path used 32/128. Representative loopback p50/p95 values, configurations, limitations, and reproduction commands are in the new guide. The TCK adapter executes the existing synchronous fixture on bounded workers and is explicitly documented as a compatibility fixture.
Testing
A2A_VERIFY_POSTGRES=1 A2A_VERIFY_BUILD_DIR=build ./scripts/verify_changes.sh: 880 tests passed../scripts/run_clang_tidy.sh build: passed; lint uses a local cache keyed by translation-unit dependencies and tool/configuration inputs.pip-audit: no known vulnerabilities. Native OSV scan attempted but blocked by the environment's HTTP 403 policy forapi.osv.dev; no dependency versions changed.The previously authorized TCK baseline exception is retained: the upstream registry reports 80.9% MUST coverage (80.0% overall) because 21 MUST requirements have no upstream tests. All executable tests passed; this is not a claim of complete registered-requirement coverage. Local Linux GCC validation and all required CI checks, including Windows, macOS, sanitizers, conformance, performance, and CodeQL, passed on
768fde3.Authorship and AI usage
Checklist
./scripts/verify_changes.shpassed locally@MisterVVP ready for your review.