Extended metadata
SmallRye Metrics provides its own class for metadata, io.smallrye.metrics.ExtendedMetadata
,
which contains a few additional fields. Usage of this is not mandatory, unless you need to make
use of these extra fields.
The extra fields are:
Field |
Meaning |
mbean |
The expression designating the JMX MBean property from which the value of this metric will be retrieved. This is meant to be used only for base and vendor metrics, see Base and vendor metrics for more information |
multi |
Is set to |
prependsScopeToOpenMetricsName |
Optional configuration to prepend the microprofile scope to the metric name when it is exported
to the OpenMetrics format. By default, the option is empty() and will not be taken into account.
If true, the scope is prepended to the metric name when the OpenMetrics
name is generated (e.g. |
skipsScopeInOpenMetricsExportCompletely |
If |
openMetricsKeyOverride |
If set, this property overrides the OpenMetrics key under which the metric will be presented in an OpenMetrics export. Normal export rules defined by the MicroProfile Metrics specification are therefore ignored. Only applies to non-compound metrics, that is counters and gauges. |
The ExtendedMetadata
class also comes with a fluent builder - io.smallrye.metrics.ExtendedMetadataBuilder
.