You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@activemq.apache.org by ta...@apache.org on 2010/02/18 23:29:24 UTC
svn commit: r911622 - in
/activemq/activemq-dotnet/Apache.NMS.ActiveMQ/branches/1.2.x/src/main/csharp:
Connection.cs Session.cs
Author: tabish
Date: Thu Feb 18 22:29:24 2010
New Revision: 911622
URL: http://svn.apache.org/viewvc?rev=911622&view=rev
Log:
Fix for: https://issues.apache.org/activemq/browse/AMQNET-235
Modified:
activemq/activemq-dotnet/Apache.NMS.ActiveMQ/branches/1.2.x/src/main/csharp/Connection.cs
activemq/activemq-dotnet/Apache.NMS.ActiveMQ/branches/1.2.x/src/main/csharp/Session.cs
Modified: activemq/activemq-dotnet/Apache.NMS.ActiveMQ/branches/1.2.x/src/main/csharp/Connection.cs
URL: http://svn.apache.org/viewvc/activemq/activemq-dotnet/Apache.NMS.ActiveMQ/branches/1.2.x/src/main/csharp/Connection.cs?rev=911622&r1=911621&r2=911622&view=diff
==============================================================================
--- activemq/activemq-dotnet/Apache.NMS.ActiveMQ/branches/1.2.x/src/main/csharp/Connection.cs (original)
+++ activemq/activemq-dotnet/Apache.NMS.ActiveMQ/branches/1.2.x/src/main/csharp/Connection.cs Thu Feb 18 22:29:24 2010
@@ -765,11 +765,19 @@
protected void OnTransportInterrupted(ITransport sender)
{
- Tracer.Debug("Transport has been Interrupted.");
+ Tracer.Debug("Connection: Transport has been Interrupted.");
foreach(Session session in this.sessions)
{
- session.ClearMessagesInProgress();
+ try
+ {
+ session.ClearMessagesInProgress();
+ }
+ catch(Exception ex)
+ {
+ Tracer.Warn("Exception while clearing messages: " + ex.Message);
+ Tracer.Warn(ex.StackTrace);
+ }
}
if(this.ConnectionInterruptedListener != null && !this.closing )
Modified: activemq/activemq-dotnet/Apache.NMS.ActiveMQ/branches/1.2.x/src/main/csharp/Session.cs
URL: http://svn.apache.org/viewvc/activemq/activemq-dotnet/Apache.NMS.ActiveMQ/branches/1.2.x/src/main/csharp/Session.cs?rev=911622&r1=911621&r2=911622&view=diff
==============================================================================
--- activemq/activemq-dotnet/Apache.NMS.ActiveMQ/branches/1.2.x/src/main/csharp/Session.cs (original)
+++ activemq/activemq-dotnet/Apache.NMS.ActiveMQ/branches/1.2.x/src/main/csharp/Session.cs Thu Feb 18 22:29:24 2010
@@ -807,7 +807,7 @@
lock(this.consumers.SyncRoot)
{
- foreach(MessageConsumer consumer in this.consumers)
+ foreach(MessageConsumer consumer in this.consumers.Values)
{
consumer.ClearMessagesInProgress();
}