New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

startupHealthcheck doesn't respect SetHttpClient() #225

Closed
nickw444 opened this Issue Feb 10, 2016 · 1 comment

Comments

Projects
None yet
2 participants
@nickw444

nickw444 commented Feb 10, 2016

When using newClient and providing a custom HTTP client, the connection initiated within startupHealthcheck doesn't use the provided HTTP client, instead, a new http.Client is instantiated, thus any provided HTTP connection configuration is neglected.

Offending line appears within client.go:946

...
start := time.Now()
for {
    cl := &http.Client{Timeout: timeout}
    for _, url := range urls {
...

The current use case for this is to provide a self provided CA root cert, which is provided to our http.Client. Since the health check does not use this http client, it will fail.

@olivere

This comment has been minimized.

Owner

olivere commented Feb 10, 2016

@nickw444 Ah, I see. Sounds like a bug to me. Thanks for reporting. Will take me a few days however; currently on a business trip.

@olivere olivere closed this in f6550f7 Feb 27, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment