Skip to content

fix: propagate A2A request metadata into the run config in AgentExecutor#1345

Open
copybara-service[bot] wants to merge 1 commit into
mainfrom
test_945055254
Open

fix: propagate A2A request metadata into the run config in AgentExecutor#1345
copybara-service[bot] wants to merge 1 commit into
mainfrom
test_945055254

Conversation

@copybara-service

Copy link
Copy Markdown

fix: propagate A2A request metadata into the run config in AgentExecutor

During A2A communication, AgentExecutor invoked the 4-argument
Runner.runAsync, which hardcodes stateDelta = null and silently dropped the
caller's incoming request metadata.

Route the incoming request metadata (RequestContext.getParams().metadata())
into RunConfig.customMetadata under the a2a_metadata key, so downstream
processing can read it. This mirrors ADK Python and Go, which pass A2A request
metadata through the run config and leave the session state delta null, rather
than writing framework IDs into session state. Add tests for the metadata and
no-metadata cases.

…utor`

During A2A communication, `AgentExecutor` invoked the 4-argument
`Runner.runAsync`, which hardcodes `stateDelta = null` and silently dropped the
caller's incoming request metadata.

Route the incoming request metadata (`RequestContext.getParams().metadata()`)
into `RunConfig.customMetadata` under the `a2a_metadata` key, so downstream
processing can read it. This mirrors ADK Python and Go, which pass A2A request
metadata through the run config and leave the session state delta null, rather
than writing framework IDs into session state. Add tests for the metadata and
no-metadata cases.

PiperOrigin-RevId: 945055254
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