TheRacetrack / racetrack

An opinionated framework for deploying, managing, and serving application workloads
https://theracetrack.github.io/racetrack/
Apache License 2.0
28 stars 5 forks source link

Upgrade FastAPI to solve memory leaks #442

Closed iszulcdeepsense closed 2 months ago

iszulcdeepsense commented 2 months ago

There might be a memory leak on Racetrack wrapper due to FastAPI. Some of the jumps in memory occured at the same time as errors.

There were other people complaining online about memory leaks after errors and pointed to FastAPI. FastAPI had a breaking change in version 0.110.0 (Racetrack uses 0.109.2), which could solve the issue: https://fastapi.tiangolo.com/release-notes/#01100

The documentation still says that one has to raise internal server errors properly to mitigate the memory leak.