注释类型 DubboService
-
@Documented @Retention(RUNTIME) @Target(TYPE) @Inherited public @interface DubboService
Class-level annotation used for declaring Dubbo service- 从以下版本开始:
- 2.7.7
-
-
可选元素概要
可选元素 修饰符和类型 可选元素 说明 StringaccesslogAccess log for the service, default value is ""intactivesMaximum active requests allowed, default value is 0StringapplicationApplication spring bean namebooleanasyncWhether to enable async invocation, default value is falseStringcacheSpecify cache implementation for service invocation, legal values include: lru, threadlocal, jcacheintcallbacksThe callback instance limit peer connectionStringclusterCluster strategy, you can useClusterRules.FAIL_FAST……intconnectionsMaximum connections service provider can accept, default value is 0 - connection is sharedintdelayDelay time for service registration, default value is 0booleandeprecatedWhether the service is deprecated, default value is falseStringdocumentService doc, default value is ""booleandynamicWhether the service is dynamic, default value is trueintexecutesMaximum concurrent executes for the service, default value is 0 - no limitsbooleanexportWhether to export service, default value is trueString[]filterFilters for service invocationStringgroupService group, default value is empty stringClass<?>interfaceClassInterface class, default value is void.classStringinterfaceNameInterface class name, default value is empty stringStringlayerService layer, default value is empty stringString[]listenerListeners for service exporting and unexportingStringloadbalanceLoad balance strategy, you can useLoadbalanceRules.RANDOM……Stringlocal已过时。Method[]methodsmethods supportStringmockService mock name, use interface name + Mock if not setStringmoduleModule spring bean nameStringmonitorMonitor spring bean nameStringonconnectCallback method name when connected, default value is empty stringStringondisconnectCallback method name when disconnected, default value is empty stringStringownerService owner, default value is empty stringString[]parametersCustomized parameter key-value pair, for example: {key1, value1, key2, value2}StringpathService path, default value is empty stringString[]protocolProtocol spring bean namesStringproviderProvider spring bean nameStringproxyHow the proxy is generated, legal values include: jdk, javassistbooleanregisterWhether to register the service to register center, default value is trueString[]registryRegistry spring bean nameintretriesService invocation retry timesbooleansentWhether the async request has already been sent, the default value is falseStringstubService stub name, use interface name + Local if not setStringtagService tag nameinttimeoutTimeout value for service invocation, default value is 0StringtokenService token, default value is falseStringvalidationWhether to use JSR303 validation, legal values are: true, falseStringversionService version, default value is empty stringintweightService weight value, default value is 0
-
-
-
元素详细资料
-
interfaceClass
Class<?> interfaceClass
Interface class, default value is void.class- 默认值:
- void.class
-
-
-
interfaceName
String interfaceName
Interface class name, default value is empty string- 默认值:
- ""
-
-
-
version
String version
Service version, default value is empty string- 默认值:
- ""
-
-
-
group
String group
Service group, default value is empty string- 默认值:
- ""
-
-
-
path
String path
Service path, default value is empty string- 默认值:
- ""
-
-
-
token
String token
Service token, default value is false- 默认值:
- ""
-
-
-
accesslog
String accesslog
Access log for the service, default value is ""- 默认值:
- ""
-
-
-
document
String document
Service doc, default value is ""- 默认值:
- ""
-
-
-
stub
String stub
Service stub name, use interface name + Local if not set- 默认值:
- ""
-
-
-
cluster
String cluster
Cluster strategy, you can useClusterRules.FAIL_FAST……- 默认值:
- ""
-
-
-
proxy
String proxy
How the proxy is generated, legal values include: jdk, javassist- 默认值:
- ""
-
-
-
onconnect
String onconnect
Callback method name when connected, default value is empty string- 默认值:
- ""
-
-
-
ondisconnect
String ondisconnect
Callback method name when disconnected, default value is empty string- 默认值:
- ""
-
-
-
owner
String owner
Service owner, default value is empty string- 默认值:
- ""
-
-
-
layer
String layer
Service layer, default value is empty string- 默认值:
- ""
-
-
-
loadbalance
String loadbalance
Load balance strategy, you can useLoadbalanceRules.RANDOM……- 默认值:
- "random"
-
-
-
mock
String mock
Service mock name, use interface name + Mock if not set- 默认值:
- ""
-
-
-
validation
String validation
Whether to use JSR303 validation, legal values are: true, false- 默认值:
- ""
-
-
-
cache
String cache
Specify cache implementation for service invocation, legal values include: lru, threadlocal, jcache- 默认值:
- ""
-
-
-
filter
String[] filter
Filters for service invocation- 另请参阅:
Filter
- 默认值:
- {}
-
-
-
listener
String[] listener
Listeners for service exporting and unexporting- 另请参阅:
ExporterListener
- 默认值:
- {}
-
-
-
parameters
String[] parameters
Customized parameter key-value pair, for example: {key1, value1, key2, value2}- 默认值:
- {}
-
-
-
application
String application
Application spring bean name- 默认值:
- ""
-
-
-
module
String module
Module spring bean name- 默认值:
- ""
-
-
-
provider
String provider
Provider spring bean name- 默认值:
- ""
-
-
-
protocol
String[] protocol
Protocol spring bean names- 默认值:
- {}
-
-
-
monitor
String monitor
Monitor spring bean name- 默认值:
- ""
-
-
-
registry
String[] registry
Registry spring bean name- 默认值:
- {}
-
-
-
tag
String tag
Service tag name- 默认值:
- ""
-
-
-
methods
Method[] methods
methods support- 返回:
- 默认值:
- {}
-
-