Skip to content

Migrate from A2A v0 to v1 (part 1) - #1921

Merged
EItanya merged 17 commits into
mainfrom
jetc/feat/a2a-v1-migration-a
Jun 8, 2026
Merged

EItanya merged 17 commits into
mainfrom
jetc/feat/a2a-v1-migration-a

Conversation

@supreme-gg-gg

@supreme-gg-gg supreme-gg-gg commented May 25, 2026

Copy link
Copy Markdown
Contributor

The 1st of 3 PRs for A2A v0 to v1 zero downtime migration. This will go into release 0.10.0

Makes the controller compatible with A2A v0 (trpc-a2a-go) and v1 (a2a-go) data and both v0 and v1 JSON-RPC routes / agent card routes depending on A2A-Version header (designed explicitly by the protocol for version negotiations). Replaces all internal usages of trpc-a2a-go with a2a-go except in data conversion code and CLI client code.

This ensure that the controller is compatible with old / existing agents and UI in A2A v0 and existing v0 data in db, while adding the capability to communicate with v1 agents and UI during upgrade as they are added in the next part.

Follows https://a2a-protocol.org/latest/whats-new-v1/#migration-strategy-recommendations and db conversion reuses as much of existing a2a backward compatible code as possible.

@chromatic-com

chromatic-com Bot commented May 25, 2026

Copy link
Copy Markdown

Warning

Testing paused

Monthly snapshot limit reached. Update your plan for additional snapshots and to resume testing.

@supreme-gg-gg
supreme-gg-gg force-pushed the jetc/feat/a2a-v1-migration-a branch 3 times, most recently from 4aae019 to 2cea435 Compare May 26, 2026 18:31

@supreme-gg-gg supreme-gg-gg May 26, 2026

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

For reviewer, tracing context injection and associated tests have been moved to client_interceptors.go and client_interceptor_test.go (also where auth headers injection happens)

@supreme-gg-gg
supreme-gg-gg force-pushed the jetc/feat/a2a-v1-migration-a branch from 8943aff to 6350578 Compare May 26, 2026 21:51
@supreme-gg-gg
supreme-gg-gg force-pushed the jetc/feat/a2a-v1-migration-a branch from 6350578 to d60eec4 Compare May 27, 2026 16:29

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

For reviewer, this is a modified version of existing https://github.com/kagent-dev/kagent/blob/main/go/core/internal/a2a/manager.go (removed) for very similar functionality

This new passthrough handler is simpler and forwards RPC methods directly to the client and avoids having to go through things like task lifecycle, task status, etc. that the old AgentExecutor would do, and fits better since the controller is just a proxy to upstream agent runtime that handles the real executor.

@supreme-gg-gg
supreme-gg-gg marked this pull request as ready for review May 27, 2026 16:47
Copilot AI review requested due to automatic review settings May 27, 2026 16:47
@supreme-gg-gg supreme-gg-gg changed the title [DNM] Migrate from A2A v0 to v1 (part 1) Migrate from A2A v0 to v1 (part 1) May 27, 2026

Copilot AI 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.

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

@supreme-gg-gg

Copy link
Copy Markdown
Contributor Author

@copilot review

@EItanya EItanya 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.

These changes look awesome overall!

Can you potentially create a unified TODO marker for all changes which need to go in as a part of this migration so that it's clear when a change will be handled by a future PR, or needs to be. That way we can just do ctrl + shift + f and find all of them.

Comment thread go/core/internal/a2a/a2a_registrar.go Outdated
Comment on lines +45 to +47
_ int,
_ int,
_ time.Duration,

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.

Does the new library not expose these? I remember these were very important to ensure larger streams/payloads weren't rejected

@supreme-gg-gg supreme-gg-gg May 28, 2026

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

The new library doesn't have direct options to set these, I think we can just use the default ones from the library, I found these:

const defaultRequestTimeout = 3 * time.Minute

// MaxSSETokenSize is the maximum size for SSE data lines (10MB).
// The default bufio.Scanner buffer of 64KB is insufficient for large payloads
MaxSSETokenSize = 10 * 1024 * 1024 // 10MB

I'll remove these parameters

Comment thread go/core/internal/a2a/client_interceptors.go
Comment thread go/core/internal/controller/translator/agent/utils.go
Signed-off-by: Jet Chiang <pokyuen.jetchiang-ext@solo.io>
Signed-off-by: Jet Chiang <pokyuen.jetchiang-ext@solo.io>
Signed-off-by: Jet Chiang <pokyuen.jetchiang-ext@solo.io>
Signed-off-by: Jet Chiang <pokyuen.jetchiang-ext@solo.io>
Signed-off-by: Jet Chiang <pokyuen.jetchiang-ext@solo.io>
Signed-off-by: Jet Chiang <pokyuen.jetchiang-ext@solo.io>
Signed-off-by: Jet Chiang <pokyuen.jetchiang-ext@solo.io>
Signed-off-by: Jet Chiang <pokyuen.jetchiang-ext@solo.io>
Signed-off-by: Jet Chiang <pokyuen.jetchiang-ext@solo.io>
Signed-off-by: Jet Chiang <pokyuen.jetchiang-ext@solo.io>
Signed-off-by: Jet Chiang <pokyuen.jetchiang-ext@solo.io>
Signed-off-by: Jet Chiang <pokyuen.jetchiang-ext@solo.io>
@supreme-gg-gg
supreme-gg-gg force-pushed the jetc/feat/a2a-v1-migration-a branch from 69e93c5 to 253191a Compare May 28, 2026 17:39
Signed-off-by: Jet Chiang <pokyuen.jetchiang-ext@solo.io>
@supreme-gg-gg
supreme-gg-gg requested a review from EItanya May 28, 2026 19:02
Signed-off-by: Jet Chiang <pokyuen.jetchiang-ext@solo.io>
@supreme-gg-gg
supreme-gg-gg force-pushed the jetc/feat/a2a-v1-migration-a branch from 9ee3809 to 670b5af Compare May 29, 2026 15:25
@jmhbh
jmhbh force-pushed the jetc/feat/a2a-v1-migration-a branch from 0eddee2 to 579d89f Compare June 8, 2026 18:40
jmhbh
jmhbh previously approved these changes Jun 8, 2026
@jmhbh
jmhbh dismissed their stale review June 8, 2026 18:54

need to fix bad merge conflicts

Signed-off-by: JM Huibonhoa <jm.huibonhoa@solo.io>
@jmhbh
jmhbh enabled auto-merge (squash) June 8, 2026 20:29
@EItanya
EItanya disabled auto-merge June 8, 2026 22:09
@EItanya
EItanya merged commit d39fa0b into main Jun 8, 2026
26 checks passed
@EItanya
EItanya deleted the jetc/feat/a2a-v1-migration-a branch June 8, 2026 22:10
EItanya added a commit that referenced this pull request Aug 7, 2026
## Summary

Close #1941 

This PR combines the changes of #1929 and #1936 and migrates all
Kagent's A2A integration surfaces (UI a2a-js client, CLI a2a-go client,
DB and REST API interfaces, declarative ADK in go and python, BYO
frameworks in python) from 0.3 and 1.0 dual-compatible (introduced in
#1921) to strictly v1.0. This paves the way for future work to
consolidate our A2A integration and develop the Kagent v1 APIs.

**This migration is not zero downtime and is not backward compatible,
and is intended to go into the next major version.** There is no
compatibility matrix for this. Your UI/CLI/custom client and all agents
must **ALL** be in v1.0 to work properly.

## Testing

Unit, integration, and E2E tests have been updated and ran successfully.
I have manually tested: using UI and CLI with Go declarative, Python
declarative, and BYO agents on K8s and Substrate.

For context, the A2A migration doc is
[here](https://github.com/a2aproject/a2a-python/tree/main/docs/migrations/v1_0)
(written for python sdk but generally applicable to go and js)

---------

Signed-off-by: Jet Chiang <pokyuen.jetchiang-ext@solo.io>
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.

4 participants