public static class GraphiteReporter.Builder extends Object
GraphiteReporter instances. Defaults to not using a prefix, using the
default clock, converting rates to events/second, converting durations to milliseconds, and
not filtering metrics.| Modifier and Type | Method and Description |
|---|---|
GraphiteReporter |
build(GraphiteSender graphite)
Builds a
GraphiteReporter with the given properties, sending metrics using the
given GraphiteSender. |
GraphiteReporter.Builder |
convertDurationsTo(TimeUnit durationUnit)
Convert durations to the given time unit.
|
GraphiteReporter.Builder |
convertRatesTo(TimeUnit rateUnit)
Convert rates to the given time unit.
|
GraphiteReporter.Builder |
filter(com.codahale.metrics.MetricFilter filter)
Only report metrics which match the given filter.
|
GraphiteReporter.Builder |
prefixedWith(String prefix)
Prefix all metric names with the given string.
|
GraphiteReporter.Builder |
withClock(com.codahale.metrics.Clock clock)
Use the given
Clock instance for the time. |
public GraphiteReporter.Builder withClock(com.codahale.metrics.Clock clock)
Clock instance for the time.clock - a Clock instancethispublic GraphiteReporter.Builder prefixedWith(String prefix)
prefix - the prefix for all metric namesthispublic GraphiteReporter.Builder convertRatesTo(TimeUnit rateUnit)
rateUnit - a unit of timethispublic GraphiteReporter.Builder convertDurationsTo(TimeUnit durationUnit)
durationUnit - a unit of timethispublic GraphiteReporter.Builder filter(com.codahale.metrics.MetricFilter filter)
filter - a MetricFilterthispublic GraphiteReporter build(GraphiteSender graphite)
GraphiteReporter with the given properties, sending metrics using the
given GraphiteSender.graphite - a GraphiteSenderGraphiteReporterCopyright © 2014. All Rights Reserved.