alexhsamuel / apsis

General-purpose scheduler.
Other
2 stars 2 forks source link

liveness and stats endpoints #295

Closed alexhsamuel closed 11 months ago

alexhsamuel commented 11 months ago

To check liveness, with a 15 s timeout:

>>> from apsis.service.client import Client
>>> Client().alive(timeout=15)

To peek at the current latency:

>>> Client().stats()["async"]["latency"]

I see typically ~3 ms when Apsis is idle.