Automattic / mShots

Website Thumbnail/Snapshot Service
GNU General Public License v2.0
100 stars 21 forks source link

Add performance testing script to mshots #61

Closed roo2 closed 2 years ago

roo2 commented 2 years ago

We have plans which will put a significantly increased load on mshots, I'm adding these scripts to test whether mshots is up to the task and also to have a way to test future performance improvements.

I went with a python script using the locust framework because we've used python for one off things around wpcom and I think the framework is quite nice.

p2 link discussing this: pbxlJb-1sw-p2

Test instructions

Follow instructions in scripts/performance-testing/README.md and ensure that they capture everything that needs to be done on your machine.

taipeicoder commented 2 years ago

Maybe I'm missing something, but it's hard to see if locust is running the test as intended. Could you upload screenshots/recordings of what a successfully test looks like?

roo2 commented 2 years ago

you have to run locust and then open a browser at http://localhost:8089/ locust docs

I added some screenshots to pbxlJb-1sw-p2#how-many-new-preview-requests-per-second-can-mshots-handle you have to go to the "Charts" tab e.g.

Screen Shot 2022-04-01 at 4 53 47 pm