Module Quiz
Complete this quiz after finishing all concept and practice pages.
Current Module Questions
Question 1: USE vs RED
You are handed a new Postgres-backed microservice with zero monitoring. Name one metric you would put on a dashboard from the USE method and one from the RED method, and explain which question each answers.
Answer: USE: put "CPU saturation" (e.g., run queue length or %iowait) on the dashboard. It answers "is any resource becoming the bottleneck?" RED: put "request duration p99" on the dashboard. It answers "what latency are users experiencing?" USE finds the resource that will tip over; RED finds user-visible pain. You need both because saturated resources sometimes still hide behind acceptable percentiles (briefly), and rising percentiles sometimes come from downstream dependencies, not this service's resources.
Question 2: Percentile Reasoning I
Service X has a latency distribution of [20, 25, 30, 35, 40, 45, 50, 55, 60, 65] ms (sorted). Service Y has [20, 22, 25, 28, 30, 32, 38, 42, 50, 468] ms.
a. Compute the mean latency for each. Are they similar? b. Compute p50 and p99 for each (use the 10th sample as p99 for this approximation). c. If a user page fans out to 10 independent requests, which service will more often produce a slow page?
Answer:
a. Mean of X = 42.5 ms. Mean of Y = 75.5 ms. Close-ish, but Y is 77% higher.
b. X: p50 ≈ 42.5 ms, p99 ≈ 65 ms. Y: p50 ≈ 31 ms, p99 ≈ 468 ms.
c. Y will much more often produce a slow page. Tail-at-scale: with 10 parallel requests, the probability the slowest hits the p99 is roughly 1 − 0.99^10 ≈ 9.6%. For Y, a p99 hit means 468 ms rendered; for X it means 65 ms. Y's p50 is better but its tail dominates the user experience. This is why averages lie: Y's mean is higher only because of the tail, and the tail - not the mean - is what the user feels.
Question 3: Percentile Reasoning II
Your monitoring team wants to compute "cluster-wide p99" by taking the average of each instance's p99 and reporting that number. Is this valid? If not, what should they do instead?
Answer: No. Percentiles do not average. Each instance's p99 is a different quantile of a different distribution; averaging them produces a number that corresponds to no real quantile of anything. The correct approach is to preserve the raw-request latency distribution (histograms, with buckets) from every instance and compute the percentile from the combined histogram. Tools like Prometheus histogram_quantile or HdrHistogram's add-and-query do exactly this: sum the bucket counts across instances, then compute the quantile on the summed distribution. The rule: never take mean, median, max, or percentile of percentiles.
Question 4: Amdahl vs USL
A parallel data-processing job has 5% serial fraction (Amdahl's s). It also exhibits contention with USL parameters α = 0.05, β = 0. At N = 100 workers, which law predicts a higher throughput, and what is the practical takeaway?
Answer: Amdahl's law predicts speedup S(N) = 1 / (s + (1−s)/N) = 1 / (0.05 + 0.95/100) = 1 / 0.0595 ≈ 16.8x. USL with