From c0f71c3e1537da7bafb9071f746cfcb2687778e0 Mon Sep 17 00:00:00 2001
From: Clebert Suconic <clebertsuconic@apache.org>
Date: Thu, 17 Dec 2015 22:43:20 -0500
Subject: [PATCH] fixing executor (adding state back)

---
 .../apache/activemq/artemis/utils/OrderedExecutorFactory.java | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/artemis-core-client/src/main/java/org/apache/activemq/artemis/utils/OrderedExecutorFactory.java b/artemis-core-client/src/main/java/org/apache/activemq/artemis/utils/OrderedExecutorFactory.java
index 18db9c7606..b1e9d886c7 100644
--- a/artemis-core-client/src/main/java/org/apache/activemq/artemis/utils/OrderedExecutorFactory.java
+++ b/artemis-core-client/src/main/java/org/apache/activemq/artemis/utils/OrderedExecutorFactory.java
@@ -62,6 +62,10 @@ public final class OrderedExecutorFactory implements ExecutorFactory {
       private final Executor delegate;
       private final ExecutorTask task = new ExecutorTask();
 
+      // used by stateUpdater
+      @SuppressWarnings("unused")
+      private volatile int state = 0;
+
       private static final AtomicIntegerFieldUpdater<OrderedExecutor> stateUpdater = AtomicIntegerFieldUpdater.newUpdater(OrderedExecutor.class, "state");
 
       private static final int STATE_NOT_RUNNING = 0;