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

Add nonProxyHosts to ProxyConfiguration

Đang mở
#3,585 0 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
48/100
Loại issue
Tính năng
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Ít trao đổi
Công nghệ
java
Lĩnh vực
api, backend, networking

Hướng nghiên cứu

Bắt đầu bằng cách xác định ProxyConfiguration và ClientConfigurations, sau đó theo dõi cách ProxySelector đi qua lớp Dialogue đến các HTTP client bên dưới. Xem xét cấu hình proxy hiện có và hành vi của API trước khi xử lý các tương tác giữa định dạng danh sách, quy tắc khớp, CIDR, SOCKS, mesh và DNS-refresh. Hoàn tất khi có thể cấu hình các host không dùng proxy và các request khớp sẽ bỏ qua proxy mà không làm hỏng các cấu hình hiện có.

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

Mô tả

There isn't currently a way to specify non-proxy hosts for conjure generated clients. This is an FR to add a configuration field for explicitly configuring no-proxy hosts (separate from #3166, which would pull from environment)

Add a new nonProxyHosts field to ProxyConfiguration, and change ClientConfigurations to produce a new ProxySelector that matches on the provided non-proxy hosts in order to determine whether to indicate passthrough or proxy. Since the ProxySelector is passed through the Dialogue layer to the underlying hc clients, no modifications should be needed for https outside c-j-r and the associated api.

While this should be a straightforward change, there are a number of things to discuss:

  • How should backcompat and rollout be handled? Since this is an additive change, it will not break compat with existing configuration. However, if a service were to have picked up non-proxy-hosts configuration via discovery and then roll back to a non-supported version, the proxy settings could either silently break or error out.
    • The first use cases will be with static non-proxy hosts that are introduced programmatically, which makes this a bit less of a concern.
  • Should the nonProxyHosts be a List or a String?
    • Using a List would be less confusing for end users, and would elide discussion around whether the string should be delimited by commas (no_proxy envvar) or pipe characters (java).
  • Should CIDR blocks be supported?
    • Initial implementation could just not support this and error out instead.
  • Should domain suffix matching require explicit asterisks like in the Java case?
    • It would probably make more sense to make this behave more like the no-proxy envvar and suffix match even without wildcards.
  • How should socks proxies and mesh be handled?
    • The best option might be to error out on configurations with a socks proxy or mesh is used with nonProxyHosts.

Some further investigation is required to determine how no-proxy will interact with Dialogue's custom DNS refreshing. Initial impression is that it should work with hostnames, but it probably won't work with IPs matching resolved hostnames (instead of other IPs), since the DNS resolution happens after the ProxySelector callback.

Ngôn ngữ chính
Java
Star
96
Fork
95
Merge trung bình
12 phút
Pull request đã merge (30 ngày)
55

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

  • Không có Dockerfile hay tệp Docker Compose
  • Có mẫu pull request
  • Không có hướng dẫn đóng góp

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 palantir/conjure-java-runtime

Tất cả issue của palantir/conjure-java-runtime

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.