@SPI(value="metadata",
scope=APPLICATION)
public interface ServiceNameMapping
extends org.apache.dubbo.rpc.service.Destroyable
| Modifier and Type | Field and Description |
|---|---|
static String |
DEFAULT_MAPPING_GROUP |
| Modifier and Type | Method and Description |
|---|---|
static String |
buildGroup(String serviceInterface) |
static String |
buildMappingKey(org.apache.dubbo.common.URL url) |
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.
|
static Set<String> |
getAppNames(String content) |
Map<String,Set<String>> |
getCachedMapping() |
Set<String> |
getCachedMapping(String mappingKey) |
Set<String> |
getCachedMapping(org.apache.dubbo.common.URL consumerURL) |
static ServiceNameMapping |
getDefaultExtension(org.apache.dubbo.rpc.model.ScopeModel scopeModel)
Get the default extension of
ServiceNameMapping |
void |
initInterfaceAppMapping(org.apache.dubbo.common.URL subscribedURL)
Init the mapping data from local storage and url parameter.
|
boolean |
map(org.apache.dubbo.common.URL url)
Map the specified Dubbo service interface, group, version and protocol to current Dubbo service name
|
void |
putCachedMapping(String serviceKey,
Set<String> apps) |
Set<String> |
removeCachedMapping(String serviceKey) |
MappingListener |
stopListen(org.apache.dubbo.common.URL subscribeURL,
MappingListener listener) |
static String |
toStringKeys(Set<String> serviceNames) |
$destroystatic final String DEFAULT_MAPPING_GROUP
boolean map(org.apache.dubbo.common.URL url)
static ServiceNameMapping getDefaultExtension(org.apache.dubbo.rpc.model.ScopeModel scopeModel)
ServiceNameMappingServiceNameMappingstatic String buildMappingKey(org.apache.dubbo.common.URL url)
void initInterfaceAppMapping(org.apache.dubbo.common.URL subscribedURL)
Set<String> getAndListen(org.apache.dubbo.common.URL registryURL, org.apache.dubbo.common.URL subscribedURL, MappingListener listener)
listener - listener that will be notified on mapping changeMappingListener stopListen(org.apache.dubbo.common.URL subscribeURL, MappingListener listener)
Copyright © 2011–2022 The Apache Software Foundation. All rights reserved.