$indexStats includes the "shard" field on version 4.2 when run on an unsharded collection (correct behavior). However on version 4.4 onwards the "shard" field is missing for unsharded collections even though it should be present.
See comments for more info.
- related to
-
SERVER-44915 Extend $indexStats output to include full index options and shard name
- Closed