Class GraphiteReporter

    • Field Detail

      • LOGGER

        private static final org.slf4j.Logger LOGGER
      • graphite

        private final Graphite graphite
      • clock

        private final Clock clock
      • prefix

        private final java.lang.String prefix
    • Constructor Detail

      • GraphiteReporter

        private GraphiteReporter​(MetricRegistry registry,
                                 Graphite graphite,
                                 Clock clock,
                                 java.lang.String prefix,
                                 java.util.concurrent.TimeUnit rateUnit,
                                 java.util.concurrent.TimeUnit durationUnit,
                                 MetricFilter filter)
    • Method Detail

      • report

        public void report​(java.util.SortedMap<java.lang.String,​Gauge> gauges,
                           java.util.SortedMap<java.lang.String,​Counter> counters,
                           java.util.SortedMap<java.lang.String,​Histogram> histograms,
                           java.util.SortedMap<java.lang.String,​Meter> meters,
                           java.util.SortedMap<java.lang.String,​Timer> timers)
        Description copied from class: ScheduledReporter
        Called periodically by the polling thread. Subclasses should report all the given metrics.
        Specified by:
        report in class ScheduledReporter
        Parameters:
        gauges - all of the gauges in the registry
        counters - all of the counters in the registry
        histograms - all of the histograms in the registry
        meters - all of the meters in the registry
        timers - all of the timers in the registry
      • reportTimer

        private void reportTimer​(java.lang.String name,
                                 Timer timer,
                                 long timestamp)
                          throws java.io.IOException
        Throws:
        java.io.IOException
      • reportMetered

        private void reportMetered​(java.lang.String name,
                                   Metered meter,
                                   long timestamp)
                            throws java.io.IOException
        Throws:
        java.io.IOException
      • reportHistogram

        private void reportHistogram​(java.lang.String name,
                                     Histogram histogram,
                                     long timestamp)
                              throws java.io.IOException
        Throws:
        java.io.IOException
      • reportCounter

        private void reportCounter​(java.lang.String name,
                                   Counter counter,
                                   long timestamp)
                            throws java.io.IOException
        Throws:
        java.io.IOException
      • reportGauge

        private void reportGauge​(java.lang.String name,
                                 Gauge gauge,
                                 long timestamp)
                          throws java.io.IOException
        Throws:
        java.io.IOException
      • format

        private java.lang.String format​(java.lang.Object o)
      • prefix

        private java.lang.String prefix​(java.lang.String... components)
      • format

        private java.lang.String format​(long n)
      • format

        private java.lang.String format​(double v)