Vert.x Prometheus Metrics

Prometheus implementation of the Vert.x Metrics SPI

License

License

Categories

Categories

Metrics Application Testing & Monitoring Monitoring Prometheus
GroupId

GroupId

su.nlq
ArtifactId

ArtifactId

vertx-prometheus-metrics
Last Version

Last Version

3.6.2
Release Date

Release Date

Type

Type

jar
Description

Description

Vert.x Prometheus Metrics
Prometheus implementation of the Vert.x Metrics SPI
Project URL

Project URL

https://github.com/nolequen/vertx-prometheus-metrics
Source Code Management

Source Code Management

https://github.com/nolequen/vertx-prometheus-metrics

Download vertx-prometheus-metrics

How to add to project

<!-- https://jarcasting.com/artifacts/su.nlq/vertx-prometheus-metrics/ -->
<dependency>
    <groupId>su.nlq</groupId>
    <artifactId>vertx-prometheus-metrics</artifactId>
    <version>3.6.2</version>
</dependency>
// https://jarcasting.com/artifacts/su.nlq/vertx-prometheus-metrics/
implementation 'su.nlq:vertx-prometheus-metrics:3.6.2'
// https://jarcasting.com/artifacts/su.nlq/vertx-prometheus-metrics/
implementation ("su.nlq:vertx-prometheus-metrics:3.6.2")
'su.nlq:vertx-prometheus-metrics:jar:3.6.2'
<dependency org="su.nlq" name="vertx-prometheus-metrics" rev="3.6.2">
  <artifact name="vertx-prometheus-metrics" type="jar" />
</dependency>
@Grapes(
@Grab(group='su.nlq', module='vertx-prometheus-metrics', version='3.6.2')
)
libraryDependencies += "su.nlq" % "vertx-prometheus-metrics" % "3.6.2"
[su.nlq/vertx-prometheus-metrics "3.6.2"]

Dependencies

compile (7)

Group / Artifact Type Version
org.jetbrains : annotations jar 16.0.3
io.vertx : vertx-core jar 3.6.2
io.vertx : vertx-web jar 3.6.2
io.prometheus : simpleclient jar 0.6.0
io.prometheus : simpleclient_servlet jar 0.6.0
io.prometheus : simpleclient_common jar 0.6.0
su.nlq : prometheus-protobuf-servlet jar 0.6.0

test (2)

Group / Artifact Type Version
junit : junit jar 4.12
io.vertx : vertx-unit jar 3.6.2

Project Modules

There are no modules declared in this project.

DEPRECATED

The project is no longer supported, please consider using Vert.x Micrometer Metrics instead.

No Maintenance Intended Build Status Maven Central Codecov Codebeat

Prometheus implementation of the Vert.x Metrics SPI.

Usage

You can find latest release on Maven Central.

  • Maven:
<dependency>
  <groupId>su.nlq</groupId>
  <artifactId>vertx-prometheus-metrics</artifactId>
  <version>3.6.2</version>
</dependency>
  • Gradle:
compile group: 'su.nlq', name: 'vertx-prometheus-metrics', version: '3.6.2'

Now you can set and enable Vert.x metrics:

final Vertx vertx = Vertx.vertx(new VertxOptions().setMetricsOptions(
    new VertxPrometheusOptions().setEnabled(true)
));

Compatibility

Metrics Vert.x Prometheus
0.13.x 3.4.1 0.0.23
0.14.x 3.4.2 0.0.26
0.15.x 3.5.0 0.1.0
Version adjust
3.5.0 3.5.0 0.1.0
3.5.1 3.5.1 0.2.0
3.5.2 3.5.2 0.4.0
3.5.4 3.5.4 0.5.0
3.6.0 3.6.0 0.5.0
3.6.2 3.6.2 0.6.0

Options

There are some special options you can use:

  • Enable or disable embedded server to expose metrics for Prometheus consumption via HTTP or check its state (disabled by default)
  • Specify host and port of the embedded server (localhost:9090 by default)
  • Enable or disable specific MetricsType or check their state (all metrics are enabled by default)
  • Specify which Prometheus CollectorRegistry should be used (unless otherwise specified, the default one is used)
  • Specify the Prometheus exposition format (the default is Text format)

Metrics

The following metrics are provided.

Vert.x metrics

  • vertx_timers_number - gauge of the number of timers by state
  • vertx_verticle_number - gauge of the currently deployed verticles number by class

Event bus metrics

  • vertx_eventbus_handlers - gauge of the registered message handlers number
  • vertx_eventbus_respondents - gauge of the registered message reply-handlers number
  • vertx_eventbus_messages - gauge of the number of messages by range (local or remote), state and address
  • vertx_eventbus_failures - counter of the number of messages handling failures by address, message type and reason
  • vertx_eventbus_messages_time_seconds - histogram representing the total processing time (in seconds) of the messages by address and type
  • vertx_eventbus_bytes - counter of the read\written bytes number by address

HTTP server metrics

  • vertx_httpserver_requests - gauge of the number of processing requests by address, HTTP method, path and state
  • vertx_httpserver_responses - counter of the responses number by address and status code
  • vertx_httpserver_requests_time_seconds - histogram of the total processing time (in seconds) of the requests by address
  • vertx_httpserver_websockets - gauge of the number of the connected websockets
  • vertx_httpserver_connections - gauge of the active connections number
  • vertx_httpserver_bytes - counter of the read\written bytes number by address
  • vertx_httpserver_errors - counter of the number of errors occurred by address

HTTP client metrics

  • vertx_httpclient_endpoints - gauge of endpoints number by address and state
  • vertx_httpclient_endpoints_queue_time_seconds - histogram of the total queue time (in seconds) of pending endpoints
  • vertx_httpclient_requests - gauge of the number of processing requests by address, HTTP method, path and state
  • vertx_httpclient_requests_time_seconds - histogram of the total processing time (in seconds) of the requests by address
  • vertx_httpclient_responses - counter of the responses number by address and status code
  • vertx_httpclient_websockets - gauge of the number of the connected websockets
  • vertx_httpclient_connections - gauge of the active connections number
  • vertx_httpclient_bytes - counter of the read\written bytes number by address
  • vertx_httpclient_errors - counter of the number of errors occurred by address

Net server metrics

  • vertx_netserver_connections - gauge of the active connections number
  • vertx_netserver_bytes - counter of the read\written bytes number by address
  • vertx_netserver_errors - counter of the number of errors occurred by address

Net client metrics

  • vertx_netclient_connections - gauge of the active connections number
  • vertx_netclient_bytes - counter of the read\written bytes number by address
  • vertx_netclient_errors - counter of the number of errors occurred by address

Datagram socket metrics

  • vertx_datagram_socket_bytes - counter of the read\written bytes number by address
  • vertx_datagram_socket_errors - counter of the number of errors occurred by address

Pool metrics

  • vertx_pool_tasks - gauge of the number of processing tasks by pool and state
  • vertx_pool_time_seconds - histogram representing the total processing time (in seconds) of the tasks in a certain state

Versions

Version
3.6.2
3.6.0
3.5.4
3.5.2
3.5.1
3.5.0
0.15.1
0.15
0.14.1
0.14
0.13.4
0.13.3
0.13.2
0.13.1
0.13