Contact Us
Contact Us
Software Testing

Performance Testing Before Launch: Avoiding the Peak-Traffic Crash

Why apps fall over at peak traffic, a one-page load test plan for a launch or sales event, and how k6 and JMeter compare.

JRC Software Team
7 min read
Performance Testing Before Launch: Avoiding the Peak-Traffic Crash

Black Friday falls on 27 November in 2026, Cyber Monday on 30 November, and Boxing Day on 26 December. For a lot of Australian retailers those dates are the busiest hours of the year, and the worst time to find out checkout can't handle the traffic. The pattern is familiar: the email goes out, the push notification lands, and within minutes the site crawls, checkout times out and the team spends the peak restarting servers.

Most of these failures are predictable. Performance testing before a launch or planned peak finds the weak point while there's still time to fix it. Below are the failure patterns we see most, a load test plan that fits on one page, and how to choose between k6 and JMeter.

Functional tests can't see a traffic spike

A functional test tells you a feature works for one user. It says nothing about thousands of people hitting the same endpoint in the same minute. And peaks aren't smooth: traffic jumps sharply after an email send, a social post or a sale start time.

Load testing is also easier as a habit than as an event. DORA's continuous integration guidance says developers should get feedback from acceptance and performance tests daily. A small load test that runs regularly catches regressions long before the big pre-launch run.

Seven ways apps fall over at peak

These are anonymised patterns, not specific incidents, but each one comes up again and again:

  • The database runs out of connections first. App servers scale out, each opens its own pool, and the database hits its connection limit while CPU still looks fine. The symptom is "too many connections" or pool timeout errors in the app logs. A connection pooler such as PgBouncer in front of Postgres, or smaller per-instance pools, usually fixes it.
  • A third-party API sets the ceiling. Payment, inventory, address lookup and shipping providers have rate limits. Your app is fine and the partner starts returning HTTP 429s.
  • Autoscaling reacts too slowly. Rules tuned for gradual growth can't add capacity fast enough for a spike, and new instances or functions take time to warm up. Scale out ahead of a known start time instead of waiting for CPU to climb.
  • The cache stampede. A popular cache entry expires under load and hundreds of requests hit the database at once to rebuild it.
  • Only the home page was tested. Cached pages hold up, while search, cart and checkout, which are uncached and write to the database, fall over.
  • The load generator was the bottleneck. A test run from one laptop, or with heavy reporting switched on, measures the test tool rather than your system.
  • Slow memory leaks. Everything passes a 15-minute test, then degrades after several hours of steady traffic.

Six load test types and what each answers

Grafana's k6 documentation describes a useful set of load test types. The names apply whatever tool you use.

Test typeLoadDurationWhat it answers
SmokeMinimalSeconds to minutesDoes the script work, and does the system respond under light load?
Average loadNormal production levelAbout 5 to 60 minutesDoes the system meet targets on a normal busy day?
StressAbove averageAbout 5 to 60 minutesHow does it behave at and beyond expected peak?
SpikeVery high, suddenA few minutesDoes it survive a sharp burst, and does it recover?
SoakAverageHoursDo leaks or slow degradation show up over time?
BreakpointRising until failureAs long as neededWhere's the actual capacity limit?

The docs suggest starting with a smoke test, then average load, and choosing the rest by risk. For a sales event, spike and stress matter most. For a long campaign, add a soak test. Breakpoint tests are for running only a few times.

A one-page performance testing plan

This is our starting point. It fits on a page and runs in a few weeks.

  1. Set the target. Agree the expected peak from analytics and the marketing plan: concurrent users, requests per second and orders per minute. Add a headroom margin the business signs off.
  2. Pick the critical journeys. Usually browse, search, log in, add to cart, checkout and the key mobile API calls. Weight them to match real traffic.
  3. Use a production-like environment. Same instance sizes, database size and configuration as production, with realistic data. Tell third-party providers before you test and use their sandboxes where you can.
  4. Write down pass or fail thresholds. For example, a 95th percentile response time and a maximum error rate per journey. The k6 thresholds documentation shows http_req_duration: ['p(95)<200'] and http_req_failed: ['rate<0.01'], meaning 95% of requests under 200 ms and errors under 1%. Pick values that suit your product and users.
  5. Run in order. Smoke, then average load, then stress and spike, then soak if the event runs for days.
  6. Watch the whole system. Database connections, queues, cache hit rates, third-party error rates and autoscaling events, not only response times.
  7. Fix, retest, freeze. Retest every fix at the same load, then freeze risky changes in the last few days before the event.
  8. Leave a small test in the pipeline. A short load test on every release stops performance regressions creeping back.

k6 vs JMeter: pick the one your team will maintain

Both are open source and both are capable. The choice is mostly about your team and your pipeline.

k6Apache JMeter
How tests are writtenCode, in JavaScript or TypeScript (k6 docs)Test plans built in a GUI, run from the command line
RuntimeIts own JavaScript runtime, not Node.jsA pure Java application
ProtocolsHTTP, with more added through extensions, plus a browser APIHTTP, REST, SOAP, JDBC, JMS, LDAP, FTP, mail, TCP and more
CI fitA failed threshold gives a non-zero exit codeCLI mode runs headless in pipelines
Browser behaviourBrowser module for front-end timingsNot a browser: doesn't run page JavaScript or render HTML

Apache JMeter suits teams with existing JMeter skills, a need for protocols like JDBC or JMS, or testers who prefer a visual test plan. Its best practices guide is clear that load tests should run in CLI mode (jmeter -n -t test.jmx -l results.jtl), with as few listeners as possible, CSV output, and several instances for big tests. Running a heavy test from the GUI is a classic cause of misleading results.

Grafana k6 suits developer-led teams who want tests in version control next to the code, reviewed like any other change and run in CI. Because a failed threshold fails the build, it fits neatly with a shift left testing approach. One gotcha: since k6 isn't Node.js, some npm packages won't work inside test scripts.

Either way, a simple test that runs every week beats a sophisticated one that runs once.

How JRC Software runs a pre-launch load test

Our quality engineering and automation team runs load tests as part of launch readiness. In week one we agree targets with your product and marketing leads, confirm the environment really is production-like, and script the critical journeys in k6 or JMeter. Then we run the plan above.

While the tests run we watch the whole stack, from database connections to third-party limits and autoscaling events, so the report names the actual bottleneck and the fix rather than a page of response-time charts. We leave a small load test in your pipeline so performance stays visible after launch. Where performance checks sit in a wider suite is covered in our test automation strategy guide.

And a hard no from us: don't load test production in the week of the sale.

If you've got a launch or a sales peak coming, request a load test and we'll find your breaking point before your customers do.

Frequently asked questions

What is the difference between performance testing and load testing?

Performance testing is the broad discipline of checking speed, stability and capacity. Load testing is one type of it, where you simulate a set number of users or requests and measure how the system responds. Stress, spike, soak and breakpoint tests are related types that push past normal load or run for longer.

How far before launch should we load test?

As soon as the critical journeys are stable, and with time for at least one fix and retest cycle. Bottlenecks like database limits or third-party rate limits can take weeks to resolve. A short load test running regularly in your pipeline means the pre-launch test confirms readiness instead of uncovering surprises at the last minute.

Should we use k6 or JMeter?

Choose k6 if your developers will own the tests and want them as code in version control and CI. Choose JMeter if your team already knows it, prefers a visual test plan or needs protocols such as JDBC or JMS. Both work well when run correctly, so pick the one your team will actually maintain.

Can we load test in production?

You can, but it's risky. Production tests use real infrastructure and can affect real customers, third-party quotas and data. Most teams test a production-like environment instead, then run small synthetic checks in production to confirm key journeys keep working. If you must load test production, pick a quiet window and tell your providers first.

Software Testing

Request a load test

Tell us where you're stuck and we'll come back with practical next steps.

Get in touch

Sources