Default serverStatus sections are used by FTDC and also for emergency debugging. Because of this, we should try to ensure that they can always make forward progress. Taking locks or performing I/O runs the risk that a server in some degraded state will not be able to collect FTDC metrics and thus will impede diagnostics.
The shardingStatistics serverStatus section is included by default if the node is a cluster node, but it also takes locks. We should be able to read the estimated number of documents using the lock-free variant of the function.