It seems cleanUpAfterBuild can be called after the primary steps down to the secondary. In that case, we would end up having an untimestamped write to the catalog because this wouldn't get executed.
- related to
-
SERVER-42799 obtain timestamp for cleaning up index build without noop write
- Closed