danog\BetterPrometheus\BetterHistogram
Author: Daniil Gentili [email protected]
A better prometheus histogram.
danog\BetterPrometheus\BetterHistogram::TYPE
:$storageAdapter
: Prometheus\Storage\Adapter
Storage adapter$namespace
: string
Metric namespace$name
: string
Metric name$help
: string
Info about the metric$labels
: array<string, string>
Default labels, i.e. [‘instance’ => ‘instance_1’]__construct(\Prometheus\Storage\Adapter $adapter, string $namespace, string $name, string $help, array<string, string> $labels = [], (non-empty-list<float>|null) $buckets = NULL)
addLabels(array $labels): static
observe((double|int) $value, array<string, string> $labels = []): void
__construct(\Prometheus\Storage\Adapter $adapter, string $namespace, string $name, string $help, array<string, string> $labels = [], (non-empty-list<float>|null) $buckets = NULL)
Parameters:
$adapter
: \Prometheus\Storage\Adapter
$namespace
: string
$name
: string
$help
: string
$labels
: array<string, string>
$buckets
: (non-empty-list<float>|null)
\Prometheus\Storage\Adapter
non-empty-list
addLabels(array $labels): static
Parameters:
$labels
: array
observe((double|int) $value, array<string, string> $labels = []): void
Parameters:
$value
: (double|int)
e.g. 123$labels
: array<string, string>
e.g. [‘status’ => ‘201’, ‘opcode’ => ‘SOME_OP’]double
Generated by danog/phpdoc