We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 5ee7baf + 7988f55 commit e08b477Copy full SHA for e08b477
python/apsis/apsis.py
@@ -610,15 +610,18 @@ async def __check_async(self):
610
Monitors the async event loop.
611
"""
612
while True:
613
+ num_tasks = len(asyncio.all_tasks())
614
+
615
# Wake up on the next round 10 seconds.
616
t = now()
617
next_second = t.EPOCH + math.ceil((t - t.EPOCH + 0.01) / 10) * 10
618
await asyncio.sleep(next_second - t)
-
619
# See how late we are.
620
latency = now() - next_second
621
622
self.__check_async_stats = {
- "latency": latency,
623
+ "latency" : latency,
624
+ "num_tasks" : num_tasks,
625
}
626
627
0 commit comments