The demo is aimed at getting started with load testing a microservice before taking it to production. We use FastAPI microservice (to predict weather) and Locust to load test the service (locally or on cloud). You can find detailed instructions in the Engineering MLOps book.
Major frameworks used to build the project:
These are instructions to install and get the services up and running.
- Clone the repo
git clone https://github.com/emmanuelraj7/loadtesting-microservices.git
- Install Locust.io
pip install locust
- Go to FastAPI_microservice folder and build the FastAPI service docker image
docker build -t fastapi .
- Run the FastAPI service docker container locally
docker run -d -p 80:80 fastapi
- Go to Load_testing folder and run locust.io service for load testing
Locust -f load_test-py
Distributed under the MIT License. See LICENSE
for more information.
Emmanuel Raj - Linkedin
Project Link: https://github.com/emmanuelraj7/loadtesting-microservices
Engineering MLOps (book): Amazon