Skip to content

FIX: report the SOCKS frontend's outcomes to the health check - #26

Merged
mclueppers merged 1 commit into
mainfrom
socks-health-tracking
Aug 5, 2026
Merged

FIX: report the SOCKS frontend's outcomes to the health check#26
mclueppers merged 1 commit into
mainfrom
socks-health-tracking

Conversation

@mclueppers

Copy link
Copy Markdown

Health tracking was wired into the goproxy response hook only, so a proxy serving SOCKS alone never recorded anything: it started healthy and stayed healthy however many connections failed, and /health answered 200 regardless. The endpoint was a liveness check rather than a health one for that deployment.

The frontend reports on what it was asked to do, which is reach the target: opening a tunnel is a success and failing to dial one is a failure. A client refused before the proxy tried to reach anything, by its password, its network or the port it asked for, records nothing, since that says something about the client rather than about this proxy's ability to reach the world.

That leaves the two frontends counting slightly different things: the HTTP one still treats a 407 as a failure, inherited from the original health check, where the challenge may have come from an upstream proxy with stale credentials or from this proxy challenging its own client. The difference is documented rather than smoothed over, since changing it would change behaviour that is already deployed.

Health tracking was wired into the goproxy response hook only, so a proxy
serving SOCKS alone never recorded anything: it started healthy and
stayed healthy however many connections failed, and /health answered 200
regardless. The endpoint was a liveness check rather than a health one
for that deployment.

The frontend reports on what it was asked to do, which is reach the
target: opening a tunnel is a success and failing to dial one is a
failure. A client refused before the proxy tried to reach anything, by
its password, its network or the port it asked for, records nothing,
since that says something about the client rather than about this
proxy's ability to reach the world.

That leaves the two frontends counting slightly different things: the
HTTP one still treats a 407 as a failure, inherited from the original
health check, where the challenge may have come from an upstream proxy
with stale credentials or from this proxy challenging its own client.
The difference is documented rather than smoothed over, since changing
it would change behaviour that is already deployed.
@mclueppers
mclueppers merged commit 00d79b2 into main Aug 5, 2026
2 checks passed
@mclueppers
mclueppers deleted the socks-health-tracking branch August 5, 2026 09:50
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