public class ReplicationSourceMetrics extends Object implements org.apache.hadoop.metrics.Updater
Modifier and Type | Field and Description |
---|---|
MetricsRate |
logEditsFilteredRate
Rate of log entries filtered by the source
|
MetricsRate |
logEditsReadRate
Rate of log entries (can be multiple Puts) read from the logs
|
MetricsRate |
shippedBatchesRate
Rate of shipped batches by the source
|
MetricsRate |
shippedKBRate
Rate of shipped bytes (in KB) by the source
|
MetricsRate |
shippedOpsRate
Rate of shipped operations by the source
|
org.apache.hadoop.metrics.util.MetricsIntValue |
sizeOfLogQueue
Current size of the queue of logs to replicate,
excluding the one being processed at the moment
|
Constructor and Description |
---|
ReplicationSourceMetrics(String id)
Constructor used to register the metrics
|
Modifier and Type | Method and Description |
---|---|
void |
doUpdates(org.apache.hadoop.metrics.MetricsContext metricsContext) |
void |
refreshAgeOfLastShippedOp()
Convenience method to use the last given timestamp to refresh the age
of the last edit.
|
void |
setAgeOfLastShippedOp(long timestamp)
Set the age of the last edit that was shipped
|
void |
stopReportMetrics() |
public final MetricsRate shippedOpsRate
public final MetricsRate shippedKBRate
public final MetricsRate shippedBatchesRate
public final MetricsRate logEditsReadRate
public final MetricsRate logEditsFilteredRate
public final org.apache.hadoop.metrics.util.MetricsIntValue sizeOfLogQueue
public ReplicationSourceMetrics(String id)
id
- Name of the source this class is monitoringpublic void setAgeOfLastShippedOp(long timestamp)
timestamp
- write time of the editpublic void refreshAgeOfLastShippedOp()
public void doUpdates(org.apache.hadoop.metrics.MetricsContext metricsContext)
doUpdates
in interface org.apache.hadoop.metrics.Updater
public void stopReportMetrics()
Copyright © 2014 The Apache Software Foundation. All Rights Reserved.