Package io.dropwizard.metrics.common
Class Slf4jReporterFactory
java.lang.Object
io.dropwizard.metrics.common.BaseReporterFactory
io.dropwizard.metrics.common.Slf4jReporterFactory
- All Implemented Interfaces:
Discoverable
,ReporterFactory
A
ReporterFactory
for Slf4jReporter
instances.
Configuration Parameters:
Name | Default | Description |
logger | metrics | The name of the logger to write metrics to. |
markerName | (none) | The name of the marker to mark logged metrics with. |
See BaseReporterFactory for more options. |
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptioncom.codahale.metrics.ScheduledReporter
build
(com.codahale.metrics.MetricRegistry registry) Configures and builds aScheduledReporter
instance for the given registry.org.slf4j.Logger
@Nullable String
void
setLoggerName
(String loggerName) void
setMarkerName
(@Nullable String markerName) Methods inherited from class io.dropwizard.metrics.common.BaseReporterFactory
getDisabledAttributes, getDurationUnit, getExcludes, getExcludesAttributes, getFilter, getFrequency, getIncludes, getIncludesAttributes, getRateUnit, getUseRegexFilters, getUseSubstringMatching, setDurationUnit, setExcludes, setExcludesAttributes, setFrequency, setIncludes, setIncludesAttributes, setRateUnit, setUseRegexFilters, setUseSubstringMatching
-
Constructor Details
-
Slf4jReporterFactory
public Slf4jReporterFactory()
-
-
Method Details
-
getLoggerName
-
setLoggerName
-
getLogger
public org.slf4j.Logger getLogger() -
getMarkerName
-
setMarkerName
-
build
public com.codahale.metrics.ScheduledReporter build(com.codahale.metrics.MetricRegistry registry) Description copied from interface:ReporterFactory
Configures and builds aScheduledReporter
instance for the given registry.- Parameters:
registry
- the metrics registry to report metrics from.- Returns:
- a reporter configured for the given metrics registry.
-