Vert.x and Metrics

Vert.x has the capacity to automatically collect metrics via Micrometer. The benefit of using Micrometer is that it is a vendor-neutral metrics facade, so metrics can be collected using Micrometer and made available for a variety of backends.

For specific details about Vert.x’s implementation of Micrometer, see the documentation.

For more generic details about Micrometer metrics - what’s available and how they’re set up - see the Micrometer documentation. This includes the supported monitoring systems.

Loading The Registry

The registry is automatically loaded automatically as a PrometheusBackendRegistry because only Prometheus options are passed in. The registry options are loaded in Launch.runVerticle().

Two JSON objects from the config.json can be set to refine the settings:

  • metrics for the main Vertx metrics options.
  • prometheusMetrics for Prometheus-specific options.