OpenTelemetry metrics
- The nevisAuth OpenTelemetry metrics are registered as Gauges.
- Metrics can be accessed via exporters.
- For configuration example see the manual configuration examples in the configuration guide.
- The metric names on this page are the names nevisAuth emits. How they appear in your monitoring backend depends on the exporter. See Metric names per exporter.
nevisAuth metrics overview
nevisAuth registers the following metrics with the meter (instrumentation scope) ch.nevis.auth-<version>, where <version> is the nevisAuth version.
| Emitted name | Prometheus name | Attributes |
|---|---|---|
nevisauth.authstate.classes | nevisauth_authstate_classes | type, classes |
nevisauth.heap | nevisauth_heap | type, stat |
nevisauth.request-threads | nevisauth_request_threads | type, stat |
nevisauth.requests | nevisauth_requests | type, stat |
nevisauth.httpclient-pool | nevisauth_httpclient_pool | type, name, stat |
Metric names per exporter
nevisAuth emits the metric names with dots and hyphens, for example nevisauth.request-threads. The exporter configured with otel.metrics.exporter determines how the names appear in the monitoring backend:
- OpenTelemetry Protocol (OTLP) exporter (
otlp) and logging exporters: the emitted names are kept unchanged. Backends that receive metrics through OTLP, for example an OpenTelemetry Collector or Datadog, show the emitted names such asnevisauth.requests. - Prometheus exporter (
prometheus): Prometheus metric names do not allow dots or hyphens, so the exporter replaces them with underscores. For example,nevisauth.request-threadsbecomesnevisauth_request_threads. The exporter also adds the instrumentation scope as theotel_scope_namelabel.
Example of a metric exposed by the Prometheus exporter:
nevisauth_heap{otel_scope_name="ch.nevis.auth-<version>",stat="used",type="nevis-operational-analytics"} 2.62144E8
If you forward Prometheus metrics to another backend, the backend shows the Prometheus names. Use the names that match your exporter when you create queries, dashboards, and alerts.
Product metrics
Metrics with type of nevis-product-analytics shows information on how the component is used from business point of view.
nevisauth.authstate.classes- list of auth state classes configured for this nevisAuth instance. The value of the metric is always1. Theclassesattribute contains the sorted list of fully qualified auth state class names, for example[ch.nevis.esauth.auth.states.standard.TransformAttributes, ch.nevis.esauth.auth.states.standard.UseridPasswordAuthenticateState].
Operational metrics
Metrics with type of nevis-operational-analytics shows information on runtime statistics.
-
nevisauth.heapshows heap memory usage. Thestatattribute identifying the detailed metric can have the following values:max- Maximum memory which can be occupied by the JVM.total- Memory currently allocated by the JVM.used- Memory allocated by the JVM which is currently in use.free- Memory allocated by the JVM which is currently not used.
-
nevisauth.request-threadsshows the web container thread pool processing incoming requests. Note that the web container itself uses a few threads (less than 10) internally. Thestatattribute identifying the detailed metric can have the following values:current- Number of currently managed threads.max- Maximum allowed threads (lazy init, only created on demand).idle- From the currently managed threads how many is waiting for a task.busy- From the currently managed threads how many is actively working on request processing / container internal tasks.
-
nevisauth.requestsshows the web container request statistics. Thestatattribute identifying the detailed metric can have the following values:active- Number active concurrent requests.failures- Number of failed request since start.responses1xx- Number of HTTP 1xx request responses since start.responses2xx- Number of HTTP 2xx request responses since start.responses3xx- Number of HTTP 3xx request responses since start.responses4xx- Number of HTTP 4xx request responses since start.responses5xx- Number of HTTP 5xx request responses since start.responseTimeMean- Mean response time since start.responseTimeMax- Max response time since start.
-
nevisauth.httpclient-poolshows the utilization of HttpClient connection pools (it does not include SOAP connections made by theSecurityTokenServiceClient,MobileSignatureStateandnevisIdmauth states). The metric has anameattribute which typically contains the class of the auth state, the name in the configuration and some postfix. Thestatattribute identifying the detailed metric can have the following values:max- Maximum number of connections allowed in the pool overall (lazy initialization, only created on demand).maxPerRoute- Maximum number of connections allowed per request target host (lazy initialization, only created on demand).busy- Number of connections actively used to send requests.idle- Number of connections in the pool which not used.queued- Number of requests waiting for a connection to be ready in the pool.
Standard OpenTelemetry Java agent metrics
The OpenTelemetry Java agent bundled with nevisAuth can also emit standard metrics that are not specific to nevisAuth, for example JVM runtime metrics (jvm.*) and HTTP server metrics (http.server.*). These metrics follow the OpenTelemetry semantic conventions. The exporters convert their names with the same rules as the nevisAuth metrics. The Prometheus exporter can additionally append a unit suffix, for example http.server.request.duration becomes http_server_request_duration_seconds.