SERVER-136330ClosedGone away

Gate `updateStatsAfterRepair` behind repair modes

This requires write permissions on the database and can write to an instance that may have been spun up temporarily for offline validate.

Affected Versions
Versions known to exhibit this issue

No affected versions recorded.

Fixed Versions
Versions that include the fix

No fix available yet.

Components
Server components related to this issue

No components specified.

Labels
Tags and classification
validate