return this;
}
@Override
public Processor createProcessor(RouteContext routeContext) throws Exception {
Policy policy = resolvePolicy(routeContext);
ObjectHelper.notNull(policy, "policy", this);
// before wrap
policy.beforeWrap(routeContext, this);
// create processor after the before wrap
Processor childProcessor = this.createChildProcessor(routeContext, true);
// wrap
Processor target = policy.wrap(routeContext, childProcessor);
// wrap the target so it becomes a service and we can manage its lifecycle
WrapProcessor wrap = new WrapProcessor(target, childProcessor);
return wrap;
}