Repository: camel
Updated Branches:
  refs/heads/master 59eb278ca -> 969f29034


CAMEL-9150: Seda suspend/resume should not trigger start/stop logic


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

Branch: refs/heads/master
Commit: de2aab16048ff5ecc98b16f52333d19a0c0b612b
Parents: 59eb278
Author: Claus Ibsen <davscl...@apache.org>
Authored: Tue Sep 22 09:18:15 2015 +0200
Committer: Claus Ibsen <davscl...@apache.org>
Committed: Tue Sep 22 09:18:15 2015 +0200

----------------------------------------------------------------------
 .../java/org/apache/camel/component/seda/SedaConsumer.java     | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/de2aab16/camel-core/src/main/java/org/apache/camel/component/seda/SedaConsumer.java
----------------------------------------------------------------------
diff --git 
a/camel-core/src/main/java/org/apache/camel/component/seda/SedaConsumer.java 
b/camel-core/src/main/java/org/apache/camel/component/seda/SedaConsumer.java
index 5ddd0b5..14e4372 100644
--- a/camel-core/src/main/java/org/apache/camel/component/seda/SedaConsumer.java
+++ b/camel-core/src/main/java/org/apache/camel/component/seda/SedaConsumer.java
@@ -167,8 +167,8 @@ public class SedaConsumer extends ServiceSupport implements 
Consumer, Runnable,
                 continue;
             }
 
-            // do not poll if we are suspended
-            if (isSuspending() || isSuspended()) {
+            // do not poll if we are suspended or starting again after resuming
+            if (isSuspending() || isSuspended() || isStarting()) {
                 if (shutdownPending && queue.isEmpty()) {
                     LOG.trace("Consumer is suspended and shutdown is pending, 
so this consumer thread is breaking out because the task queue is empty.");
                     // we want to shutdown so break out if there queue is empty
@@ -312,7 +312,7 @@ public class SedaConsumer extends ServiceSupport implements 
Consumer, Runnable,
 
     @Override
     protected void doResume() throws Exception {
-        doStart();
+        endpoint.onStarted(this);
     }
 
     protected void doStop() throws Exception {

Reply via email to