activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jbert...@apache.org
Subject [3/3] activemq-artemis git commit: ARTEMIS-1051 Adding synchronized calls on ACKs
Date Wed, 22 Mar 2017 14:55:19 GMT
ARTEMIS-1051 Adding synchronized calls on ACKs


Project: http://git-wip-us.apache.org/repos/asf/activemq-artemis/repo
Commit: http://git-wip-us.apache.org/repos/asf/activemq-artemis/commit/ac7cafb2
Tree: http://git-wip-us.apache.org/repos/asf/activemq-artemis/tree/ac7cafb2
Diff: http://git-wip-us.apache.org/repos/asf/activemq-artemis/diff/ac7cafb2

Branch: refs/heads/master
Commit: ac7cafb210c2da126fe2f22ec54fcfe5de648d18
Parents: 10c9d79
Author: Clebert Suconic <clebertsuconic@apache.org>
Authored: Tue Mar 21 10:33:36 2017 -0400
Committer: Justin Bertram <jbertram@apache.org>
Committed: Wed Mar 22 09:55:02 2017 -0500

----------------------------------------------------------------------
 .../artemis/core/server/impl/ServerConsumerImpl.java    | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/ac7cafb2/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ServerConsumerImpl.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ServerConsumerImpl.java
b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ServerConsumerImpl.java
index 710a22b..e812f2e 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ServerConsumerImpl.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ServerConsumerImpl.java
@@ -731,7 +731,7 @@ public class ServerConsumerImpl implements ServerConsumer, ReadyListener
{
     * This will be useful for other protocols that will need this such as openWire or MQTT.
     */
    @Override
-   public List<MessageReference> getDeliveringReferencesBasedOnProtocol(boolean remove,
+   public synchronized List<MessageReference> getDeliveringReferencesBasedOnProtocol(boolean
remove,
                                                                         Object protocolDataStart,
                                                                         Object protocolDataEnd)
{
       LinkedList<MessageReference> retReferences = new LinkedList<>();
@@ -766,7 +766,7 @@ public class ServerConsumerImpl implements ServerConsumer, ReadyListener
{
    }
 
    @Override
-   public void acknowledge(Transaction tx, final long messageID) throws Exception {
+   public synchronized void acknowledge(Transaction tx, final long messageID) throws Exception
{
       if (browseOnly) {
          return;
       }
@@ -830,7 +830,7 @@ public class ServerConsumerImpl implements ServerConsumer, ReadyListener
{
    }
 
    @Override
-   public void individualAcknowledge(Transaction tx, final long messageID) throws Exception
{
+   public synchronized void individualAcknowledge(Transaction tx, final long messageID) throws
Exception {
       if (browseOnly) {
          return;
       }
@@ -892,7 +892,7 @@ public class ServerConsumerImpl implements ServerConsumer, ReadyListener
{
    }
 
    @Override
-   public void individualCancel(final long messageID, boolean failed) throws Exception {
+   public synchronized void individualCancel(final long messageID, boolean failed) throws
Exception {
       if (browseOnly) {
          return;
       }
@@ -911,12 +911,12 @@ public class ServerConsumerImpl implements ServerConsumer, ReadyListener
{
    }
 
    @Override
-   public void backToDelivering(MessageReference reference) {
+   public synchronized void backToDelivering(MessageReference reference) {
       deliveringRefs.addFirst(reference);
    }
 
    @Override
-   public MessageReference removeReferenceByID(final long messageID) throws Exception {
+   public synchronized MessageReference removeReferenceByID(final long messageID) throws
Exception {
       if (browseOnly) {
          return null;
       }


Mime
View raw message