public abstract class AbstractServiceNameMapping extends Object implements ServiceNameMapping, org.apache.dubbo.rpc.model.ScopeModelAware
DEFAULT_MAPPING_GROUP| Constructor and Description |
|---|
AbstractServiceNameMapping(org.apache.dubbo.rpc.model.ApplicationModel applicationModel) |
| Modifier and Type | Method and Description |
|---|---|
void |
$destroy() |
abstract Set<String> |
get(org.apache.dubbo.common.URL url)
Get the service names from the specified Dubbo service interface, group, version and protocol
|
abstract Set<String> |
getAndListen(org.apache.dubbo.common.URL url,
MappingListener mappingListener)
Get the service names from the specified Dubbo service interface, group, version and protocol
|
Set<String> |
getAndListen(org.apache.dubbo.common.URL registryURL,
org.apache.dubbo.common.URL subscribedURL,
MappingListener listener)
Get the latest mapping result from remote center and register listener at the same time to get notified once mapping changes.
|
Map<String,Set<String>> |
getCachedMapping() |
Set<String> |
getCachedMapping(String mappingKey) |
Set<String> |
getCachedMapping(org.apache.dubbo.common.URL consumerURL) |
Lock |
getMappingLock(String key) |
void |
initInterfaceAppMapping(org.apache.dubbo.common.URL subscribedURL)
Init the mapping data from local storage and url parameter.
|
void |
putCachedMapping(String serviceKey,
Set<String> apps) |
Set<String> |
removeCachedMapping(String serviceKey) |
void |
setApplicationModel(org.apache.dubbo.rpc.model.ApplicationModel applicationModel) |
MappingListener |
stopListen(org.apache.dubbo.common.URL subscribeURL,
MappingListener listener) |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitbuildGroup, buildMappingKey, getAppNames, getDefaultExtension, map, toStringKeyssetFrameworkModel, setModuleModel, setScopeModelpublic AbstractServiceNameMapping(org.apache.dubbo.rpc.model.ApplicationModel applicationModel)
public void setApplicationModel(org.apache.dubbo.rpc.model.ApplicationModel applicationModel)
setApplicationModel in interface org.apache.dubbo.rpc.model.ScopeModelAwarepublic abstract Set<String> get(org.apache.dubbo.common.URL url)
public abstract Set<String> getAndListen(org.apache.dubbo.common.URL url, MappingListener mappingListener)
public void initInterfaceAppMapping(org.apache.dubbo.common.URL subscribedURL)
ServiceNameMappinginitInterfaceAppMapping in interface ServiceNameMappingpublic Set<String> getAndListen(org.apache.dubbo.common.URL registryURL, org.apache.dubbo.common.URL subscribedURL, MappingListener listener)
ServiceNameMappinggetAndListen in interface ServiceNameMappinglistener - listener that will be notified on mapping changepublic MappingListener stopListen(org.apache.dubbo.common.URL subscribeURL, MappingListener listener)
stopListen in interface ServiceNameMappingpublic void putCachedMapping(String serviceKey, Set<String> apps)
putCachedMapping in interface ServiceNameMappingpublic Set<String> getCachedMapping(String mappingKey)
getCachedMapping in interface ServiceNameMappingpublic Set<String> getCachedMapping(org.apache.dubbo.common.URL consumerURL)
getCachedMapping in interface ServiceNameMappingpublic Set<String> removeCachedMapping(String serviceKey)
removeCachedMapping in interface ServiceNameMappingpublic Map<String,Set<String>> getCachedMapping()
getCachedMapping in interface ServiceNameMappingpublic void $destroy()
$destroy in interface org.apache.dubbo.rpc.service.DestroyableCopyright © 2011–2022 The Apache Software Foundation. All rights reserved.