Package org.apache.storm.metric
Class LoggingMetricsConsumer
java.lang.Object
org.apache.storm.metric.LoggingMetricsConsumer
- All Implemented Interfaces:
- IMetricsConsumer
Listens for all metrics, dumps them to log
 
To use, add this to your topology's configuration:
```java conf.registerMetricsConsumer(org.apache.storm.metrics.LoggingMetricsConsumer.class, 1); ```
Or edit the storm.yaml config file:
```yaml topology.metrics.consumer.register: - class: "org.apache.storm.metrics.LoggingMetricsConsumer" parallelism.hint: 1 ```
- 
Nested Class SummaryNested classes/interfaces inherited from interface org.apache.storm.metric.api.IMetricsConsumerIMetricsConsumer.DataPoint, IMetricsConsumer.TaskInfo
- 
Field SummaryFields
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionvoidcleanup()voidhandleDataPoints(IMetricsConsumer.TaskInfo taskInfo, Collection<IMetricsConsumer.DataPoint> dataPoints) voidprepare(Map<String, Object> topoConf, Object registrationArgument, TopologyContext context, IErrorReporter errorReporter) 
- 
Field Details- 
LOGpublic static final org.slf4j.Logger LOG
 
- 
- 
Constructor Details- 
LoggingMetricsConsumerpublic LoggingMetricsConsumer()
 
- 
- 
Method Details- 
preparepublic void prepare(Map<String, Object> topoConf, Object registrationArgument, TopologyContext context, IErrorReporter errorReporter) - Specified by:
- preparein interface- IMetricsConsumer
 
- 
handleDataPointspublic void handleDataPoints(IMetricsConsumer.TaskInfo taskInfo, Collection<IMetricsConsumer.DataPoint> dataPoints) - Specified by:
- handleDataPointsin interface- IMetricsConsumer
 
- 
cleanuppublic void cleanup()- Specified by:
- cleanupin interface- IMetricsConsumer
 
 
-