You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by da...@apache.org on 2020/07/27 05:04:26 UTC
[camel] 01/02: Replace old groupExchanges in EIP docs.
This is an automated email from the ASF dual-hosted git repository.
davsclaus pushed a commit to branch camel-3.4.x
in repository https://gitbox.apache.org/repos/asf/camel.git
commit 5ff8e23ccce16bbb418262e817ddc23959ba0494
Author: Jan Bednář <ma...@janbednar.eu>
AuthorDate: Sun Jul 26 23:55:09 2020 +0200
Replace old groupExchanges in EIP docs.
---
.../src/main/docs/modules/eips/pages/aggregate-eip.adoc | 17 ++++++++---------
1 file changed, 8 insertions(+), 9 deletions(-)
diff --git a/core/camel-core-engine/src/main/docs/modules/eips/pages/aggregate-eip.adoc b/core/camel-core-engine/src/main/docs/modules/eips/pages/aggregate-eip.adoc
index a27492a..4765a7a 100644
--- a/core/camel-core-engine/src/main/docs/modules/eips/pages/aggregate-eip.adoc
+++ b/core/camel-core-engine/src/main/docs/modules/eips/pages/aggregate-eip.adoc
@@ -368,25 +368,24 @@ To configure this from XML DSL
There is also JMX API on the aggregator which is available under the
processors node in the Camel JMX tree.
-== Using GroupedExchanges
+== Using GroupedExchangeAggregationStrategy
In the route below we group all the exchanges together using
-`groupExchanges()`:
+`GroupedExchangeAggregationStrategy`:
[source,java]
----
from("direct:start")
- // aggregate all using same expression
- .aggregate(constant(true))
+ // aggregate all using same expression and group the
+ // exchanges so we get one single exchange containing all
+ // the others
+ .aggregate(new GroupedExchangeAggregationStrategy()).constant(true)
// wait for 0.5 seconds to aggregate
- .completionTimeout(500L)
- // group the exchanges so we get one single exchange containing all the others
- .groupExchanges()
- .to("mock:result");
+ .completionTimeout(500L).to("mock:result");
----
As a result we have one outgoing `Exchange` being
-routed the `"mock:result"` endpoint. The exchange is a holder
+routed to the `"mock:result"` endpoint. The exchange is a holder
containing all the incoming Exchanges.
The output of the aggregator will then contain the exchanges grouped