activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tab...@apache.org
Subject svn commit: r1611183 - in /activemq/activemq-dotnet/Apache.NMS.ActiveMQ/branches/1.6.x: ./ src/main/csharp/MessageConsumer.cs
Date Wed, 16 Jul 2014 20:52:55 GMT
Author: tabish
Date: Wed Jul 16 20:52:55 2014
New Revision: 1611183

URL: http://svn.apache.org/r1611183
Log:
https://issues.apache.org/jira/browse/AMQNET-484

Eagerly release consumers from transacted sessions if they don't have any pending acks to
deliver so their prefetched messages are returned for dispatch right away.

Fixes [AMQNET-AMQNET-484]. (See https://issues.apache.org/jira/browse/AMQNET-AMQNET-484)

Modified:
    activemq/activemq-dotnet/Apache.NMS.ActiveMQ/branches/1.6.x/   (props changed)
    activemq/activemq-dotnet/Apache.NMS.ActiveMQ/branches/1.6.x/src/main/csharp/MessageConsumer.cs

Propchange: activemq/activemq-dotnet/Apache.NMS.ActiveMQ/branches/1.6.x/
------------------------------------------------------------------------------
  Merged /activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk:r1611182

Modified: activemq/activemq-dotnet/Apache.NMS.ActiveMQ/branches/1.6.x/src/main/csharp/MessageConsumer.cs
URL: http://svn.apache.org/viewvc/activemq/activemq-dotnet/Apache.NMS.ActiveMQ/branches/1.6.x/src/main/csharp/MessageConsumer.cs?rev=1611183&r1=1611182&r2=1611183&view=diff
==============================================================================
--- activemq/activemq-dotnet/Apache.NMS.ActiveMQ/branches/1.6.x/src/main/csharp/MessageConsumer.cs
(original)
+++ activemq/activemq-dotnet/Apache.NMS.ActiveMQ/branches/1.6.x/src/main/csharp/MessageConsumer.cs
Wed Jul 16 20:52:55 2014
@@ -434,7 +434,7 @@ namespace Apache.NMS.ActiveMQ
 		{
 			if(!this.unconsumedMessages.Closed)
 			{
-				if(this.session.IsTransacted && this.session.TransactionContext.InTransaction)
+				if(this.dispatchedMessages.Count != 0 && this.session.IsTransacted &&
this.session.TransactionContext.InTransaction)
 				{
                     Tracer.DebugFormat("Consumer {0} Registering new ConsumerCloseSynchronization",
                                        this.info.ConsumerId);
@@ -442,7 +442,7 @@ namespace Apache.NMS.ActiveMQ
 				}
 				else
 				{
-                    Tracer.DebugFormat("Consumer {0} No Active TX closing normally.",
+                    Tracer.DebugFormat("Consumer {0} No Active TX or pending acks, closing
normally.",
                                        this.info.ConsumerId);
                     this.DoClose();
 				}



Mime
View raw message