Sample questions
Question 1Easy
What does 'scalability' most precisely mean for a system?
- Handling growing load by adding resources while keeping performance acceptable
- How quickly a developer can add new features
- Its ability to run without any downtime at all, even during hardware failures and deploys
- The maximum number of requests it serves on a single machine
Answer: A. Handling growing load by adding resources while keeping performance acceptable
Explanation
Scalability is about handling more load (users, data, traffic) by adding resources; availability and developer velocity are different properties.
Step-by-step solution
- Scalability is about growth.
- More load handled by adding resources.
- Performance remains acceptable.
Why the other options are wrong
- B. That is maintainability.
- C. That is availability.
- D. That is single-machine throughput.
Question 2Easy
A team handles growth only by moving its database to ever-larger single machines. What is the main long-term problem?
- A hardware ceiling, and one machine stays a single point of failure
- It always requires rewriting the application so that it becomes fully stateless
- It forces data to be partitioned across nodes
- It cannot increase memory available to the process
Answer: A. A hardware ceiling, and one machine stays a single point of failure
Explanation
One machine can only grow so large and, if it fails, the service goes down; scaling up usually needs no code changes.
Step-by-step solution
- Growing only by moving to larger single machines keeps one machine as the whole system.
- Each machine has a hardware limit, so growth eventually stops.
- If that one machine fails, the service goes down.
- So the main long-term problem is a hardware ceiling and a single point of failure (option A).
Why the other options are wrong
- B. Making the app stateless is a separate design goal, not a result of scaling up.
- C. Partitioning data across nodes is what sharding does, which this approach does not require.
- D. Bigger machines can usually add memory, so memory is not the stated problem.
Tip: Scaling up is simple but has a ceiling and one failure point; scaling out avoids both.
Question 3Easy
Latency vs throughput: which statement is correct?
- Lower throughput always means lower latency
- Latency is time per request; throughput is requests completed per second
- Latency and throughput are two names for the same metric measured at different layers
- Throughput is measured in milliseconds per request
Answer: B. Latency is time per request; throughput is requests completed per second
Explanation
Latency measures how long one operation takes; throughput measures how many operations finish per second. Improving one does not automatically improve the other.
Step-by-step solution
- Latency is how long one request takes.
- Throughput is how many requests complete per second.
- They measure different things, so improving one does not automatically improve the other.
- So the correct statement is option B.
Why the other options are wrong
- A. Throughput and latency are not tied, so lower throughput does not always mean lower latency.
- C. Latency and throughput are different metrics, not two names for one.
- D. Throughput is a rate such as requests per second, not milliseconds per request.
Tip: Latency is time per request; throughput is requests per time unit.
Question 4Easy
Adding more CPU and RAM to an existing database server is an example of:
- Sharding the database
- Read replication
- Horizontal scaling (scaling out)
- Vertical scaling (scaling up)
Answer: D. Vertical scaling (scaling up)
Explanation
Vertical scaling makes a single machine bigger; horizontal scaling adds more machines.
Step-by-step solution
- Adding CPU and RAM to the same database server makes that one machine bigger.
- Making one machine bigger is scaling up, also called vertical scaling.
- Horizontal scaling adds more machines instead.
- So the answer is vertical scaling (option D).
Why the other options are wrong
- A. Sharding splits data across machines; it does not add CPU to one server.
- B. Read replicas copy data for reads; they do not upgrade the existing server.
- C. Horizontal scaling adds more machines, not more power to one.
Tip: Up or vertical means a bigger single machine; out or horizontal means more machines.
Question 5Medium
Which statement about stateless services is correct?
- Stateless means the service keeps no logs
- State still exists but lives in external stores like databases
- Stateless services cannot use a database
- Stateless services need sticky sessions so that each user always returns to the same server
Answer: B. State still exists but lives in external stores like databases
Explanation
'Stateless' means no request-specific state lives in the server process between requests; durable state moves to shared stores.
Step-by-step solution
- A stateless server keeps no per-user state between requests.
- State is stored elsewhere (database, cache).
- So any server can handle any request.
Why the other options are wrong
- A. Logs are unrelated to statelessness.
- C. Stateless services commonly use databases.
- D. Sticky sessions are needed for stateful servers.
Question 6Medium
Why is connection pooling important when many app servers talk to one database?
- Pools let each query use several CPU cores in parallel on the database server, speeding up joins
- Pools encrypt data in transit
- Pools remove the need for indexes
- Opening connections is costly and databases cap concurrent connections
Answer: D. Opening connections is costly and databases cap concurrent connections
Explanation
Reusing a bounded set of connections avoids handshake costs and prevents app servers from exhausting the database's connection limit.
Step-by-step solution
- Each new database connection has a setup cost.
- A database also limits how many connections it accepts at once.
- A bounded pool reuses a fixed set of connections, avoiding repeated setup and the limit.
- So the key reason is that opening connections is costly and databases cap them (option D).
Why the other options are wrong
- A. A pool does not make one query run on several cores; it reuses connections.
- B. Encryption in transit is a separate concern, not what a connection pool does.
- C. A connection pool does not replace indexes; indexes are what speed up queries.
Tip: Use a bounded connection pool so many app servers do not exhaust the database's connection limit.
Question 7Medium
An autoscaling group adds servers when average CPU exceeds 70%. What is the main purpose of a cool-down period?
- To avoid flapping while new capacity takes effect
- To warm the cache before startup
- To slow down incoming traffic during scaling
- To shut down servers during off-peak hours and reduce the monthly compute bill
Answer: A. To avoid flapping while new capacity takes effect
Explanation
New instances need time to boot and absorb load; a cool-down stops the scaler from repeatedly adding or removing capacity based on stale metrics.
Step-by-step solution
- New servers take time to boot and start taking load.
- While they start, the CPU metric can stay high, so the scaler may add more servers.
- A cool-down waits before the next scaling action.
- So its main purpose is to avoid flapping while new capacity takes effect (option A).
Why the other options are wrong
- B. Warming the cache is unrelated to the cool-down period.
- C. A cool-down does not slow incoming traffic; it limits scaling actions.
- D. Scaling down off-peak is a scheduling choice, not the purpose of a cool-down.
Tip: A cool-down stops scaling actions from repeating on stale metrics.
Question 8Medium
A system handles 10x traffic by running 10x as many identical servers with no change in per-request latency. This shows:
- Linear scalability
- Vertical scalability
- High consistency
- Low availability
Answer: A. Linear scalability
Explanation
Linear scalability means capacity grows in proportion to resources added.
Step-by-step solution
- Ten times the servers handle ten times the traffic.
- Per-request latency stays the same, so capacity grows in step with resources.
- Capacity that grows in direct proportion to added resources is linear scalability.
- So the answer is linear scalability (option A).
Why the other options are wrong
- B. Vertical scalability means making one machine bigger, not adding identical servers.
- C. Consistency is about data agreement, and the scenario says nothing about it.
- D. The scenario describes growing capacity, not lower availability.
Tip: Linear scalability means doubling resources doubles capacity with no added per-request cost.
Question 9Hard
A service's throughput stops increasing after 8 app servers even though their CPU is low. What is the most likely cause?
- The load balancer cannot route to more than 8 servers in one target group
- The app servers need more CPU cores
- A shared bottleneck downstream, such as the database or a lock
- Horizontal scaling only works up to 8 nodes
Answer: C. A shared bottleneck downstream, such as the database or a lock
Explanation
When adding workers stops helping and they are idle, the limit is a shared resource downstream; scale or relieve that component instead.
Step-by-step solution
- Throughput stops rising after 8 servers.
- The servers have low CPU, so they are mostly waiting.
- Idle servers point to a limit elsewhere, not in the servers themselves.
- So the likely cause is a shared bottleneck, such as the database or a lock (option C).
Why the other options are wrong
- A. Idle CPU shows the balancer is not the limit; the cap sits downstream.
- B. Low CPU means the cores are not busy, so more cores would not help.
- D. Horizontal scaling has no fixed 8-node limit; the cap comes from a shared resource.
Tip: If adding workers does not help and they are idle, look for a shared resource downstream.
Question 10Hard
According to Amdahl's law, if 10% of a job is strictly serial, what is the maximum speedup from adding unlimited parallel workers?
- 90x
- Unlimited
- 100x
- 10x
Answer: D. 10x
Explanation
Speedup is bounded by 1 / serial fraction = 1 / 0.1 = 10, no matter how many workers you add.
Step-by-step solution
- Amdahl: speedup = 1/(s + (1-s)/N).
- With s = 0.1 and N -> infinity: 1/0.1.
- Max speedup = 10x.
Why the other options are wrong
- A. 90x confuses the parallel fraction with the speedup.
- B. Serial work always caps speedup.
- C. 100x would need 1% serial.
Tip: Max speedup = 1 / serial fraction.
Practise all 20 questions free
The full question bank with timed practice, progress tracking and Vidya, your AI tutor. Free, no ads.
Open this topic in the app →