Repository: camel Updated Branches: refs/heads/master f9ef95155 -> ae7ede091
CAMEL-9887 Check for preCompletion on the delegated AggregationStrategy Project: http://git-wip-us.apache.org/repos/asf/camel/repo Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/ae7ede09 Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/ae7ede09 Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/ae7ede09 Branch: refs/heads/master Commit: ae7ede0918ad631df66ba430c15f1037236d4f8c Parents: f9ef951 Author: Tomas Rohovsky <tomasrohov...@seznam.cz> Authored: Mon Apr 25 12:20:32 2016 +0200 Committer: Tomas Rohovsky <tomasrohov...@seznam.cz> Committed: Mon Apr 25 12:25:36 2016 +0200 ---------------------------------------------------------------------- .../apache/camel/processor/aggregate/AggregateProcessor.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/camel/blob/ae7ede09/camel-core/src/main/java/org/apache/camel/processor/aggregate/AggregateProcessor.java ---------------------------------------------------------------------- diff --git a/camel-core/src/main/java/org/apache/camel/processor/aggregate/AggregateProcessor.java b/camel-core/src/main/java/org/apache/camel/processor/aggregate/AggregateProcessor.java index d094249..036c45a 100644 --- a/camel-core/src/main/java/org/apache/camel/processor/aggregate/AggregateProcessor.java +++ b/camel-core/src/main/java/org/apache/camel/processor/aggregate/AggregateProcessor.java @@ -1273,7 +1273,11 @@ public class AggregateProcessor extends ServiceSupport implements AsyncProcessor @Override protected void doStart() throws Exception { - if (aggregationStrategy instanceof PreCompletionAwareAggregationStrategy) { + AggregationStrategy strategy = aggregationStrategy; + if (strategy instanceof DelegateAggregationStrategy) { + strategy = ((DelegateAggregationStrategy) strategy).getDelegate(); + } + if (strategy instanceof PreCompletionAwareAggregationStrategy) { preCompletion = true; LOG.info("PreCompletionAwareAggregationStrategy detected. Aggregator {} is in pre-completion mode.", getId()); }