digitaldemocratic/stress-tests
Evilham 567bfd770d
[stress-tests] Documentation + necessary files to perform testing
By executing tests in this normalised fashion it is easier to compare
results between different instances or different patch levels.

Roughly speaking there are two kinds of tests:

- VM tests: which summarise general performance of the instance,
  without taking DD into account
- DD tests: which simulates many logins and interactions with DD,
  while recording the session as a user would pereceive it from a
  browser

By using these we should be able to consistently compare and improve
performance.

The original dd-stress-test.tpl.jmx tests file was prepared by
Teradisk  with hardcoded instance, threadcount and duration values.

Testing should now be performed with `vm-test.sh` and `dd-test.sh`
respectively, and the template file should stay generic.
2023-02-28 08:25:42 +01:00
..
.gitignore [stress-tests] Documentation + necessary files to perform testing 2023-02-28 08:25:42 +01:00
Pipfile [stress-tests] Documentation + necessary files to perform testing 2023-02-28 08:25:42 +01:00
Pipfile.lock [stress-tests] Documentation + necessary files to perform testing 2023-02-28 08:25:42 +01:00
README.md [stress-tests] Documentation + necessary files to perform testing 2023-02-28 08:25:42 +01:00
dd-stress-test.tpl.jmx [stress-tests] Documentation + necessary files to perform testing 2023-02-28 08:25:42 +01:00
dd-test-selenium.py [stress-tests] Documentation + necessary files to perform testing 2023-02-28 08:25:42 +01:00
dd-test.sh [stress-tests] Documentation + necessary files to perform testing 2023-02-28 08:25:42 +01:00
requirements.txt [stress-tests] Documentation + necessary files to perform testing 2023-02-28 08:25:42 +01:00
vm-test.sh [stress-tests] Documentation + necessary files to perform testing 2023-02-28 08:25:42 +01:00

README.md

Stress tests

By executing tests in this normalised fashion it is easier to compare results between different instances or different patch levels.

This documents normalised stress-testing and references files under stress-tests.

VM tests

  • vm-test.sh: generate a text file to compare CPU and other factors across VM types, providers or instances which may affect DD performance.

We can compare the resulting lgos just with, e.g. vim -d.

DD tests

Currently these tests perform logins and interact with Nextcloud, but it would be interesting to expand them to interact with other services.

Directory contents

This directory contains following files:

  • dd-stress-test.tpl.jmx: template to generate JMeter tests to execute
  • dd-tests.sh: helper script that generates the actual test plan files and executes them. See ./dd-tests.sh --help
  • dd-test-selenium.sh: this gives us an idea of how a user would perceive DD to be behaving while under load. Called by ./dd-tests.sh by default.

Results

Results will be saved in a results directory, where each subdirectory corresponds to a stress test executed with dd-test.sh.

The naming scheme for those subdirectories is: DOMAIN_THREADCOUNT_DURATION Where THREADCOUNT and DURATION are the corresponding JMeter parameters.

Each results directory contains:

  • log: the JMeter log
  • results: the JMeter results file
  • html/index.html: the interactive graphs for the data as produced by JMeter
  • selenium/session.html: the session report as would be perceived by a user. Note this requires Python3 and selenium and can be disabled by setting the environment variable: USE_SELENIUM=NO.