Skip to content

minh132/call_record

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Call Record API

Getting Started

Follơw these steps to set up and run the Call_record API:

1. Clone this repo

git clone https://github.com/minh132/call_record.git

2. Build dockercompose

Run the following command to build docker compose:

docker compose build

3. Run dockercompose

Run docker compose, execute command below and wait a few minutes to run testcase and start server:

docker compose up

4. TestAPI

Go to http://0.0.0.0:8888/docs to test API

Gunicorn with Uvicorn Workers

Gunicorn supports working as a process manager and allowing users to tell it which specific worker process class to use. Then Gunicorn would start one or more worker processes using that class. I use JMeter to test success rate when send many request with resource limit in docker-compose(2 core cpu and 2048m memory) . Result when use uvicorn, gunicorn and test with same config in JMeter, send 2500 request in 2 seconds and set timeout 2s:

Gunicorn

Uvicorn Uvicorn

Screenshot from 2024-01-04 20-58-52

The result shows that using Gunicorn help error rate reduce from 84% to 39%

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published