| 1068 | } |
| 1069 | |
| 1070 | void 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 | |
| 1078 | int Socket::ReleaseReferenceIfIdle(int idle_seconds) { |
| 1079 | const int64_t last_active_us = last_active_time_us(); |