Class MetricSchema
The published schema of the metrics the server records about itself: each one's name, kind, unit, attributes and lifecycle, the runtimes that measure it, and the Micrometer meter a Spring Boot dashboard reads for the same figure. The names, units and attributes listed here are stable; a dashboard or alert written against them keeps working across releases and across the JVM and the packaged native server.
A figure a runtime cannot measure is never reported as zero there. Its
instrument is not registered, or -- for a pool gauge on a server with no
database -- reports no point, so it is absent from every view, and
describe() lists it as unavailable with the reason. The Micrometer meters
neither runtime has an equivalent for are listed by unmeasured(String, String).
GET /manage/schema serves describe() for the running server.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classOne instrument of the schema. -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringMeasured by every runtime.static final StringA value that only grows while the process runs, and starts again from zero when it restarts.static final StringMeasured when the server has a database pool.static final StringA value read when the metrics are collected, which may rise or fall.static final StringMeasured on the JVM only; a packaged native server has no equivalent. -
Method Summary
Modifier and TypeMethodDescriptionstatic Mapdescribe()The schema as the management endpoint serves it: the runtime, every instrument with whether this process reports it and, when it does not, why, and the Micrometer meters nothing here reports.static Listentries()Every instrument of the schema, in a fixed order.static MetricSchema.EntryThe schema's instrument of this name, or null.static booleanisAvailable(MetricSchema.Entry entry) Whether this process reports the instrument now: it is registered and, for a gauge without attributes, has its point to report.static Stringruntime()The runtime this process is:jvmornative.static ListThe Micrometer meters a Spring Boot dashboard may read that no runtime here reports, each as{meter, reason}.
-
Field Details
-
ALWAYS
-
DATABASE
-
JVM
Measured on the JVM only; a packaged native server has no equivalent.- See Also:
-
CUMULATIVE
A value that only grows while the process runs, and starts again from zero when it restarts. Rate and increase functions apply.- See Also:
-
INSTANT
A value read when the metrics are collected, which may rise or fall.- See Also:
-
-
Method Details
-
entries
Every instrument of the schema, in a fixed order. -
get
The schema's instrument of this name, or null. -
unmeasured
The Micrometer meters a Spring Boot dashboard may read that no runtime here reports, each as{meter, reason}. -
runtime
The runtime this process is:jvmornative. -
isAvailable
Whether this process reports the instrument now: it is registered and, for a gauge without attributes, has its point to report. A gauge with attributes has a point per value -- an executor, say -- and none while there is no such value yet, which is a measured "none". False for every instrument before a server has started. -
describe
The schema as the management endpoint serves it: the runtime, every instrument with whether this process reports it and, when it does not, why, and the Micrometer meters nothing here reports.
-