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

#1648 Populate headers from RequestOptions in WebClient.request() #1649

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

marcinus
Copy link

Motivation:
#1648

Conformance:

Your commits should be signed and you should have signed the Eclipse Contributor Agreement as explained in https://github.com/eclipse/vert.x/blob/master/CONTRIBUTING.md
Please also make sure you adhere to the code style guidelines: https://github.com/vert-x3/wiki/wiki/Vert.x-code-style-guidelines

@marcinus marcinus changed the title #1648 Populate headers from RequestOptions inWebClient.request() #1648 Populate headers from RequestOptions in WebClient.request() Jun 24, 2020
@@ -197,7 +197,8 @@ public WebClientBase(HttpClient client, WebClientOptions options) {
@Override
public HttpRequest<Buffer> request(HttpMethod method, SocketAddress serverAddress, RequestOptions requestOptions) {
return new HttpRequestImpl<>(this, method, serverAddress, requestOptions.isSsl(), requestOptions.getPort(),
requestOptions.getHost(), requestOptions.getURI(), BodyCodecImpl.BUFFER, options);
requestOptions.getHost(), requestOptions.getURI(), BodyCodecImpl.BUFFER, options)
.putHeaders(requestOptions.getHeaders());
Copy link
Member

Choose a reason for hiding this comment

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

requestOptions.getHeaders() is possible null

@gaol
Copy link
Member

gaol commented Jun 30, 2020

I think adding a test would be easier to get merged. :)

@gaol
Copy link
Member

gaol commented Jul 2, 2020

LGTM if @marcinus can squash into one commit :)

@marcinus marcinus force-pushed the bugfix/1648-webclient-headers branch from f7ce37e to 9e84bda Compare July 2, 2020 09:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants