1

Assume I have a collection with 100 million rows and I will need to do sharding to improve performance. However, the collection is heavily indexed. For some reasons, there are 20 different indexes created for the collection.

Based on my understanding, the collection is going to be sharded based on a shard key, which is similar to an index. How would the rest 20-1 =19 indexes perform after sharding? If I am writing a record, would sharding helps performance at all in this case? Would an index get broke down based on how many shards you have?

Qing Liu
  • 11
  • 2

1 Answers1

0

The indexes are handled by mongods on each shard. They are separate from decision to shard or shard key choice.

D. SM
  • 13,584
  • 3
  • 12
  • 21