Skip to content

Commit f45f02a

Browse files
committed
Add some comments about various kinds of load testing.
1 parent 60f8ff1 commit f45f02a

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

backend/load-test.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,12 @@
11
import http from 'k6/http';
22
import { check, sleep } from 'k6';
33

4+
// Possible test types include smoke, stress, spike, soak and load.
5+
// Smoke: verify system can habdle a minimal load w/o issues.
6+
// Stress: determine breaking point by increading number of VUs until the API starts returning errors or response times degrade significantly.
7+
// Spike: test how the system handles sudden spikes in load. A sudden increase in the number of VUs to simulate a traffic spike, followed by a return to normal load.
8+
// Soak (endurance): test the system's stability and performance over an extended period. Running a constant load for several hours or days to identify memory leaks or performance degradation over time.
9+
// Load: test the system under expected peak load conditions. Running a constant load for a period of time to verify that the system can handle the expected number of users.
410
export let options = {
511
stages: [
612
{ duration: '1m', target: 10 }, // Ramp-up to 10 users over 1 minute

0 commit comments

Comments
 (0)