Build indexes only after all shard scanners done

Even though the index was being created concurrently, the inserts that
were occuring after the index was made were drastically slower, so they
weren't even finishing in time.

We need to delay the index creation until all three are done, so they
write their finish time to the metadata table, and then immediately
check to see if they were the nth person to write, where n is the
number of shards.