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 272ea94 Polished
272ea94 is described below
commit 272ea94f9e765355dd308b6ba8037e70e3fc92b7
Author: Claus Ibsen <[email protected]>
AuthorDate: Thu Jul 18 10:53:39 2019 +0200
Polished
---
.../org/apache/camel/processor/CamelInternalProcessor.java | 12 +++++-------
1 file changed, 5 insertions(+), 7 deletions(-)
diff --git
a/core/camel-base/src/main/java/org/apache/camel/processor/CamelInternalProcessor.java
b/core/camel-base/src/main/java/org/apache/camel/processor/CamelInternalProcessor.java
index 9f48f00..78753e1 100644
---
a/core/camel-base/src/main/java/org/apache/camel/processor/CamelInternalProcessor.java
+++
b/core/camel-base/src/main/java/org/apache/camel/processor/CamelInternalProcessor.java
@@ -248,7 +248,7 @@ public class CamelInternalProcessor extends
DelegateAsyncProcessor {
/**
* Strategy to determine if we should continue processing the {@link
Exchange}.
*/
- protected boolean continueProcessing(Exchange exchange) {
+ private boolean continueProcessing(Exchange exchange) {
Object stop = exchange.getProperty(Exchange.ROUTE_STOP);
if (stop != null) {
boolean doStop =
exchange.getContext().getTypeConverter().convertTo(Boolean.class, stop);
@@ -350,7 +350,7 @@ public class CamelInternalProcessor extends
DelegateAsyncProcessor {
* @param policy the policy
* @return <tt>true</tt> to run
*/
- protected boolean isRoutePolicyRunAllowed(RoutePolicy policy) {
+ boolean isRoutePolicyRunAllowed(RoutePolicy policy) {
if (policy instanceof StatefulService) {
StatefulService ss = (StatefulService) policy;
return ss.isRunAllowed();
@@ -395,9 +395,8 @@ public class CamelInternalProcessor extends
DelegateAsyncProcessor {
}
private static boolean isCamelStopping(CamelContext context) {
- if (context instanceof StatefulService) {
- StatefulService ss = (StatefulService) context;
- return ss.isStopping() || ss.isStopped();
+ if (context != null) {
+ return context.isStopping() || context.isStopped();
}
return false;
}
@@ -516,9 +515,8 @@ public class CamelInternalProcessor extends
DelegateAsyncProcessor {
@Override
public StopWatch before(Exchange exchange) throws Exception {
- StopWatch watch = new StopWatch();
debugger.beforeProcess(exchange, target, definition);
- return watch;
+ return new StopWatch();
}
@Override