Product analytics
Introduction
The product analytics report contains information about the usage of the nevis components, such as the number of patterns used in the nevisAdmin 4 projects, the used auth states in the running nevisAuth instances or the number of active users in nevisIDM.
The information is based on a group of metrics queried from a connected Prometheus instance.
Prerequisites
The generation of the report requires a Prometheus and an OpenTelemetry instance. For more information about the installation of these components see: Installation of Monitoring setup.
Change the Configuration
Helm
Extend the used values.yaml
with the following values:
nevisAdmin4:
otel:
enabled: true
url: "<otelUrl>"
productAnalytics:
enabled: true
prometheus:
url: "<prometheuslUrl>"
RPM
If not using nevisAppliance, download nevis-opentelemetry-javaagent-<version>.jar
from the Nevis portal and save it as /opt/agent/opentelemetry-javaagent.jar
Replace the placeholders and place the following otel.properties
file in /var/opt/nevisadmin4/conf
otel.service.name = nevisadmin4
otel.resource.attributes = service.version=8.2405,service.instance.id=nevisadmin4-<intance>
otel.exporter.otlp.protocol = http/protobuf
otel.exporter.otlp.traces.protocol = http/protobuf
otel.exporter.otlp.traces.endpoint = <tracesEndpoint>
otel.exporter.otlp.metrics.protocol = http/protobuf
otel.exporter.otlp.metrics.endpoint = <metricsEndpoint>
otel.exporter.otlp.metrics.temporality.preference = cumulative
otel.exporter.otlp.logs.protocol = http/protobuf
otel.exporter.otlp.logs.endpoint = <logsEndpoint>
Then extend the JAVA_OPTS
located in /var/opt/nevisadmin4/conf/env.conf
with
-javaagent:/opt/agent/opentelemetry-javaagent.jar -Dotel.javaagent.logging=application -Dotel.javaagent.configuration-file=/var/opt/nevisadmin4/conf/otel.properties -Dotel.instrumentation.jdbc.enabled=false
After that, configure the base url where the Prometheus instance is reachable in /var/opt/nevisadmin4/conf/nevisadmin4.yml
. Username and password is required in case basic authentication is enabled for the Prometheus instance.
nevisadmin:
product-analytics:
prometheus:
url: https://prometheus.example.dev/
password: <password>
username: <username>
Adjust nevisAdmin 4 inventory
To use the default product analytics configuration, add the otel collector endpoints to the nevisAdmin 4 inventory variables.
An example setup can be seen below:
vars:
__otel:
metricsEndpoint: https://otel-otel-collector.observability:4318/v1/metrics
logsEndpoint: https://otel-otel-collector.observability:4318/v1/logs
tracesEndpoint: https://otel-otel-collector.observability:4318/v1/traces
Usage
About the usage of the product analytics see: Product Analytics.