logger.debug("Received exchange: status: " + exchange.getStatus() + ", role: "
+ (exchange.getRole() == Role.CONSUMER ? "consumer" : "provider"));
}
if (exchange.getRole() == Role.PROVIDER) {
boolean dynamic = false;
ServiceEndpoint endpoint = exchange.getEndpoint();
String key = EndpointSupport.getKey(exchange.getEndpoint());
Endpoint ep = (Endpoint) this.component.getRegistry().getEndpoint(key);
if (ep == null) {
if (endpoint.getServiceName().equals(getEPRServiceName())) {
ep = getResolvedEPR(exchange.getEndpoint());
dynamic = true;
}
if (ep == null) {
throw new IllegalStateException("Endpoint not found: " + key);