This is an automated email from the ASF dual-hosted git repository.

davsclaus pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git


The following commit(s) were added to refs/heads/master by this push:
     new 9d7d883  CAMEL-14354: Optimize core
9d7d883 is described below

commit 9d7d8835302f0c23e3d109b04a42cdda49e7108b
Author: Claus Ibsen <claus.ib...@gmail.com>
AuthorDate: Wed Jan 22 08:48:12 2020 +0100

    CAMEL-14354: Optimize core
---
 .../java/org/apache/camel/impl/engine/DefaultReactiveExecutor.java  | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git 
a/core/camel-base/src/main/java/org/apache/camel/impl/engine/DefaultReactiveExecutor.java
 
b/core/camel-base/src/main/java/org/apache/camel/impl/engine/DefaultReactiveExecutor.java
index e8c997e..f9d4cde 100644
--- 
a/core/camel-base/src/main/java/org/apache/camel/impl/engine/DefaultReactiveExecutor.java
+++ 
b/core/camel-base/src/main/java/org/apache/camel/impl/engine/DefaultReactiveExecutor.java
@@ -131,10 +131,10 @@ public class DefaultReactiveExecutor extends 
ServiceSupport implements ReactiveE
                 executor.runningWorkers.incrementAndGet();
                 try {
                     for (;;) {
-                        final Runnable polled = queue.poll();
+                        final Runnable polled = queue.pollFirst();
                         if (polled == null) {
                             if (back != null && !back.isEmpty()) {
-                                queue = back.poll();
+                                queue = back.pollFirst();
                                 continue;
                             } else {
                                 break;
@@ -162,7 +162,7 @@ public class DefaultReactiveExecutor extends ServiceSupport 
implements ReactiveE
         }
 
         boolean executeFromQueue() {
-            final Runnable polled = queue != null ? queue.poll() : null;
+            final Runnable polled = queue != null ? queue.pollFirst() : null;
             if (polled == null) {
                 return false;
             }

Reply via email to