reta commented on code in PR #1781:
URL: https://github.com/apache/cxf/pull/1781#discussion_r1550639711


##########
rt/rs/client/src/main/java/org/apache/cxf/jaxrs/client/spec/ClientImpl.java:
##########
@@ -470,7 +472,7 @@ public WebTarget resolveTemplatesFromEncoded(Map<String, 
Object> templatesMap) {
         private WebTarget newWebTarget(UriBuilder newBuilder) {
             WebClient newClient;
             if (targetClient != null) {
-                newClient = WebClient.fromClient(targetClient);
+                newClient = threadSafeTargetClient ? targetClient : 
WebClient.fromClient(targetClient);

Review Comment:
   @dennis-yemelyanov the usage of the new client instance is not accidental 
and is not about thread safety as much as the following the specification 
JAX-RS (please consult section "5.3 Client Targets" of the JSR-339). 



##########
rt/rs/client/src/main/java/org/apache/cxf/jaxrs/client/spec/ClientImpl.java:
##########
@@ -470,7 +472,7 @@ public WebTarget resolveTemplatesFromEncoded(Map<String, 
Object> templatesMap) {
         private WebTarget newWebTarget(UriBuilder newBuilder) {
             WebClient newClient;
             if (targetClient != null) {
-                newClient = WebClient.fromClient(targetClient);
+                newClient = threadSafeTargetClient ? targetClient : 
WebClient.fromClient(targetClient);

Review Comment:
   @dennis-yemelyanov the usage of the new client instance is not accidental 
and is not about thread safety as much as the following the  JAX-RS 
specification (please consult section "5.3 Client Targets" of the JSR-339). 



-- 
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: dev-unsubscr...@cxf.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to