reblocks-prometheus - This is an addon for Reblocks Common Lisp framework which allows to gather metrics in Prometheus format.

REBLOCKS-PROMETHEUS ASDF System Details

This is an addon for Reblocks Common Lisp framework which allows to gather metrics in Prometheus format.

Installation

You can install this library from Quicklisp, but you want to receive updates quickly, then install it from Ultralisp.org:

(ql-dist:install-dist "http://dist.ultralisp.org/"
                      :prompt nil)
(ql:quickload :reblocks-prometheus)

Usage

Inherit your Reblocks application from prometheus-app-mixin class:

(defapp app
  :subclasses (reblocks-prometheus:prometheus-app-mixin)
  :prefix "/")

A new route /metrics will be added to serve metrics in Prometheus format.

API

A mixin which gathers some stats to report in Prometheus format.

Also, this mixin adds a /metrics slot to the app.

Use stats-registry to access the registry slot.