You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@activemq.apache.org by mi...@apache.org on 2019/09/12 19:21:14 UTC
[activemq-nms-amqp] branch master updated: AMQNET-611:
Apache.NMS.IllegalStateException is throw on transport thread
This is an automated email from the ASF dual-hosted git repository.
michaelpearce pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/activemq-nms-amqp.git
The following commit(s) were added to refs/heads/master by this push:
new 720910e AMQNET-611: Apache.NMS.IllegalStateException is throw on transport thread
new fe65710 Merge pull request #30 from Havret/exception_is_throw_on_transport_thread_during_shutdown
720910e is described below
commit 720910eb900c4811e13c9eea209907e4b5edb3a4
Author: Havret <h4...@gmail.com>
AuthorDate: Wed Sep 11 23:18:34 2019 +0200
AMQNET-611: Apache.NMS.IllegalStateException is throw on transport thread
---
src/NMS.AMQP/NmsMessageConsumer.cs | 2 +-
src/NMS.AMQP/NmsSession.cs | 2 ++
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/src/NMS.AMQP/NmsMessageConsumer.cs b/src/NMS.AMQP/NmsMessageConsumer.cs
index 34afd0c..a8c65d5 100644
--- a/src/NMS.AMQP/NmsMessageConsumer.cs
+++ b/src/NMS.AMQP/NmsMessageConsumer.cs
@@ -408,7 +408,7 @@ namespace Apache.NMS.AMQP
{
envelope.Message.NmsAcknowledgeCallback = new NmsAcknowledgeCallback(Session);
}
- else if (Session.AcknowledgementMode == AcknowledgementMode.IndividualAcknowledge)
+ else if (Session.IsIndividualAcknowledge())
{
envelope.Message.NmsAcknowledgeCallback = new NmsAcknowledgeCallback(Session, envelope);
}
diff --git a/src/NMS.AMQP/NmsSession.cs b/src/NMS.AMQP/NmsSession.cs
index c9f008d..1b1c0f6 100644
--- a/src/NMS.AMQP/NmsSession.cs
+++ b/src/NMS.AMQP/NmsSession.cs
@@ -592,5 +592,7 @@ namespace Apache.NMS.AMQP
consumer.OnConnectionInterrupted();
}
}
+
+ internal bool IsIndividualAcknowledge() => acknowledgementMode == AcknowledgementMode.IndividualAcknowledge;
}
}
\ No newline at end of file