hc-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ol...@apache.org
Subject svn commit: r1526426 - /httpcomponents/httpcore/trunk/httpcore-nio/src/main/java/org/apache/http/nio/protocol/HttpAsyncService.java
Date Thu, 26 Sep 2013 09:25:26 GMT
Author: olegk
Date: Thu Sep 26 09:25:25 2013
New Revision: 1526426

URL: http://svn.apache.org/r1526426
Log:
HTTPCORE-351: Preserve HTTP context used for server side HTTP exchange by HttpAsyncService
Contributed by James Leigh <james at 3roundstones.com>

Modified:
    httpcomponents/httpcore/trunk/httpcore-nio/src/main/java/org/apache/http/nio/protocol/HttpAsyncService.java

Modified: httpcomponents/httpcore/trunk/httpcore-nio/src/main/java/org/apache/http/nio/protocol/HttpAsyncService.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpcore/trunk/httpcore-nio/src/main/java/org/apache/http/nio/protocol/HttpAsyncService.java?rev=1526426&r1=1526425&r2=1526426&view=diff
==============================================================================
--- httpcomponents/httpcore/trunk/httpcore-nio/src/main/java/org/apache/http/nio/protocol/HttpAsyncService.java
(original)
+++ httpcomponents/httpcore/trunk/httpcore-nio/src/main/java/org/apache/http/nio/protocol/HttpAsyncService.java
Thu Sep 26 09:25:25 2013
@@ -610,7 +610,7 @@ public class HttpAsyncService implements
 
     static class State {
 
-        private final BasicHttpContext context;
+        private volatile BasicHttpContext context;
         private volatile boolean terminated;
         private volatile HttpAsyncRequestHandler<Object> requestHandler;
         private volatile MessageState requestState;
@@ -705,7 +705,7 @@ public class HttpAsyncService implements
         }
 
         public void reset() {
-            this.context.clear();
+            this.context = new BasicHttpContext();
             this.responseState = MessageState.READY;
             this.requestState = MessageState.READY;
             this.requestHandler = null;



Mime
View raw message