Read a results dashboard
Medium70 pts~25 min
- Metrics
- Dashboards
Practice app · Checkout Service
A load-testable checkout service with realistic latency that degrades under concurrency, plus a live metrics view.
Your starter code already declares BASE_URL — call the API relative to it.
Objective
Generate load, then read the service's live metrics and assert on them from the script.
Your task
- 1Set options { vus: 5, iterations: 40 }.
- 2GET BASE_URL + "/perf/checkout" and check 200.
- 3Every 4th iteration of a VU (__ITER % 4 === 3) also GET BASE_URL + "/perf/metrics".
- 4check rps > 0, p95 > 0, errorRate < 0.05 and recent is non-empty.
Acceptance criteria
- GET /perf/checkout returns 200
- GET /perf/metrics returns 200
- ≥ 40 requests are sent
- At least 40 check() calls pass
k6 load testing · Performance Testing · Scaling & analysis