-
-
Notifications
You must be signed in to change notification settings - Fork 9k
Extract the number of in-flight requests? #1005
Copy link
Copy link
Closed
Labels
Description
First check
- I used the GitHub search to find a similar issue and didn't find it.
- I searched the FastAPI documentation, with the integrated search.
- I already searched in Google "How to X in FastAPI" and didn't find any information.
Description
Is there a way to extract the total number of in-flight requests? I.e. the number of requests that have been received and not yet responded to (not including background tasks).
If so, how can it be consumed? E.g. can I create an endpoint like /requests which responds with the number? Or perhaps a cron task which can query the number so I could send it to a stats database?
Motivation
I'd like to trigger autoscaling events based on the number of in-flight requests.
Reactions are currently unavailable