[prev in list] [next in list] [prev in thread] [next in thread] 

List:       httpcomponents-commits
Subject:    [httpcomponents-client] branch master updated: HTTPCLIENT-2170: Classic protocol layer no longer rel
From:       olegk () apache ! org
Date:       2021-08-19 17:06:39
Message-ID: 162939279908.31188.12508033900897447192 () gitbox ! apache ! org
[Download RAW message or body]

This is an automated email from the ASF dual-hosted git repository.

olegk pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/httpcomponents-client.git


The following commit(s) were added to refs/heads/master by this push:
     new 5164a4e  HTTPCLIENT-2170: Classic protocol layer no longer releases the \
underlying connection back to the pool prematurely while the NTLM handshake is still \
ongoing 5164a4e is described below

commit 5164a4e7b4e122bd3f81db212f6d8ed4a681c583
Author: Oleg Kalnichevski <olegk@apache.org>
AuthorDate: Thu Aug 19 15:29:39 2021 +0200

    HTTPCLIENT-2170: Classic protocol layer no longer releases the underlying \
                connection back to the pool prematurely while the NTLM handshake is \
                still ongoing
---
 .../java/org/apache/hc/client5/http/impl/classic/MainClientExec.java   | 3 ---
 .../java/org/apache/hc/client5/http/impl/classic/ProtocolExec.java     | 2 ++
 2 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/httpclient5/src/main/java/org/apache/hc/client5/http/impl/classic/MainClientExec.java \
b/httpclient5/src/main/java/org/apache/hc/client5/http/impl/classic/MainClientExec.java
 index 7bf2ea7..2af5b70 100644
--- a/httpclient5/src/main/java/org/apache/hc/client5/http/impl/classic/MainClientExec.java
                
+++ b/httpclient5/src/main/java/org/apache/hc/client5/http/impl/classic/MainClientExec.java
 @@ -102,8 +102,6 @@ public final class MainClientExec implements ExecChainHandler {
             LOG.debug("{} executing {}", exchangeId, new RequestLine(request));
         }
         try {
-            RequestEntityProxy.enhance(request);
-
             final ClassicHttpResponse response = execRuntime.execute(exchangeId, \
request, context);  
             Object userToken = context.getUserToken();
@@ -136,7 +134,6 @@ public final class MainClientExec implements ExecChainHandler {
                 execRuntime.releaseEndpoint();
                 return new CloseableHttpResponse(response, null);
             }
-            ResponseEntityProxy.enhance(response, execRuntime);
             return new CloseableHttpResponse(response, execRuntime);
         } catch (final ConnectionShutdownException ex) {
             final InterruptedIOException ioex = new InterruptedIOException(
diff --git a/httpclient5/src/main/java/org/apache/hc/client5/http/impl/classic/ProtocolExec.java \
b/httpclient5/src/main/java/org/apache/hc/client5/http/impl/classic/ProtocolExec.java \
                index 9b311cd..2edfe4c 100644
--- a/httpclient5/src/main/java/org/apache/hc/client5/http/impl/classic/ProtocolExec.java
                
+++ b/httpclient5/src/main/java/org/apache/hc/client5/http/impl/classic/ProtocolExec.java
 @@ -140,6 +140,7 @@ public final class ProtocolExec implements ExecChainHandler {
                 }
             }
 
+            RequestEntityProxy.enhance(request);
 
             for (;;) {
 
@@ -207,6 +208,7 @@ public final class ProtocolExec implements ExecChainHandler {
                         request.addHeader(it.next());
                     }
                 } else {
+                    ResponseEntityProxy.enhance(response, execRuntime);
                     return response;
                 }
             }


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic