Use overloaded method with java.net.URI of Reactor Netty HttpClient #29954
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.
I was doing some flame graph analysis and found that despite passing a URI into the WebClient, a string version of the URI was being passed into the reactor-netty library where it was parsed again in the UriEndpointFactory: https://github.com/reactor/reactor-netty/blob/dfb1e18551bd51a6cc406acdb923b66c9d7bbada/reactor-netty-http/src/main/java/reactor/netty/http/client/HttpClientConnect.java#L497-L513
Later, the URI is constructed again further inside that library https://github.com/reactor/reactor-netty/blob/dfb1e18551bd51a6cc406acdb923b66c9d7bbada/reactor-netty-http/src/main/java/reactor/netty/http/HttpOperations.java#L429 I may take a stab at cleaning up that in reactor/reactor-netty#829 once the URI is passed from spring. Ideally, I could make the URI passed into spring live all the way thru the lifecycle.
NOTE: this assumes a full URI is present like
http://example.com/blah
not/blah
. When I hit breakpoints here, it appeared that they were all full URI's.