use of org.apache.camel.component.sjms.batch.ListAggregationStrategy in project camel by apache.
the class ManualBatchFromQueueTest method createCamelContext.
@Override
protected CamelContext createCamelContext() throws Exception {
SimpleRegistry registry = new SimpleRegistry();
registry.put("testStrategy", new ListAggregationStrategy());
CamelContext camel = new DefaultCamelContext(registry);
SjmsBatchComponent sjms = new SjmsBatchComponent();
sjms.setAsyncStartListener(true);
log.info("Using live connection to existing ActiveMQ broker running on {}", url);
sjms.setConnectionFactory(new ActiveMQConnectionFactory(url));
camel.addComponent("sjms-batch", sjms);
return camel;
}
Aggregations