Database Sharding — Concept Check
Questions on Database Sharding. Sharding partitions data across multiple database instances based on a shard key. It enables horizontal scaling of the data tier but introduces complexity in queries, joins, and rebalancing.
Questions in this quiz
6 questions on Database Sharding — Concept Check. Work through them here, then start the quiz to answer them and see your score.
1.A company uses range-based sharding for its database. They notice that one shard is handling significantly more traffic than others. What is likely causing this?
- ANon-uniform distribution of data
- BEfficient load balancing
- CConsistent hashing
- DEven distribution of data
2.An application uses hash-based sharding. The team wants to add a new shard. What challenge might they face?
- AIncreased lookup latency
- BDifficulty in range queries
- CRehashing existing data
- DHotspots due to uneven distribution
3.A database uses directory-based sharding. What is a potential drawback of this approach?
- AInefficient range queries
- BUneven data distribution
- CDifficulty in rebalancing data
- DSingle point of failure in lookup service
4.A team is designing a sharded database system. They want to minimize data movement when adding new shards. Which strategy should they use?
- ADirectory-based sharding
- BRange-based sharding
- CHash-based sharding
- DConsistent hashing
5.An application frequently performs cross-shard joins. What is a recommended strategy to improve performance?
- AUse consistent hashing
- BSwitch to range-based sharding
- CIncrease number of shards
- DDenormalize data to avoid joins
6.A system uses range-based sharding. What is a benefit of this approach?
- AFast range queries within a shard
- BEven distribution of data
- CReduced complexity in rebalancing
- DEliminates hotspots