jamesge commented on a change in pull request #1005: ignore ELIMIT for circuit
breaker
URL: https://github.com/apache/incubator-brpc/pull/1005#discussion_r362366503
##########
File path: src/brpc/circuit_breaker.cpp
##########
@@ -171,6 +206,10 @@ CircuitBreaker::CircuitBreaker()
}
bool CircuitBreaker::OnCallEnd(int error_code, int64_t latency) {
+ const std::set<int>* ignored_error_codes = GetOrNewIgnoredErrorCodes();
Review comment:
1. 我记得曾忽略过ELIMIT?
2. 如果一定要忽略,建议写死并说明理由
3. 如果一定需要可配置,应该把error code有序地存在vector中,在比较短时直接find,比较长时std::binary_search
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]