hc-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ol...@apache.org
Subject svn commit: r597592 - in /jakarta/httpcomponents/httpcore/trunk: ./ module-niossl/src/main/java/org/apache/http/impl/nio/reactor/
Date Fri, 23 Nov 2007 08:37:40 GMT
Author: olegk
Date: Fri Nov 23 00:37:39 2007
New Revision: 597592

URL: http://svn.apache.org/viewvc?rev=597592&view=rev
Log:
HTTPCORE-130: Fixed over-synchronization bug leading to a thread deadlock condition in SSL
IOEventDispatch implementations.


Modified:
    jakarta/httpcomponents/httpcore/trunk/RELEASE_NOTES.txt
    jakarta/httpcomponents/httpcore/trunk/module-niossl/src/main/java/org/apache/http/impl/nio/reactor/SSLClientIOEventDispatch.java
    jakarta/httpcomponents/httpcore/trunk/module-niossl/src/main/java/org/apache/http/impl/nio/reactor/SSLServerIOEventDispatch.java

Modified: jakarta/httpcomponents/httpcore/trunk/RELEASE_NOTES.txt
URL: http://svn.apache.org/viewvc/jakarta/httpcomponents/httpcore/trunk/RELEASE_NOTES.txt?rev=597592&r1=597591&r2=597592&view=diff
==============================================================================
--- jakarta/httpcomponents/httpcore/trunk/RELEASE_NOTES.txt (original)
+++ jakarta/httpcomponents/httpcore/trunk/RELEASE_NOTES.txt Fri Nov 23 00:37:39 2007
@@ -1,5 +1,9 @@
 Changes since 4.0 Alpha 6
 
+* [HTTPCORE-130] Fixed over-synchronization bug leading to a thread deadlock 
+  condition in SSL IOEventDispatch implementations.
+  Contributed by Oleg Kalnichevski <olegk at apache.org>
+
 * [HTTPCORE-37] HttpParams beans
   Contributed by Stojce Dimski <sdmiski at yahoo.it>
 

Modified: jakarta/httpcomponents/httpcore/trunk/module-niossl/src/main/java/org/apache/http/impl/nio/reactor/SSLClientIOEventDispatch.java
URL: http://svn.apache.org/viewvc/jakarta/httpcomponents/httpcore/trunk/module-niossl/src/main/java/org/apache/http/impl/nio/reactor/SSLClientIOEventDispatch.java?rev=597592&r1=597591&r2=597592&view=diff
==============================================================================
--- jakarta/httpcomponents/httpcore/trunk/module-niossl/src/main/java/org/apache/http/impl/nio/reactor/SSLClientIOEventDispatch.java
(original)
+++ jakarta/httpcomponents/httpcore/trunk/module-niossl/src/main/java/org/apache/http/impl/nio/reactor/SSLClientIOEventDispatch.java
Fri Nov 23 00:37:39 2007
@@ -136,12 +136,10 @@
             (SSLIOSession) session.getAttribute(SSL_SESSION);
 
         try {
-            synchronized (sslSession) {
-                if (sslSession.isAppInputReady()) {
-                    conn.consumeInput(this.handler);
-                }
-                sslSession.inboundTransport();
+            if (sslSession.isAppInputReady()) {
+                conn.consumeInput(this.handler);
             }
+            sslSession.inboundTransport();
         } catch (IOException ex) {
             this.handler.exception(conn, ex);
             sslSession.shutdown();
@@ -155,12 +153,10 @@
             (SSLIOSession) session.getAttribute(SSL_SESSION);
 
         try {
-            synchronized (sslSession) {
-                if (sslSession.isAppOutputReady()) {
-                    conn.produceOutput(this.handler);
-                }
-                sslSession.outboundTransport();
+            if (sslSession.isAppOutputReady()) {
+                conn.produceOutput(this.handler);
             }
+            sslSession.outboundTransport();
         } catch (IOException ex) {
             this.handler.exception(conn, ex);
             sslSession.shutdown();

Modified: jakarta/httpcomponents/httpcore/trunk/module-niossl/src/main/java/org/apache/http/impl/nio/reactor/SSLServerIOEventDispatch.java
URL: http://svn.apache.org/viewvc/jakarta/httpcomponents/httpcore/trunk/module-niossl/src/main/java/org/apache/http/impl/nio/reactor/SSLServerIOEventDispatch.java?rev=597592&r1=597591&r2=597592&view=diff
==============================================================================
--- jakarta/httpcomponents/httpcore/trunk/module-niossl/src/main/java/org/apache/http/impl/nio/reactor/SSLServerIOEventDispatch.java
(original)
+++ jakarta/httpcomponents/httpcore/trunk/module-niossl/src/main/java/org/apache/http/impl/nio/reactor/SSLServerIOEventDispatch.java
Fri Nov 23 00:37:39 2007
@@ -135,12 +135,10 @@
             (SSLIOSession) session.getAttribute(SSL_SESSION);
 
         try {
-            synchronized (sslSession) {
-                if (sslSession.isAppInputReady()) {
-                    conn.consumeInput(this.handler);
-                }
-                sslSession.inboundTransport();
+            if (sslSession.isAppInputReady()) {
+                conn.consumeInput(this.handler);
             }
+            sslSession.inboundTransport();
         } catch (IOException ex) {
             this.handler.exception(conn, ex);
             sslSession.shutdown();
@@ -154,12 +152,10 @@
             (SSLIOSession) session.getAttribute(SSL_SESSION);
 
         try {
-            synchronized (sslSession) {
-                if (sslSession.isAppOutputReady()) {
-                    conn.produceOutput(this.handler);
-                }
-                sslSession.outboundTransport();
+            if (sslSession.isAppOutputReady()) {
+                conn.produceOutput(this.handler);
             }
+            sslSession.outboundTransport();
         } catch (IOException ex) {
             this.handler.exception(conn, ex);
             sslSession.shutdown();



Mime
View raw message