@oz
2026-11-10 01:09 UTC · 8 votes
I would put rate limits at the edge and keep app middleware as a second line.
Hit this after a routine bump.
Symptom: Validate enums in query params without 500s
TimeoutError / pool exhausted / upstream reset
(versions in next reply if needed)
Env: Python 3.12, FastAPI recent, uvicorn workers≥2.
What should I check first?
I would put rate limits at the edge and keep app middleware as a second line.
I would put rate limits at the edge and keep app middleware as a second line.
marking solved after we pinned the dependency and re-smoked /docs.
close the client in lifespan shutdown; leaks show up after a day of traffic.
paste engine kwargs and max_connections. worker×pool is the usual culprit.
minimal repro with ASGITransport would help more than screenshots.
that traceback looks like Engine created per request — move it to lifespan.