Observability
Logging
Edge Worker logs various events to the stdin. You can change the log level
by setting EDGE_WORKER_LOG_LEVEL
environment variable:
Available log levels are:
debug
info
error
- (more will come)
By default, Edge Worker’s log level is info
.
Heartbeats
Edge Worker sends heartbeats every 5 seconds and updates last_heartbeat_at
column in edge_worker.workers
table.
List of active workers
In order to get a list of active workers, we need to fetch those that have pinged in the last 6 seconds (+1s to account for delays):
Helper SQL Views
Alterntively, use following SQL views to simplify those queries: