Class StreamMetricsReporter

java.lang.Object
io.dropwizard.metrics5.ScheduledReporter
org.nuxeo.runtime.stream.StreamMetricsReporter
All Implemented Interfaces:
io.dropwizard.metrics5.Reporter, Closeable, AutoCloseable

public class StreamMetricsReporter extends io.dropwizard.metrics5.ScheduledReporter
A Dropwizard Metrics Reporter that sends metrics into a Nuxeo Stream.
Since:
11.5
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    protected String
     
    protected String
     
    protected String
     
    protected static final com.fasterxml.jackson.databind.ObjectMapper
     
  • Constructor Summary

    Constructors
    Constructor
    Description
    StreamMetricsReporter(io.dropwizard.metrics5.MetricRegistry registry, io.dropwizard.metrics5.MetricFilter filter)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected String
     
    protected void
    putGaugeMetric(com.fasterxml.jackson.databind.node.ObjectNode metric, Object o)
     
    void
    report(SortedMap<io.dropwizard.metrics5.MetricName,io.dropwizard.metrics5.Gauge> gauges, SortedMap<io.dropwizard.metrics5.MetricName,io.dropwizard.metrics5.Counter> counters, SortedMap<io.dropwizard.metrics5.MetricName,io.dropwizard.metrics5.Histogram> histograms, SortedMap<io.dropwizard.metrics5.MetricName,io.dropwizard.metrics5.Meter> meters, SortedMap<io.dropwizard.metrics5.MetricName,io.dropwizard.metrics5.Timer> timers)
     
    protected void
    reportCounter(com.fasterxml.jackson.databind.node.ArrayNode metrics, io.dropwizard.metrics5.MetricName key, io.dropwizard.metrics5.Counter value)
     
    protected void
    reportGauge(com.fasterxml.jackson.databind.node.ArrayNode metrics, io.dropwizard.metrics5.MetricName key, io.dropwizard.metrics5.Gauge<?> value)
     
    protected void
    reportTimer(com.fasterxml.jackson.databind.node.ArrayNode metrics, io.dropwizard.metrics5.MetricName key, io.dropwizard.metrics5.Timer value)
     

    Methods inherited from class io.dropwizard.metrics5.ScheduledReporter

    close, convertDuration, convertRate, getDisabledMetricAttributes, getDurationUnit, getRateUnit, isShutdownExecutorOnStop, report, start, start, stop

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • OBJECT_MAPPER

      protected static final com.fasterxml.jackson.databind.ObjectMapper OBJECT_MAPPER
    • hostIp

      protected String hostIp
    • hostname

      protected String hostname
    • nodeId

      protected String nodeId
  • Constructor Details

    • StreamMetricsReporter

      public StreamMetricsReporter(io.dropwizard.metrics5.MetricRegistry registry, io.dropwizard.metrics5.MetricFilter filter)
  • Method Details

    • getNodeId

      protected String getNodeId()
    • report

      public void report(SortedMap<io.dropwizard.metrics5.MetricName,io.dropwizard.metrics5.Gauge> gauges, SortedMap<io.dropwizard.metrics5.MetricName,io.dropwizard.metrics5.Counter> counters, SortedMap<io.dropwizard.metrics5.MetricName,io.dropwizard.metrics5.Histogram> histograms, SortedMap<io.dropwizard.metrics5.MetricName,io.dropwizard.metrics5.Meter> meters, SortedMap<io.dropwizard.metrics5.MetricName,io.dropwizard.metrics5.Timer> timers)
      Specified by:
      report in class io.dropwizard.metrics5.ScheduledReporter
    • reportTimer

      protected void reportTimer(com.fasterxml.jackson.databind.node.ArrayNode metrics, io.dropwizard.metrics5.MetricName key, io.dropwizard.metrics5.Timer value)
    • reportCounter

      protected void reportCounter(com.fasterxml.jackson.databind.node.ArrayNode metrics, io.dropwizard.metrics5.MetricName key, io.dropwizard.metrics5.Counter value)
    • reportGauge

      protected void reportGauge(com.fasterxml.jackson.databind.node.ArrayNode metrics, io.dropwizard.metrics5.MetricName key, io.dropwizard.metrics5.Gauge<?> value)
    • putGaugeMetric

      protected void putGaugeMetric(com.fasterxml.jackson.databind.node.ObjectNode metric, Object o)