Repository navigation
Reuse keepalive HTTP transports - #59
Merged
Merged
Conversation
jiegec
reviewed
Oct 1, 2026
jiegec
reviewed
Oct 1, 2026
| &cli.BoolFlag{Name: "daemonize", Aliases: []string{"D"}, Usage: "run without reading username/password from standard input; less log"}, | ||
| &cli.BoolFlag{Name: "debug", Usage: "print debug messages"}, | ||
| &cli.BoolFlag{Name: "help, h", Usage: "print the help"}, | ||
| &cli.BoolFlag{Name: "help", Aliases: []string{"h"}, Usage: "print the help"}, |
marvil6
force-pushed
the
perf/reuse-keepalive-transports
branch
from
October 2, 2026 01:21
5ec3bf2 to
b8dc88e
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Create one HTTP client per address family for each keepalive run. Reuse those clients for periodic HEAD requests, then stop the IPv6 worker and close idle connections on exit. Tests cover IPv4 and IPv6 over HTTP and HTTPS, forced network selection, and worker shutdown.
Verification:
go test ./...,go vet ./..., 100 repeated targeted test runs, 20 full race-detector runs, and Linux/macOS/Windows builds pass. In a five-run local benchmark, median HTTPS request time fell from 1.52 ms to 37 µs; each 500-request reused-transport run opened one connection instead of 500 (loopback measurements).Fixes #58