-
Type:
Task
-
Resolution: Done
-
Priority:
Unknown
-
None
-
Affects Version/s: None
-
Component/s: None
-
None
-
Python Drivers
-
None
-
None
-
None
-
None
-
None
-
None
We need to add instructions and perhaps a justfile target for profiling memory usage in pymongo, using py-spy.
Rough notes from working on HELP-72348:
- Create an ubuntu spawn host
- Use the pymongo scripts to set up the host
- Install py-spy: https://github.com/benfred/py-spy
- Create a test script that does a setup and then loops over the code to profile, to improve the sampling
- Run the script using something like: py-spy record -o profile.svg --native -r 2000 - python test.py
- Use scp to get the svg file back from the host