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 4281220  CAMEL-14354: camel-core optimize
4281220 is described below

commit 42812209faf0ac1f2b209d256281365ddc1d2a5f
Author: Claus Ibsen <claus.ib...@gmail.com>
AuthorDate: Mon Jan 27 13:38:37 2020 +0100

    CAMEL-14354: camel-core optimize
---
 .../camel/processor/errorhandler/RedeliveryErrorHandler.java | 12 +-----------
 1 file changed, 1 insertion(+), 11 deletions(-)

diff --git 
a/core/camel-base/src/main/java/org/apache/camel/processor/errorhandler/RedeliveryErrorHandler.java
 
b/core/camel-base/src/main/java/org/apache/camel/processor/errorhandler/RedeliveryErrorHandler.java
index ca010ff..8336458 100644
--- 
a/core/camel-base/src/main/java/org/apache/camel/processor/errorhandler/RedeliveryErrorHandler.java
+++ 
b/core/camel-base/src/main/java/org/apache/camel/processor/errorhandler/RedeliveryErrorHandler.java
@@ -265,15 +265,6 @@ public abstract class RedeliveryErrorHandler extends 
ErrorHandlerSupport impleme
     }
 
     /**
-     * Strategy whether the exchange has an exception that we should try to 
handle.
-     * <p/>
-     * Standard implementations should just look for an exception.
-     */
-    protected boolean shouldHandleException(Exchange exchange) {
-        return exchange.getException() != null;
-    }
-
-    /**
      * Strategy to determine if the exchange is done so we can continue
      */
     protected boolean isDone(Exchange exchange) {
@@ -404,8 +395,7 @@ public abstract class RedeliveryErrorHandler extends 
ErrorHandlerSupport impleme
             }
 
             // did previous processing cause an exception?
-            boolean handle = shouldHandleException(exchange);
-            if (handle) {
+            if (exchange.getException() != null) {
                 handleException();
                 onExceptionOccurred();
             }

Reply via email to