*/
protected Processor wrapInErrorHandler(RouteContext routeContext, Processor target) throws Exception {
ObjectHelper.notNull(target, "target", this);
ErrorHandlerWrappingStrategy strategy = routeContext.getErrorHandlerWrappingStrategy();
if (strategy != null) {
return strategy.wrapProcessorInErrorHandler(this, target);
}
return getErrorHandlerBuilder().createErrorHandler(routeContext, target);
}
protected ErrorHandlerBuilder createErrorHandlerBuilder() {