Skip to content

Commit

Permalink
aggregate requests (#328)
Browse files Browse the repository at this point in the history
  • Loading branch information
aniketmaurya authored Oct 8, 2024
1 parent a6c1565 commit 6483da1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/litserve/server.py
Original file line number Diff line number Diff line change
Expand Up @@ -308,7 +308,7 @@ async def data_streamer(self, q: deque, data_available: asyncio.Event, send_stat
@property
def active_requests(self):
if self.track_requests and self.active_counters:
return self.active_counters[self.app.response_queue_id].value
return sum(counter.value for counter in self.active_counters)
warnings.warn(
"Active request counter is not enabled while using `on_request` callback hook. "
"Please set track_requests=True in the LitServer."
Expand Down

0 comments on commit 6483da1

Please sign in to comment.