Question regarding Zone sharding with Range key, referred doc: https://www.mongodb.com/docs/v5.0/tutorial/sharding-segmenting-data-by-location/
data estimation: 1500GB
Have a Collection with shard key like: country: 1, cityId: 1, userId: 1
country has only 4 option(low cardinality): US, UK, IND, UE
cityId and userId is UUID,
I am planning to use Zone Sharding, 1 zone (4 shard).
with zone range:
example:
sh.addTagRange(“db.collection”, { “country” : “US”, “city” : MinKey, “userId”: MinKey }, { “country” : “US”, “city” : MaxKey, “userId”: MaxKey }, “USA”);
wanted to understand whether the shard key will do balanced distribution in zone cluster and how.(having low cardinality of first prefix value)