0
0
HLDsystem_design~20 mins

Why database scaling handles data growth in HLD - Challenge Your Understanding

Choose your learning style9 modes available
Challenge - 5 Problems
🎖️
Database Scaling Mastery
Get all challenges correct to earn this badge!
Test your skills under time pressure!
🧠 Conceptual
intermediate
2:00remaining
How does vertical scaling improve database capacity?

Imagine you have a small shop and you want to serve more customers. You decide to buy a bigger cash register that can handle more transactions at once. In database terms, this is called vertical scaling.

Which of the following best explains how vertical scaling helps handle data growth?

ABy creating multiple copies of the database to improve read speed but not increase storage capacity.
BBy splitting the database into smaller parts and storing them on different servers to distribute the load.
CBy adding more powerful hardware like CPU and RAM to the existing database server to handle more data and queries.
DBy compressing the data to reduce its size without changing the hardware.
Attempts:
2 left
💡 Hint

Think about upgrading the size of one machine versus adding more machines.

Architecture
intermediate
2:00remaining
What is horizontal scaling in databases?

Suppose your shop is growing fast and one big cash register is not enough. You decide to open more cash registers to serve customers in parallel. This is similar to horizontal scaling in databases.

Which option best describes horizontal scaling?

AUpgrading the existing server with better hardware components.
BAdding more servers to share the database load by splitting data across them.
CBacking up the database regularly to prevent data loss.
DUsing a faster network connection to speed up data transfer.
Attempts:
2 left
💡 Hint

Think about adding more machines instead of making one machine bigger.

scaling
advanced
2:00remaining
Which challenge is unique to horizontal scaling compared to vertical scaling?

When scaling databases, vertical and horizontal scaling have different challenges. Which of the following is a challenge unique to horizontal scaling?

AManaging data consistency across multiple servers.
BUpgrading the CPU and memory of a single server.
CIncreasing disk space on the existing server.
DReducing the size of database indexes.
Attempts:
2 left
💡 Hint

Think about what happens when data is spread over many machines.

tradeoff
advanced
2:00remaining
What is a tradeoff when choosing vertical scaling over horizontal scaling?

Choosing between vertical and horizontal scaling depends on tradeoffs. Which of the following is a tradeoff when choosing vertical scaling?

ALimited by the maximum hardware capacity of a single server, making future growth harder.
BComplexity in splitting data and queries across many servers.
CHigher network latency due to data being spread over multiple machines.
DNeed to manage multiple database instances and synchronization.
Attempts:
2 left
💡 Hint

Think about the limits of one machine versus many machines.

estimation
expert
2:00remaining
Estimate the number of servers needed for horizontal scaling

Your database currently runs on one server handling 1000 queries per second. You expect traffic to grow to 10,000 queries per second. Each server can handle 1500 queries per second before performance degrades.

How many servers do you need to handle the expected load with horizontal scaling?

A5 servers
B6 servers
C8 servers
D7 servers
Attempts:
2 left
💡 Hint

Divide total expected queries by capacity per server, then round up.