Skip to content

Metrics

Sablier can expose a Prometheus-compatible /metrics endpoint. Enable it on the server:

# compose.yml
services:
  sablier:
    image: sablierapp/sablier:next
    command:
      - start
      - --provider.name=docker
      - --server.metrics.enabled=true
    ports:
      - "10000:10000"
    volumes:
      - /var/run/docker.sock:/var/run/docker.sock

When server.metrics.enabled is true, Sablier registers a GET <base-path>/metrics route on the same HTTP server that handles /health and /api/... (see the CLI reference). The route returns the Prometheus text exposition format and is served by promhttp. When set to false (the default), the route is not registered and any request to that path returns 404.

Exposed metrics

NameTypeLabelsDescription
sablier_group_active_instancesgaugegroupNumber of instances in the group with an active session.
sablier_group_lockedgaugegroupWhether the group has at least one instance with an active session (1) or not (0).
sablier_instance_active_seconds_totalcounterinstanceCumulative seconds each instance has spent in the Ready state. Incremented each time an instance’s session expires. Use increase() or rate() over a time window to compute the active fraction.
sablier_instance_ready_duration_secondshistograminstanceEnd-to-end wall time from first not-ready observation to ready (seconds).
sablier_instance_start_duration_secondshistograminstanceDuration of provider.InstanceStart calls (seconds), only successful starts.
sablier_instance_start_failures_totalcounterinstanceTotal number of provider InstanceStart failures, by instance.
sablier_instance_stops_totalcounterinstance, reasonTotal number of instance stops, by instance and reason.
sablier_session_expires_at_timestamp_secondsgaugegroup, instanceUnix timestamp (seconds) at which the instance’s session expires and the instance is stopped. One series per active session. The value tracks the latest access and is pushed back on every session renewal. Derive the remaining time in Grafana with the expression: value - time().
sablier_session_requests_totalcounterstrategy, targetTotal number of session requests received, by strategy and target.
Go runtime + process collectors(default)(default)Standard go_* and process_* metrics from the Prometheus Go client.

Security note

The endpoint exposes process internals, group and instance names, and counters. It is intended for trusted observability stacks. Restrict at the reverse proxy when Sablier is fronted on an untrusted network.