blob: 0edf916803ee912ab5e70326b30db6096efdc925 [file] [log] [blame]
---
servicecomb:
protocols:
grpc:
listenAddress: 192.168.88.64:40107
http:
listenAddress: 192.168.88.64:30111
rest-admin:
listenAddress: 192.168.88.64:30112 # listen addr use to adminAPI
service:
registry:
address: http://127.0.0.1:30100 # uri of service center
#address: https://cse.cn-north-1.myhuaweicloud.com:443 # uri of service center
scope: full #set full to be able to discover other app's service
watch: false # set if you want to watch instance change event
autoIPIndex: true # set to true if u want to resolve source IP to microservice
# config:
# client:
# serverUri: https://cse.cn-north-1.myhuaweicloud.com:443 #uri of config center
# refreshMode: 1 # 1: only pull config.
# refreshInterval: 30 # unit is second
# monitor: #Send monitoring data to CSE monitor Server
# client:
# serverUri: https://cse.cn-north-1.myhuaweicloud.com:443 # monitor server url
handler:
chain:
Consumer:
outgoing: #tracing-consumer #consumer handlers
#If registry type is pilot then to make sure traffic goes through mesher provider new handler needs to be added to consumer after loadbalance handler
#ex: router, ratelimiter-consumer, bizkeeper-consumer, loadbalance, port-selector, transport
Provider:
incoming: #tracing-provider,bizkeeper-provider #provider handlers
# loadbalance:
# strategy:
# name: RoundRobin # Random|RoundRobin|SessionStickiness
# retryEnabled: false # if there is error, retry request or not
# retryOnNext: 2 # times to switch to another instance based on strategy
# retryOnSame: 3 # times to retry on the same instance
# backoff: # backoff policy of retried request
# kind: constant # jittered/constant/zero
# MinMs: 200 # millisecond, Minimum duration to backoff
# MaxMs: 400 # millisecond, Maximum duration to backoff
## circuit breaker configurations
# isolation:
# Consumer:
# timeout:
# enabled: true
# timeoutInMilliseconds: 500
# maxConcurrentRequests: 10
# Provider:
# timeout:
# enabled: true
# timeoutInMilliseconds: 500
# maxConcurrentRequests: 10
# circuitBreaker:
# Consumer:
# enabled: true
# forceOpen: false
# forceClosed: false
# sleepWindowInMilliseconds: 10000
# requestVolumeThreshold: 1
# errorThresholdPercentage: 1
# Provider:
# enabled: true
# forceOpen: true
# forceClosed: false
# sleepWindowInMilliseconds: 10000
# requestVolumeThreshold: 1
# errorThresholdPercentage: 20
# fallback:
# Consumer:
# enabled: true
# maxConcurrentRequests: 1
# Provider:
# enabled: true
# maxConcurrentRequests: 1
# fallbackpolicy:
# Consumer:
# policy: returnnull
# Provider:
# policy: returnnull
# flowcontrol:
# Consumer: # for consumer
# qps:
# enabled: true # enable rate limiting or not
# global:
# limit: 100 # default limit of consumer
# limit:
# Server: 100 # rate limit for request to a provider,it represents 100 request per second
# Provider:
# qps:
# enabled: true # enable rate limiting or not
# global:
# limit: 0 # default limit of provider
# limit:
# Server: 0 # rate limit for request from a provider, it represents 100 request per second
#ssl:
## Set those config to make mesher as https service
# mesher.Provider.cipherPlugin: default
# mesher.Provider.verifyPeer: false
# mesher.Provider.cipherSuits: TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256,TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384
# mesher.Provider.protocol: TLSv1.2
# mesher.Provider.caFile:
# mesher.Provider.certFile:
# mesher.Provider.keyFile:
# mesher.Provider.certPwdFile:
## Mesher TLS is base on Go Chassis TLS config
## If users wan't to use transparent, ssl config for consumer and provider must be supplied.
## The provider is the service which run in the same host/pod with mesher. for example the service name of provider is AccountService, then the ssl tag is AccountService.rest.Provider
## if u set this , no need to consider about expose your own service as https service,
## your service can only listen on 127.0.0.1, mesher wil expose https and use http to communicate with your service
# AccountService.rest.Provider.cipherPlugin: default
# AccountService.rest.Provider.verifyPeer: false
# AccountService.rest.Provider.cipherSuits: TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256,TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384
# AccountService.rest.Provider.protocol: TLSv1.2
# AccountService.rest.Provider.caFile:
# AccountService.rest.Provider.certFile:
# AccountService.rest.Provider.keyFile:
# AccountService.rest.Provider.certPwdFile:
## If a service want to use transparent tls to call other services, it must supplies consumer ssl config for these services.
## for example StoreWeb want to communicate with Account service the config is like below
# AccountService.rest.Consumer.cipherPlugin: default
# AccountService.rest.Consumer.verifyPeer: false
# AccountService.rest.Consumer.cipherSuits: TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256,TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384
# AccountService.rest.Consumer.protocol: TLSv1.2
# AccountService.rest.Consumer.caFile:
# AccountService.rest.Consumer.certFile:
# AccountService.rest.Consumer.keyFile:
# AccountService.rest.Consumer.certPwdFile:
tracing:
enabled: true #enable distribution tracing
collectorType: zipkin #zipkin: Send tracing info to zipkin server
#namedPipe: Write tracing info to linux named pipe.
collectorTarget: http://127.0.0.1:9411/api/v1/spans #If the collectorType is "zipkin", the target is a zipkin server url, if the collecterType is "file" or "namedPipe", the target is a file path.
batchSize: 1
batchInterval: 2s