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

Added WithClientRequestName function #609

Merged
merged 2 commits into from Aug 5, 2019

Conversation

yklyahin
Copy link
Contributor

@yklyahin yklyahin commented Aug 2, 2019

I have not found a way to change the default function "ClientRequestName" in the middleware for HTTP client.

@axw
Copy link
Member

axw commented Aug 5, 2019

Thanks @lobotomist! Would you mind adding a test please?

@yklyahin
Copy link
Contributor Author

yklyahin commented Aug 5, 2019

@axw Sure. I noticed that most of the option functions do not have unit tests.

Copy link
Member

@axw axw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @lobotomist, looks good. The existing options are tested, just not directly. e.g. WithRecovery is tested by module/apmhttprouter. I'll add more direct unit tests later - thanks for calling that out :)

@axw
Copy link
Member

axw commented Aug 5, 2019

jenkins run the tests please

@codecov-io
Copy link

Codecov Report

Merging #609 into master will decrease coverage by 0.06%.
The diff coverage is 66.66%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #609      +/-   ##
==========================================
- Coverage   87.81%   87.74%   -0.07%     
==========================================
  Files         122      122              
  Lines        7476     7476              
==========================================
- Hits         6565     6560       -5     
- Misses        810      814       +4     
- Partials      101      102       +1
Impacted Files Coverage Δ
module/apmhttp/client.go 93.67% <66.66%> (ø) ⬆️
transport/http.go 94.27% <0%> (-1.15%) ⬇️
tracer.go 89.37% <0%> (-0.33%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 755a78b...be4d817. Read the comment docs.

@axw axw merged commit 203d013 into elastic:master Aug 5, 2019
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.

None yet

3 participants