use of org.mule.runtime.core.privileged.routing.RoutingException in project mule by mulesoft.
the class RoundRobin method route.
/**
* Process the event using the next target route in sequence
*/
@Override
public CoreEvent route(CoreEvent event) throws MuleException {
int modulo = getAndIncrementModuloN(routes.size());
if (modulo < 0) {
throw new CouldNotRouteOutboundMessageException(this);
}
Processor mp = routes.get(modulo);
try {
return doProcessRoute(mp, event);
} catch (MuleException ex) {
throw new RoutingException(this, ex);
}
}
Aggregations