I'm using various enterprise integration patterns that support exchange aggregation within Talend routes (e.g. Content-Enricher, Aggregator, Recipient-List and so on) and am able to create a bean that implements the AggregationStrategy interface just fine.
However, I was wondering how I would go about implementing a bean where I define multiple aggregate methods (with custom names) within the same bean. The use-case here is that I need to aggregate multiple times within a route and having to create separate beans each time is a bit silly. According to the documentation for poll enrich for example, I should be able somehow define a parameter called strategyMethodName to specify the aggregation strategy method name to use.
The problem is, I can't figure out how to do this in Talend as the Aggregation Strategy field in the cContentEnricher Talend component for example is hard-coded to create a new instance of my bean so I can't so something like:
... .pollEnrich( "file:path/to/file/?fileName=some.file", 3000, AggregationStrategies.bean( new beans.CustomAggregation(), "myCustomAggregationMethodName" ) ) ...
Reference documentation for the AggregationStrategies.bean method here.
Does anyone know how to call a custom method name for aggregation in Talend? Maybe using cBean or cBeanRegister? I'm using Talend ESB 6.4.1
Solved! Go to Solution.
Watch the recorded webinar!
Introduction to Talend Open Studio for Data Integration.
Test drive Talend's enterprise products.
Practical steps to developing your data integration strategy.