File tree 1 file changed +4
-13
lines changed
1 file changed +4
-13
lines changed Original file line number Diff line number Diff line change @@ -158,20 +158,11 @@ func (connection *redisConnection) heartbeat(errChan chan<- error) {
158
158
159
159
errorCount ++
160
160
161
- if errorCount >= HeartbeatErrorLimit {
162
- // reached error limit
163
- connection .StopAllConsuming ()
164
- // Clients reading from errChan need to see this error
165
- // This allows them to shut themselves down
166
- // Therefore we block adding it to errChan to ensure delivery
167
- errChan <- & HeartbeatError {RedisErr : err , Count : errorCount }
168
- return
169
- } else {
170
- select { // try to add error to channel, but don't block
171
- case errChan <- & HeartbeatError {RedisErr : err , Count : errorCount }:
172
- default :
173
- }
161
+ select { // try to add error to channel, but don't block
162
+ case errChan <- & HeartbeatError {RedisErr : err , Count : errorCount }:
163
+ default :
174
164
}
165
+
175
166
// keep trying until we hit the limit
176
167
}
177
168
}
You can’t perform that action at this time.
0 commit comments