fanliang11 / surging

Surging is a micro-service engine that provides a lightweight, high-performance, modular RPC request pipeline. support Event-based Asynchronous Pattern and reactive programming ,The service engine supports http, TCP, WS,Grpc, Thrift,Mqtt, UDP, and DNS protocols. It uses ZooKeeper and Consul as a registry, and integrates it. Hash, random, polling, Fair Polling as a load balancing algorithm, built-in service governance to ensure reliable RPC communication, the engine contains Diagnostic, link tracking for protocol and middleware calls, and integration SkyWalking Distributed APM
MIT License
3.24k stars 922 forks source link

使用容错降级选择Failover策略时的疑问 #278

Closed hunzhichupo closed 5 years ago

hunzhichupo commented 5 years ago

容错降级当选择Failover策略时,我们会根据FailoverCluster的次数来多次调用BreakeRemoteInvokeService中的InvokeAsync方法,当我们调用失败后我们进行回调,发现一直会调用加入缓存,而没有触发到MonitorRemoteInvokeAsync方法,这个主要出现在服务不可用后去CreateClient直接抛出Exception,从而没有达到BreakeSleepWindowInMilliseconds的时间点,请问这块是不是需要在FailoverHandoverInvoker中的Invoke方法中加入延迟调用?

fanliang11 commented 5 years ago

各种策略对应各种解决方案,服务不可用,产生熔断这个逻辑没有问题,这个issues 我进行关闭