Python web performance 101
dans Bloc-notesPar Alex Ptakhin − Salle Rosalind Franklin
Python web performance 101
Web engineers meet issues with performance with fast-growing or even maintaining existing products. It’s always unexpected and we have limited time for decisions. With our hero, we meet real-faced RAM, CPU and IO problems and learn troubleshooting approaches to monolithic and distributed systems.
We try different existing tools from Python and the cloud ecosystem including, but not limited to: cProfile, yappi, memory-profiler and tracing.
This talk will be more focused on backend parts and designed for intermediate-level web engineers, but all skill levels are welcome.
Notes personnelles
- …
- Temporary solution: update hardware to get time for debug
- tools
time.?perf
cProfile
/snakeziz
- /!\ mesurement change system behavior
py-spy
yappi
forasyncio
sys.getsizeof
tracemalloc
memory-profiler
: require code changesmemray
: looks promising- Tracing: OpenTelemetry
- Things to remember
- getting time by adding ressources worth it
- Monitor application errors
- Measuring something can change the behaviour of the system
- Tuning is good, and remember, pure Python is not about the performance