if (publisherService == null) {
if (endpointURL == null) {
UDDIClient client = UDDIClientContainer.getUDDIClient(clientName);
endpointURL = client.getClientConfig().getUDDINode(nodeName).getJuddiApiUrl();
}
JUDDIApiService service = new JUDDIApiService();
publisherService = (JUDDIApiPortType) service.getPort(JUDDIApiPortType.class);
}
if (endpointURL != null) {
Map<String, Object> requestContext = ((BindingProvider) publisherService).getRequestContext();
requestContext.put(BindingProvider.ENDPOINT_ADDRESS_PROPERTY, endpointURL);
setCredentials(requestContext);