-
Type: Bug
-
Resolution: Done
-
Priority: Minor - P4
-
Affects Version/s: 2.4.6
-
Component/s: Replication
-
None
-
Environment:Bug a result of code review
-
ALL
The class ReplSetHealthPollTask has a copy of a HeartbeatInfo that it passes to Members upon each heartbeat. This copy's lastHeartbeatRecv value is never updated. Only the copy in the Member's HeartbeatInfo is updated.
Therefore, ReplSetHealthPollTask::m.lastHeartbeatRecv is never accurate.
Basically, the following code in ReplSetHealthPollTask::down is a no-op, because the if-clause will always evaluate to false:
if (m.lastHeartbeatRecv+2 >= time(0)) { log() << "replset info " << h.toString() << " just heartbeated us, but our heartbeat failed: " << msg << ", not changing state" << rsLog; // we don't update any of the heartbeat info, though, since we didn't get any info // other than "not down" from having it heartbeat us return; }
- is related to
-
SERVER-9283 lastHeartbeatRecv flaps between invalid and valid dates
- Closed