Previously, the test used awaitSyncSource to wait until it was safe to write to a new primary, which doesn't really make sense. The more robust way to do it is to call getPrimary(). As a bonus, stopServerReplication is a better way to ensure that writes don't progagate to a particular secondary than simply disconnecting that secondary from the primary. Finally, the test now uses a checkLog to make sure the server has arrived at the hangDuringBatchInsert fail point, rather than a one second sleep.
5.4 KiB
5.4 KiB