Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

[Feat]: Add Android support for A2A HTTP Client and decouple JdkA2AHttpClient (v0.3.x)

Đang mở
#793 12 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
45/100
Loại issue
Tính năng
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Ít trao đổi
Công nghệ
android
Lĩnh vực
backend-api-design, mobile

Hướng nghiên cứu

Issue đề cập đến JdkA2AHttpClient được hardcode trong A2A.java và các transport provider. Trước tiên, hãy kiểm tra cấu trúc của module http-client và client hiện có. Tìm pattern ServiceLoader (SPI) để hiểu cách triển khai A2AHttpClientFactory. Các record trong module spec/ cần các annotation @JsonProperty. 'Done' có nghĩa là SDK hoạt động trên Android với một AndroidA2AHttpClient mới và các bản sửa lỗi Jackson đã được áp dụng.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

Is your feature request related to a problem? Please describe.

Problem

Currently, the A2A Java SDK hardcodes the use of JdkA2AHttpClient in several places (such as A2A.java and various transport providers). This client relies on java.net.http.HttpClient, which is not available in standard Android environments, making the SDK unusable on Android.
Additionally, when running on Android, Jackson fails to deserialize Java records properly without explicit property annotations, leading to parsing errors for spec models.

Describe the solution you'd like

Proposed Solution

  • SPI Pattern: Introduce A2AHttpClientFactory and A2AHttpClientProvider using Java's ServiceLoader (SPI) to dynamically load the best HTTP client available on the classpath.
  • Android Client: Implement AndroidA2AHttpClient using HttpURLConnection (which is safe for Android).
  • Jackson Fixes: Add @JsonProperty annotations to records in the spec/ module to ensure they can be parsed on Android.
Describe alternatives you've considered

No response

Additional context

Goal

The goal is to make the http-client module compatible with Android by:

  1. Decoupling the HTTP client implementation so it is not hardcoded to the JDK client.
  2. Providing an Android-compatible HTTP client implementation.
  3. Fixing the Jackson parsing issues for records on Android.
Code of Conduct
  • I agree to follow this project's Code of Conduct
Ngôn ngữ chính
Java
Star
504
Fork
184
Merge trung bình
1 ngày 13 giờ
Pull request đã merge (30 ngày)
31

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của a2aproject/a2a-java

Tất cả issue của a2aproject/a2a-java

Issue tương tự

Thêm issue về Java

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.