Skip to content
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

fix: change the type of httpCli to HTTPClient #12

Merged
merged 1 commit into from
Jun 4, 2024

Conversation

holyachon
Copy link
Contributor

PR about #11

I think type of httpClient in StoreClient is *http.Client, so user can't use those functions like SetResponseErrorHandler, SetRetry out of library code to wrap client.

I expect that after this change, user can write below code.

        httpClient := &http.Client{}
	client := SetRetry(httpClient, &JitterBackoff{}, ShouldRetryDefault)
	storeClient := NewStoreClientWithHTTPClient(&StoreConfig{...}, client)

Feel free to give your opinion that improves this PR or change the way of implementation.
Thank you.

@richzw richzw self-assigned this Jun 4, 2024
@richzw
Copy link
Owner

richzw commented Jun 4, 2024

Got it. Thank you very much for your detailed response and your PR.

LGTM.

@richzw richzw merged commit ca4efc5 into richzw:master Jun 4, 2024
1 check passed
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