Skip to content

fix: rotate explicit Build proxy pools per request - #811

Open
AmPlace wants to merge 2 commits into
chenyme:mainfrom
AmPlace:agent/build-proxy-pool-rotation
Open

fix: rotate explicit Build proxy pools per request#811
AmPlace wants to merge 2 commits into
chenyme:mainfrom
AmPlace:agent/build-proxy-pool-rotation

Conversation

@AmPlace

@AmPlace AmPlace commented Jul 28, 2026

Copy link
Copy Markdown
Contributor

What changed

  • mark explicit Build proxy-pool leases as requiring a fresh connection tunnel
  • disable connection reuse only for those Build requests
  • preserve keep-alive behavior for fixed proxies, Web/Console scopes, and account-bound proxy templates
  • add regression tests for the affected and unaffected paths

Root cause

Rotating proxy endpoints commonly choose an exit IP when a new CONNECT tunnel is established. The shared Build HTTP transport reused keep-alive/HTTP2 connections, so multiple requests could remain pinned to one exit even when the egress node was explicitly configured as a proxy pool.

Impact

Explicit Build proxy pools establish a fresh tunnel per request, matching their configured rotation semantics. The additional handshake cost is limited to this mode.

Checks

  • go test ./internal/application/account ./internal/application/gateway ./internal/infra/egress

@AmPlace
AmPlace marked this pull request as ready for review July 28, 2026 04:32
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.

2 participants