From a9a2797ed10f7382006d85df39dc26f42aa86454 Mon Sep 17 00:00:00 2001 From: Herbert Jordan Date: Fri, 8 Nov 2024 23:08:34 +0100 Subject: [PATCH] Add scenarios for load-testing Sonic (#282) --- scenarios/load_tests/slope.yml | 16 ++++++++++++++++ scenarios/load_tests/steps.yml | 34 ++++++++++++++++++++++++++++++++++ 2 files changed, 50 insertions(+) create mode 100644 scenarios/load_tests/slope.yml create mode 100644 scenarios/load_tests/steps.yml diff --git a/scenarios/load_tests/slope.yml b/scenarios/load_tests/slope.yml new file mode 100644 index 00000000..447ac901 --- /dev/null +++ b/scenarios/load_tests/slope.yml @@ -0,0 +1,16 @@ +# This scenario runs a 2-minute load test with a gradual increase in load. +name: Slope Load Test +duration: 120 + +# The number of static validators present from begin to end. +num_validators: 4 + +applications: + - name: load + type: uniswap + users: 100 + start: 20 + end: 110 + rate: + slope: + increment: 5 diff --git a/scenarios/load_tests/steps.yml b/scenarios/load_tests/steps.yml new file mode 100644 index 00000000..69a004ef --- /dev/null +++ b/scenarios/load_tests/steps.yml @@ -0,0 +1,34 @@ +# This scenario runs a 2-minute load test with three different +# phases of load - a moderate load, a low load, and a high load. +name: Stepped Load Test +duration: 120 + +# The number of static validators present from begin to end. +num_validators: 4 + +# Run three different applications consecutively producing different load +applications: + + - name: load-M + type: counter + users: 100 + start: 20 + end: 50 + rate: + constant: 20 + + - name: load-S + type: erc20 + users: 100 + start: 50 + end: 80 + rate: + constant: 1 + + - name: load-L + type: uniswap + users: 100 + start: 80 + end: 110 + rate: + constant: 100 \ No newline at end of file