Added the possibility to create a client instance by context
This commit is contained in:
parent
031372c497
commit
c8518b5951
|
@ -17,5 +17,11 @@ public class ResourceRegistryPublisherFactory {
|
||||||
logger.trace("The {} will be contacted at {}", Constants.SERVICE_NAME, address);
|
logger.trace("The {} will be contacted at {}", Constants.SERVICE_NAME, address);
|
||||||
return new ResourceRegistryPublisherImpl(address);
|
return new ResourceRegistryPublisherImpl(address);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static ResourceRegistryPublisher create(String context) {
|
||||||
|
String address = String.format("%s/%s", ServiceInstance.getServiceURL(context),Constants.SERVICE_NAME);
|
||||||
|
logger.trace("The {} will be contacted at {}", Constants.SERVICE_NAME, address);
|
||||||
|
return new ResourceRegistryPublisherImpl(address);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue