RayayChung commented on code in PR #4283:
URL: https://github.com/apache/shenyu/pull/4283#discussion_r1056960923
##########
shenyu-plugin/shenyu-plugin-httpclient/src/main/java/org/apache/shenyu/plugin/httpclient/WebClientPlugin.java:
##########
@@ -63,8 +63,7 @@ protected Mono<ClientResponse> doRequest(final
ServerWebExchange exchange, final
.flatMap(bytes -> Mono.fromCallable(() ->
Optional.ofNullable(bytes))).defaultIfEmpty(Optional.empty())
.flatMap(option -> {
final ClientResponse.Builder builder =
ClientResponse.create(response.statusCode())
- .headers(headers ->
headers.addAll(response.headers().asHttpHeaders()))
- .cookies(cookies ->
cookies.addAll(response.cookies()));
Review Comment:
Setting cookies is just part of setting headers. So the previous version
codes may lead setting cookies twice.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]