Package org.a2aproject.sdk.transport.grpc.handler
@NullMarked
package org.a2aproject.sdk.transport.grpc.handler
gRPC transport handler implementations for the A2A protocol.
This package contains the core gRPC handler that processes gRPC requests and translates them to A2A protocol operations. It supports both unary (blocking) and streaming responses with proper gRPC error handling and status codes.
gRPC Protocol
This implementation uses Protocol Buffers for message serialization and provides:
- Unary RPC calls for blocking operations
- Server streaming RPC for streaming responses
- Rich error handling with gRPC status codes
- Context-aware metadata extraction
Supported Methods
SendMessage- Send message (unary/blocking)SendStreamingMessage- Send message (server streaming)SubscribeToTask- Subscribe to task updates (server streaming)GetTask- Get task by IDListTasks- List tasks with filteringCancelTask- Cancel task executionGetTaskPushNotificationConfig- Get push notification configCreateTaskPushNotificationConfig- Create push notification configListTaskPushNotificationConfigs- List push notification configsDeleteTaskPushNotificationConfig- Delete push notification configGetExtendedAgentCard- Get extended agent card
Context Access
The gRPC handler provides rich context information equivalent to Python's
grpc.aio.ServicerContext, including:
- Request metadata (headers)
- Method name
- Peer information
- A2A protocol version and extensions
- See Also:
-
ClassDescriptionFactory interface for creating
ServerCallContextfrom gRPC request context.gRPC transport handler for processing A2A protocol requests.