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

List:       httpcomponents-commits
Subject:    svn commit: r1526426 - /httpcomponents/httpcore/trunk/httpcore-nio/src/main/java/org/apache/http/nio
From:       olegk () apache ! org
Date:       2013-09-26 9:25:26
Message-ID: 20130926092526.5410C238883D () eris ! apache ! org
[Download RAW message or body]

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;


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

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