-
Type: Bug
-
Resolution: Fixed
-
Priority: Major - P3
-
Affects Version/s: 4.2.8
-
Component/s: Replication
-
None
-
Fully Compatible
-
ALL
-
v4.4, v4.2
-
Repl 2020-10-05, Repl 2020-10-19
The bgsync _producer() method runs in a loop until stop() is called asynchronously.
If, after this critical section is run
stop() is called (as it would be during step-up), then before
is reached, the primary clears the applied-through time (as it normally does), the applied-through time will be re-set to the last applied optime. This state will persist until the next time the node becomes secondary and applies a batch. If the node restarts during that time, it will invariant and need to be re-synced.
We need to hold the mutex and ensure the producer is running while checking if applied-through is clear and setting it.
- related to
-
SERVER-62379 Fix deadlock between ReplicationCoordinator and BackgroundSync on stepUp
- Closed