-
-
Notifications
You must be signed in to change notification settings - Fork 278
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add pyinstrument for performance benchmarking #6292
Comments
This should only be available during local development & not in any of the public facing instances 👍 |
But could go to the staging server temporarily if necessary for performance issue investigations |
My plan was to have this in a "perf" branch, not develop or main. |
I won't be deployed anywhere in that case 👍 However, if you merge the branch then we want to make sure pyinstrument is not included in production by using Python dependency groups and having a multistage dockerfile that uses different groups for each build target |
I don't plan to make any code changes other than whatever it takes to get some performance statistics. It shouldn't effect the docker image at all, I used pdm to install the module manually. |
We need to have the pyinstrument integration in two places:
so that we do the performance comparison between both the setups |
Here are the references what I prefer for setting up pyinstrument in flask and fastapi |
@kaditya97 - here is some previous work on profiling https://github.com/hotosm/tasking-manager/tree/develop/scripts/profiler |
To enable performance testing, support for pyinstrument should be added to the backend. This can be then run optionally via an additional parameter to the REST API call. This also needs way to export the results outside of docker.
The text was updated successfully, but these errors were encountered: