MCPcopy Create free account
hub / github.com/apache/brpc / FeedbackCircuitBreaker

Method FeedbackCircuitBreaker

src/brpc/socket.cpp:1070–1076  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1068}
1069
1070void Socket::FeedbackCircuitBreaker(int error_code, int64_t latency_us) {
1071 if (!GetOrNewSharedPart()->circuit_breaker.OnCallEnd(error_code, latency_us)) {
1072 if (SetFailed(main_socket_id()) == 0) {
1073 LOG(ERROR) << "Socket[" << *this << "] isolated by circuit breaker";
1074 }
1075 }
1076}
1077
1078int Socket::ReleaseReferenceIfIdle(int idle_seconds) {
1079 const int64_t last_active_us = last_active_time_us();

Callers 1

OnCompleteMethod · 0.80

Calls 1

OnCallEndMethod · 0.80

Tested by

no test coverage detected