You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@camel.apache.org by "Claus Ibsen (JIRA)" <ji...@apache.org> on 2015/07/12 16:03:04 UTC
[jira] [Resolved] (CAMEL-8955) Processor for .pollEnrich
incorrectly handles provided AggregationStrategy
[ https://issues.apache.org/jira/browse/CAMEL-8955?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Claus Ibsen resolved CAMEL-8955.
--------------------------------
Resolution: Won't Fix
Assignee: Claus Ibsen
That strategy is only for the aggregator eip and not poll enrich - I will update its javadoc.
> Processor for .pollEnrich incorrectly handles provided AggregationStrategy
> --------------------------------------------------------------------------
>
> Key: CAMEL-8955
> URL: https://issues.apache.org/jira/browse/CAMEL-8955
> Project: Camel
> Issue Type: Bug
> Components: camel-core
> Affects Versions: 2.14.3
> Reporter: Andy Fedotov
> Assignee: Claus Ibsen
> Priority: Minor
> Attachments: PollEnrichAggregationStrategyTest.java
>
>
> As it can be concluded from AggregationStrategy javadoc, and also from available implementations such as GroupedExchangeAggregationStrategy, it should be used in the following manner:
> {code:java}
> AggregationStrategy strategy = new GroupedExchangeAggregationStrategy();
> Exchange result = null;
> result = strategy.aggregate(result, exchange1);
> result = strategy.aggregate(result, exchange2);
> // ... and so on
> return result;
> {code}
> But PollEnricher do it in following manner:
> {code:java}
> AggregationStrategy strategy = new GroupedExchangeAggregationStrategy();
> Exchange result = strategy.aggregate(exchange1, exchange2);
> return result;
> {code}
> This leads to incorrect result returned after aggregation and lost exchanges.
> Also PollEnricher doesn't handle CompletionAwareAggregationStrategy and does not call onCompletion(). Consequently GroupedExchangeAggregationStrategy does not return aggregated result in the Exchange body.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)