public abstract class DynamicDirectory<T> extends AbstractDirectory<T> implements NotifyListener
| Constructor and Description |
|---|
DynamicDirectory(Class<T> serviceType,
URL url) |
| Modifier and Type | Method and Description |
|---|---|
void |
addServiceListener(ServiceInstancesChangedListener instanceListener) |
void |
buildRouterChain(URL url) |
void |
destroy() |
void |
discordAddresses() |
List<org.apache.dubbo.rpc.Invoker<T>> |
doList(BitList<org.apache.dubbo.rpc.Invoker<T>> invokers,
org.apache.dubbo.rpc.Invocation invocation) |
List<org.apache.dubbo.rpc.Invoker<T>> |
getAllInvokers() |
URL |
getConsumerUrl()
The currently effective consumer url
|
Class<T> |
getInterface() |
URL |
getOriginalConsumerUrl()
The original consumer url
|
URL |
getRegisteredConsumerUrl()
The url registered to registry or metadata center
|
Registry |
getRegistry() |
ServiceInstancesChangedListener |
getServiceListener() |
URL |
getSubscribeUrl()
The url used to subscribe from registry
|
boolean |
isAvailable() |
boolean |
isNotificationReceived() |
boolean |
isShouldRegister() |
void |
setInvokersChangedListener(InvokersChangedListener listener) |
void |
setProtocol(org.apache.dubbo.rpc.Protocol protocol) |
void |
setRegisteredConsumerUrl(URL url) |
void |
setRegistry(Registry registry) |
void |
setSubscribeUrl(URL subscribeUrl) |
void |
subscribe(URL url) |
void |
unSubscribe(URL url) |
addDisabledInvoker, addInvalidateInvoker, checkConnectivity, getCheckConnectivityPermit, getConnectivityCheckFuture, getDisabledInvokers, getInvokers, getInvokersToReconnect, getRouterChain, getUrl, getValidInvokers, isDestroyed, list, recoverDisabledInvoker, refreshInvoker, setConsumerUrl, setRouterChainequals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitnotifyisEmpty, isServiceDiscoverypublic void addServiceListener(ServiceInstancesChangedListener instanceListener)
addServiceListener in interface NotifyListenerpublic ServiceInstancesChangedListener getServiceListener()
getServiceListener in interface NotifyListenerpublic void setProtocol(org.apache.dubbo.rpc.Protocol protocol)
public void setRegistry(Registry registry)
public Registry getRegistry()
public boolean isShouldRegister()
public void subscribe(URL url)
public void unSubscribe(URL url)
public List<org.apache.dubbo.rpc.Invoker<T>> doList(BitList<org.apache.dubbo.rpc.Invoker<T>> invokers, org.apache.dubbo.rpc.Invocation invocation)
doList in class AbstractDirectory<T>public Class<T> getInterface()
getInterface in interface Directory<T>public List<org.apache.dubbo.rpc.Invoker<T>> getAllInvokers()
getAllInvokers in interface Directory<T>public URL getConsumerUrl()
getConsumerUrl in interface NotifyListenergetConsumerUrl in interface Directory<T>getConsumerUrl in class AbstractDirectory<T>public URL getOriginalConsumerUrl()
public URL getRegisteredConsumerUrl()
public URL getSubscribeUrl()
public void setSubscribeUrl(URL subscribeUrl)
public void setRegisteredConsumerUrl(URL url)
public void buildRouterChain(URL url)
public boolean isAvailable()
isAvailable in interface Nodepublic void destroy()
destroy in interface Nodedestroy in class AbstractDirectory<T>public void discordAddresses()
discordAddresses in interface Directory<T>discordAddresses in class AbstractDirectory<T>public void setInvokersChangedListener(InvokersChangedListener listener)
public boolean isNotificationReceived()
isNotificationReceived in interface Directory<T>Copyright © 2011–2022 The Apache Software Foundation. All rights reserved.