use of com.yahoo.messagebus.network.ServiceAddress in project vespa by vespa-engine.
the class LocalNetwork method allocServiceAddress.
@Override
public boolean allocServiceAddress(RoutingNode recipient) {
String service = recipient.getRoute().getHop(0).getServiceName();
ServiceAddress address = wire.resolveServiceAddress(service);
if (address == null) {
recipient.setError(new Error(NO_ADDRESS_FOR_SERVICE, "No address for service '" + service + "'."));
return false;
}
recipient.setServiceAddress(address);
return true;
}
Aggregations