svn commit: r1063791 - in /tomcat/trunk: java/org/apache/catalina/tribes/group/RpcChannel.java webapps/docs/changelog.xml

2011-01-26 Thread markt
Author: markt
Date: Wed Jan 26 16:53:23 2011
New Revision: 1063791

URL: http://svn.apache.org/viewvc?rev=1063791view=rev
Log:
Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=50648
Correctly set the interrupt status if a thread using RpcChannel is interrupted 
waiting for a message reply.
Based on a patch by Olivier Costet.

Modified:
tomcat/trunk/java/org/apache/catalina/tribes/group/RpcChannel.java
tomcat/trunk/webapps/docs/changelog.xml

Modified: tomcat/trunk/java/org/apache/catalina/tribes/group/RpcChannel.java
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/tribes/group/RpcChannel.java?rev=1063791r1=1063790r2=1063791view=diff
==
--- tomcat/trunk/java/org/apache/catalina/tribes/group/RpcChannel.java 
(original)
+++ tomcat/trunk/java/org/apache/catalina/tribes/group/RpcChannel.java Wed Jan 
26 16:53:23 2011
@@ -95,8 +95,7 @@ public class RpcChannel implements Chann
 if ( rpcOptions != NO_REPLY ) collector.wait(timeout);
 }
 } catch ( InterruptedException ix ) {
-Thread.interrupted();
-//throw new ChannelException(ix);
+Thread.currentThread().interrupt();
 }finally {
 responseMap.remove(key);
 }

Modified: tomcat/trunk/webapps/docs/changelog.xml
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/changelog.xml?rev=1063791r1=1063790r2=1063791view=diff
==
--- tomcat/trunk/webapps/docs/changelog.xml (original)
+++ tomcat/trunk/webapps/docs/changelog.xml Wed Jan 26 16:53:23 2011
@@ -158,6 +158,11 @@
 Be consistent with locks on sessionCreationTiming,
 sessionExpirationTiming in DeltaManager.resetStatistics(). (kkolinko)
   /fix
+  fix
+bug50648/bug: Correctly set the interrupt status if a thread using
+codeRpcChannel/code is interrupted waiting for a message reply.
+Based on a patch by Olivier Costet. (markt)
+  /fix
 /changelog
   /subsection
   subsection name=Web applications



-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org



Re: svn commit: r1063791 - in /tomcat/trunk: java/org/apache/catalina/tribes/group/RpcChannel.java webapps/docs/changelog.xml

2011-01-26 Thread Filip Hanik - Dev Lists
hmm, it should probably throw the commented out channel exception 
instead of simply bailing out with the flag set.
After all the timeout has not been reached, so the caller should not be 
tricked into thinking that it has, since no one ever checks the 
interrupted flag


Filip


On 01/26/2011 09:53 AM, ma...@apache.org wrote:

Author: markt
Date: Wed Jan 26 16:53:23 2011
New Revision: 1063791

URL: http://svn.apache.org/viewvc?rev=1063791view=rev
Log:
Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=50648
Correctly set the interrupt status if a thread using RpcChannel is interrupted 
waiting for a message reply.
Based on a patch by Olivier Costet.

Modified:
 tomcat/trunk/java/org/apache/catalina/tribes/group/RpcChannel.java
 tomcat/trunk/webapps/docs/changelog.xml

Modified: tomcat/trunk/java/org/apache/catalina/tribes/group/RpcChannel.java
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/tribes/group/RpcChannel.java?rev=1063791r1=1063790r2=1063791view=diff
==
--- tomcat/trunk/java/org/apache/catalina/tribes/group/RpcChannel.java 
(original)
+++ tomcat/trunk/java/org/apache/catalina/tribes/group/RpcChannel.java Wed Jan 
26 16:53:23 2011
@@ -95,8 +95,7 @@ public class RpcChannel implements Chann
  if ( rpcOptions != NO_REPLY ) collector.wait(timeout);
  }
  } catch ( InterruptedException ix ) {
-Thread.interrupted();
-//throw new ChannelException(ix);
+Thread.currentThread().interrupt();
  }finally {
  responseMap.remove(key);
  }

Modified: tomcat/trunk/webapps/docs/changelog.xml
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/changelog.xml?rev=1063791r1=1063790r2=1063791view=diff
==
--- tomcat/trunk/webapps/docs/changelog.xml (original)
+++ tomcat/trunk/webapps/docs/changelog.xml Wed Jan 26 16:53:23 2011
@@ -158,6 +158,11 @@
  Be consistent with locks on sessionCreationTiming,
  sessionExpirationTiming in DeltaManager.resetStatistics(). (kkolinko)
/fix
+fix
+bug50648/bug: Correctly set the interrupt status if a thread using
+codeRpcChannel/code  is interrupted waiting for a message reply.
+Based on a patch by Olivier Costet. (markt)
+/fix
  /changelog
/subsection
subsection name=Web applications



-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org


   



-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org