SERVER-15528 Refactor DistinctScan to do less in each work() call