Expression expression = getExpression().createExpression(routeContext);
ObjectHelper.notNull(config, "config", this);
ObjectHelper.notNull(expression, "expression", this);
Resequencer resequencer = new Resequencer(routeContext.getCamelContext(), processor, expression,
config.isAllowDuplicates(), config.isReverse());
resequencer.setBatchSize(config.getBatchSize());
resequencer.setBatchTimeout(config.getBatchTimeout());
if (config.getIgnoreInvalidExchanges() != null) {
resequencer.setIgnoreInvalidExchanges(config.getIgnoreInvalidExchanges());
}
return resequencer;
}