Mocks a system under test (SUT) to be used for load testing.
The mock will respond to each request with a status code 200 and log the request except for the cases listed below. Furthermore, it maintains a user session. All requests are written to files and can be retrieved via a REST endpoint.
Requests to the following endpoints return special responses and will not be logged:
sessionId - - [timestamp] "method path protocol" responseCode -The SUT Mock buffers each request and writes it to a file asynchronously. In case the internal buffer is full, the requests will be dropped and the Mock will respond with a 500 status. The number of threads removing requests from the buffer and writing them to files can be configured.
The best option to run the SUT Mock is to use the Docker container available:
docker run -d --rm --name sutmock -p 8080:80 continuityproject/sutmock
Alternatively, it can be built locally (see below) and started directly:
java -jar build/libs/sutmock.jar --port=8080
Both options to run the SUT Mock accept the following parameters.
Simply append them to the run commands shown above, e.g., ... --sutmock.writers=4
80.1024.logs/log_.The SUT Mock is build using Gradle with the following command:
./gradlew build
Build a Docker container locally using the following command:
docker build . -t continuityproject/sutmock
Content type
Image
Digest
Size
86.6 MB
Last updated
over 6 years ago
docker pull continuityproject/sutmock