dubbo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] wanhuhou commented on issue #1505: Our company has developed CircuitBreaker, on the consumer side,can we open source?
Date Mon, 26 Mar 2018 03:03:50 GMT
wanhuhou commented on issue #1505: Our company has developed CircuitBreaker, on the consumer side,can we open source?
URL: https://github.com/apache/incubator-dubbo/issues/1505#issuecomment-376033573
 
 
   Our  circuitBreaker is done in the filter, and the basic principle is to record QPS, error
rate and so on with the ip- interface to judge whether or not it is circuitBreaker.
   The main solution is to solve the problem of continuous request for the machine when the
single service machine has access abnormity.
   
   1, CircuitBreaker operate on the consumer side. When the server fails to provide services
normally, the consumption terminal will automatically drop the abnormal service address.
   
         For example, the HelloService service has three server servers, A, server B, and
server C.
   The consumer side access the HelloService.sayHi () method, each consumer will record the
address, service name, and method name of the specific access service.
   In the first step, when the server A HelloService.sayHi () method is abnormal and reaches
the threshold, the consumption end's fusing mechanism removes the access address of the server
A.
   The subsequent access can only be the server - side B, the server - side C. At this point,
the state of the CircuitBreaker is open;
   The second step is the window period, which is configured freely, such as configuring 5000ms,
that is, when the server A is removed for 5 seconds, the A access address of the server is
re placed into the address list.
   At this time, the state is half-open, which is used to try to access the service side A.
The 6 consecutive visits indicate that the service A of the server is recovered, and the state
changes to closed at this time.
   If you try to access the server - side A failure, then the half-open state changes to open,
retries it, and waits after 5 seconds to retry.
   2, after the CircuitBreaker, it reduces the access pressure to the exception service machine
and makes the client no longer access the exception machine to improve the probability of
successful return.
   
   
   Configurable parameters:
    circuitBreakerRequestVolumeThreshold=20 //与circuitBreakerRollingStatisticalWindowBuckets配合使用,默认15秒内的访问量是10,才有可能开启熔断
    circuitBreakerSleepWindowInMilliseconds=60000//60秒之后重试,单位是ms
    circuitBreakerErrorThresholdPercentage=80//错误率80% 
    circuitBreakerOpenweight=1 //熔断打开之后重试关闭时的权重 
    circuitBreakerCloseweight=1000 //存在熔断服务且过了熔断窗口可重试时没有被熔断的服务。
    circuitBreakerRollingStatisticalWindowBuckets //环境变量中配置	
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

Mime
View raw message