@Override public void unregisterService(final URI serviceUri) throws IOException { registered.remove(serviceUri.toString()); for (final DiscoveryAgent agent : agents) { agent.unregisterService(serviceUri); } }
public void unregisterService(URI serviceUri) throws IOException { registered.remove(serviceUri.toString()); for (DiscoveryAgent agent : agents) { agent.unregisterService(serviceUri); } }
public void stop() throws ServiceException { synchronized (this) { DiscoveryAgent agent = SystemInstance.get().getComponent(DiscoveryAgent.class); if (agent != null && discoveryUriFormat != null && uri != null) { try { agent.unregisterService(uri); } catch (IOException e) { log.error("Cannot unregister service '" + getName() + "' with DiscoveryAgent.", e); } } next.stop(); if (socketListener != null) { socketListener.stop(); socketListener = null; } } }
@Override public void stop() throws ServiceException { synchronized (this) { final DiscoveryAgent agent = SystemInstance.get().getComponent(DiscoveryAgent.class); if (agent != null && this.discoveryUriFormat != null && this.serviceUri != null) { try { agent.unregisterService(this.serviceUri); } catch (IOException e) { log.error("Cannot unregister service '" + this.getName() + "' with DiscoveryAgent.", e); } } this.next.stop(); if (this.socketListener != null) { this.socketListener.stop(); this.socketListener = null; } } }