I have the following in my build.gradle:
compile "io.dropwizard.metrics:metrics-core:3.1.0"
compile "io.dropwizard.metrics:metrics-servlet:3.1.0"
compile "io.dropwizard.metrics:metrics-healthchecks:3.1.0"
On inspection of metrics-servlet, I see:
According to https://dropwizard.github.io/metrics/3.1.0/manual/servlets/,
"The metrics-servlets module provides a handful of useful servlets", including HealthCheckServlet, MetricsServlet, and ThreadDumpServlet.
Where are these Servlets if not in metrics-servlet!?
There are both a metrics-servlet and metrics-servlets module. Servlet contains abstract framework classes and servlets contains the concrete implementations.
This works:
compile "io.dropwizard.metrics:metrics-core:3.1.0"
compile "io.dropwizard.metrics:metrics-servlet:3.1.0"
compile "io.dropwizard.metrics:metrics-servlets:3.1.0"
compile "io.dropwizard.metrics:metrics-healthchecks:3.1.0"
And actually, only the following is needed:
compile "io.dropwizard.metrics:metrics-servlets:3.1.0"
compile "io.dropwizard.metrics:metrics-healthchecks:3.1.0"