Load Testing Made Easy with Gatling
summary
Builds a small Scala 3 GraphQL service backed by Postgres and exercises it with Gatling simulations that ramp 0 → 20 users over 30s, hold constant 30s, then ramp down, generating random valid queries with ScalaCheck generators and sending them via Gatling. Initial test on ~500 companies and a few thousand employees fails with ~95% connection timeouts until missing foreign-key indexes are added; after indexing requests finish under 500ms. A second simulation fetching 5–10 companies shows ~10× lower throughput and several responses over 2–4s.
AI-written summary · about
chapters (10)
- 0:00Load testing with Gatling
- 1:12Test scenario and API setup
- 10:49Scala service for testing
- 12:13Gatling simulation phases
- 15:13Dynamic GraphQL queries with ScalaCheck
- 23:39First load test and results
- 25:26Fixing DB indexes for performance
- 27:17Second GraphQL query test
- 31:35Open vs closed workload models
- 33:28Summary
related talks
34mPerformance tests with Gatling
46mContinuous Performance: Load Testing with Gatling
50mPerformance testing with Gatling
12mWeb load testing with Gatling
21mGATLING DISTILLED
38mPerformance Testing sucks! How to get started testing RESTful APIs and GraphQL
36mAutomated Performance Testing of Postgres
21mCrunching Millions of Requests for Breakfast: A Tale of Performance Testing Prowess
