Skip to content

feat(client): add opt-in GET redirect following and expose via transport config - #1257

Merged
kabir merged 1 commit into
a2aproject:mainfrom
kabir:http-client-get-redirects
Nov 2, 2026
Merged

kabir merged 1 commit into
a2aproject:mainfrom
kabir:http-client-get-redirects

Conversation

@kabir

@kabir kabir commented Nov 2, 2026

Copy link
Copy Markdown
Collaborator

Add opt-in, one-hop redirect following for synchronous GET requests across the JDK, Vert.x, and Android HTTP clients, using the shared RedirectHeaderPolicy. Agent-card discovery enables this automatically.

Expose followRedirects(boolean) through JSON-RPC and REST transport configuration, and propagate it through the OpenTelemetry HTTP client wrapper. JDK GET, DELETE, and SSE requests use a client with native redirects disabled so redirect behavior stays under SDK control; streaming requests do not follow redirects.

Includes redirect and transport configuration tests and updated documentation. Validation is left to CI.

…ort config

- Add GetBuilder.followRedirects(boolean) to A2AHttpClient; JDK, Vert.x, and Android implement one SDK-managed hop filtered by RedirectHeaderPolicy
- JdkA2AHttpClient unconditionally bypasses native redirects for GET, DELETE, and SSE regardless of the supplied HttpClient policy
- Add followRedirects(boolean) to JSONRPCTransportConfigBuilder and RestTransportConfigBuilder and propagate through the transport chain
- A2ACardResolver enables GET redirect following for agent-card discovery

Signed-off-by: Emmanuel Hugonnet <ehugonne@redhat.com>
@kabir
kabir merged commit d16d765 into a2aproject:main Nov 2, 2026
15 checks passed
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.

3 participants