Hawkular

Hawkular is a monitoring and metrics server from Red Hat. It provides a centralized place for many processes to report their status and internal state.

Configuration

To add Hawkular support to your application you need the following dependency:

<dependency>
  <groupId>org.wildfly.swarm</groupId>
  <artifactId>hawkular</artifactId>
</dependency>

Additionally, you need to set at least four pieces of information, which can be set through Java properties or through the API on HawkularFraction in order to connect to and authenticate with the Hawkular server.

Description Property Java API Default value

Username

swarm.hawkular.username

hawkular.username(username)

none

Password

swarm.hawkular.password

hawkular.password(password)

none

Server Host

swarm.hawkular.host

hawkular.host(host)

localhost

Server Port

swarm.hawkular.port

hawkular.port(port)

8080

Metrics

By default, all reasonably applicable metrics are installed into the Hawkular agent. As with other fractions, you can configure which metrics, availability-checkers, and resource-types you’d like.

Many static constants have been defined to make it easier to mix in the bits you wish to use.

Description Class

Metrics

org.wildfly.swarm.hawkular.Metrics

Metric-sets

org.wildfly.swarm.hawkular.MetricSets

Availability checkers

org.wildfly.swarm.hawkular.Avails

Avail-sets

org.wildfly.swarm.hawkular.AvailSets

Resource types

org.wildfly.swarm.hawkular.ResourceTypes

Resource type sets

org.wildfly.swarm.hawkular.ResourceTypeSets

Of course, additional custom metrics, metric-sets, availability-checkers, avail-sets, resource-types, and resource-type-sets can be created and installed using relevant Java classes.