public class DiscoveryRegistry extends Object implements DiscoveryListener, DiscoveryAgent
| Constructor and Description |
|---|
DiscoveryRegistry() |
DiscoveryRegistry(DiscoveryAgent agent) |
| Modifier and Type | Method and Description |
|---|---|
void |
addDiscoveryAgent(DiscoveryAgent agent) |
void |
addDiscoveryListener(DiscoveryListener listener) |
Set<URI> |
getServices() |
void |
registerService(URI serviceUri)
register a service
|
void |
removeDiscoveryListener(DiscoveryListener listener) |
void |
reportFailed(URI serviceUri)
A process actively using a service may see it go down before the DiscoveryAgent notices the
service's failure.
|
void |
serviceAdded(URI service) |
void |
serviceRemoved(URI service) |
void |
setDiscoveryListener(DiscoveryListener listener)
Sets the discovery listener
|
void |
unregisterService(URI serviceUri)
register a service
|
public DiscoveryRegistry()
public DiscoveryRegistry(DiscoveryAgent agent)
public void addDiscoveryAgent(DiscoveryAgent agent)
public void registerService(URI serviceUri) throws IOException
DiscoveryAgentregisterService in interface DiscoveryAgentIOExceptionpublic void reportFailed(URI serviceUri) throws IOException
DiscoveryAgentreportFailed in interface DiscoveryAgentIOExceptionpublic void unregisterService(URI serviceUri) throws IOException
DiscoveryAgentunregisterService in interface DiscoveryAgentIOExceptionpublic void setDiscoveryListener(DiscoveryListener listener)
DiscoveryAgentsetDiscoveryListener in interface DiscoveryAgentpublic void addDiscoveryListener(DiscoveryListener listener)
public void removeDiscoveryListener(DiscoveryListener listener)
public void serviceAdded(URI service)
serviceAdded in interface DiscoveryListenerpublic void serviceRemoved(URI service)
serviceRemoved in interface DiscoveryListenerCopyright © 1999–2019 The Apache Software Foundation. All rights reserved.