CollectorRegistry

ditto

Constructors

this
this(CollectionDg[] callbacks)

Constructor, that accepts an array of stat collection callbacks.

Members

Aliases

CollectionDg
alias CollectionDg = void delegate(Collector)

An alias for the type of delegates that are called for stat collection

Functions

addCollector
void addCollector(CollectionDg collector)

Appends a stat collector callback to the list of existing ones. May result in a re-allocation of the entire buffer storing the callbacks.

collect
cstring collect()

Collects stats by calling all delegates specified for stat collection, formats them using ocean.util.prometheus.collector.StatFormatter eventually, and finally returns the accumulated result. The specifications of the format can be found at https://prometheus.io/docs/instrumenting/exposition_formats/.

Meta