Package ratpack.dropwizard.metrics
Class MetricsPrometheusHandler
- java.lang.Object
-
- ratpack.dropwizard.metrics.MetricsPrometheusHandler
-
- All Implemented Interfaces:
Handler
public class MetricsPrometheusHandler extends Object implements Handler
A Handler that exposes metric reports in Prometheus format.This handler should be bound to an application path, and most likely only for the GET method…
import ratpack.dropwizard.metrics.MetricsPrometheusHandler; import static org.junit.jupiter.api.Assertions.*; assertTrue(chain instanceof ratpack.core.handling.Chain); chain.get("admin/metrics", new MetricsPrometheusHandler());
- Since:
- 1.6
-
-
Constructor Summary
Constructors Constructor Description MetricsPrometheusHandler()
-
-
-
Method Detail
-
handle
public void handle(Context ctx) throws Exception
Description copied from interface:Handler
Handles the context.- Specified by:
handle
in interfaceHandler
- Parameters:
ctx
- The context to handle- Throws:
Exception
- if anything goes wrong (exception will be implicitly passed to the context'sContext.error(Throwable)
method)
-
-