@InterfaceAudience.Private public class MetricsTableRequests extends Object
Constructor and Description |
---|
MetricsTableRequests(TableName tableName,
org.apache.hadoop.conf.Configuration conf) |
Modifier and Type | Method and Description |
---|---|
private MetricRegistry |
createRegistryForTableRequests() |
private MetricRegistryInfo |
createRegistryInfoForTableRequests() |
MetricRegistryInfo |
getMetricRegistryInfo() |
private void |
init(TableName tableName,
org.apache.hadoop.conf.Configuration conf) |
boolean |
isEnableTableLatenciesMetrics() |
boolean |
isEnabTableQueryMeterMetrics() |
private static String |
qualifyMetrics(String prefix,
TableName tableName) |
void |
removeRegistry() |
void |
updateAppend(long time,
long blockBytesScanned)
Update the Append time histogram.
|
void |
updateCheckAndDelete(long time)
Update the CheckAndDelete time histogram.
|
void |
updateCheckAndMutate(long time,
long blockBytesScanned)
Update the CheckAndMutate time histogram.
|
void |
updateCheckAndPut(long time)
Update the CheckAndPut time histogram.
|
void |
updateDelete(long t)
Update the Delete time histogram
|
void |
updateDeleteBatch(long t)
Update the batch Delete time histogram
|
void |
updateGet(long time,
long blockBytesScanned)
Update the Get time histogram .
|
void |
updateIncrement(long time,
long blockBytesScanned)
Update the Increment time histogram.
|
void |
updatePut(long t)
Update the Put time histogram
|
void |
updatePutBatch(long t)
Update the batch Put time histogram
|
void |
updateScan(long time,
long responseCellSize,
long blockBytesScanned)
Update the scan metrics.
|
void |
updateTableReadQueryMeter()
Update table read QPS
|
void |
updateTableReadQueryMeter(long count)
Update table read QPS
|
void |
updateTableWriteQueryMeter()
Update table write QPS
|
void |
updateTableWriteQueryMeter(long count)
Update table write QPS
|
public static final String ENABLE_TABLE_LATENCIES_METRICS_KEY
public static final boolean ENABLE_TABLE_LATENCIES_METRICS_DEFAULT
public static final String ENABLE_TABLE_QUERY_METER_METRICS_KEY
public static final boolean ENABLE_TABLE_QUERY_METER_METRICS_KEY_DEFAULT
private static final String METRICS_NAME
private static final String METRICS_CONTEXT
private static final String METRICS_DESCRIPTION
private static final String METRICS_JMX_CONTEXT
private static final String GET_TIME
private static final String SCAN_TIME
private static final String SCAN_SIZE
private static final String PUT_TIME
private static final String PUT_BATCH_TIME
private static final String DELETE_TIME
private static final String DELETE_BATCH_TIME
private static final String INCREMENT_TIME
private static final String APPEND_TIME
private static final String CHECK_AND_DELETE_TIME
private static final String CHECK_AND_PUT_TIME
private static final String CHECK_AND_MUTATE_TIME
String BLOCK_BYTES_SCANNED_KEY
String GET_BLOCK_BYTES_SCANNED_KEY
String SCAN_BLOCK_BYTES_SCANNED_KEY
String CHECK_AND_MUTATE_BLOCK_BYTES_SCANNED_KEY
String INCREMENT_BLOCK_BYTES_SCANNED_KEY
String APPEND_BLOCK_BYTES_SCANNED_KEY
private static final String TABLE_READ_QUERY_PER_SECOND
private static final String TABLE_WRITE_QUERY_PER_SECOND
private Histogram getTimeHistogram
private Histogram scanTimeHistogram
private Histogram scanSizeHistogram
private Histogram putTimeHistogram
private Histogram putBatchTimeHistogram
private Histogram deleteTimeHistogram
private Histogram deleteBatchTimeHistogram
private Histogram incrementTimeHistogram
private Histogram appendTimeHistogram
private Histogram checkAndDeleteTimeHistogram
private Histogram checkAndPutTimeHistogram
private Histogram checkAndMutateTimeHistogram
private Counter blockBytesScannedCount
private Histogram checkAndMutateBlockBytesScanned
private Histogram getBlockBytesScanned
private Histogram incrementBlockBytesScanned
private Histogram appendBlockBytesScanned
private Histogram scanBlockBytesScanned
private Meter writeMeter
private MetricRegistry registry
private org.apache.hadoop.conf.Configuration conf
private MetricRegistryInfo registryInfo
private boolean enableTableLatenciesMetrics
private boolean enabTableQueryMeterMetrics
public MetricsTableRequests(TableName tableName, org.apache.hadoop.conf.Configuration conf)
public boolean isEnableTableLatenciesMetrics()
public boolean isEnabTableQueryMeterMetrics()
private MetricRegistry createRegistryForTableRequests()
private MetricRegistryInfo createRegistryInfoForTableRequests()
public void removeRegistry()
private static String qualifyMetrics(String prefix, TableName tableName)
public void updatePut(long t)
t
- time it tookpublic void updatePutBatch(long t)
t
- time it tookpublic void updateDelete(long t)
t
- time it tookpublic void updateDeleteBatch(long t)
t
- time it tookpublic void updateGet(long time, long blockBytesScanned)
time
- time it tookblockBytesScanned
- size of block bytes scanned to retrieve the responsepublic void updateIncrement(long time, long blockBytesScanned)
time
- time it tookblockBytesScanned
- size of block bytes scanned to retrieve the responsepublic void updateAppend(long time, long blockBytesScanned)
time
- time it tookblockBytesScanned
- size of block bytes scanned to retrieve the responsepublic void updateScan(long time, long responseCellSize, long blockBytesScanned)
time
- response time of scanresponseCellSize
- size of the scan resposneblockBytesScanned
- size of block bytes scanned to retrieve the responsepublic void updateCheckAndDelete(long time)
time
- time it tookpublic void updateCheckAndPut(long time)
time
- time it tookpublic void updateCheckAndMutate(long time, long blockBytesScanned)
time
- time it tookpublic void updateTableReadQueryMeter(long count)
count
- Number of occurrences to recordpublic void updateTableReadQueryMeter()
public void updateTableWriteQueryMeter(long count)
count
- Number of occurrences to recordpublic void updateTableWriteQueryMeter()
public MetricRegistryInfo getMetricRegistryInfo()
Copyright © 2007–2020 The Apache Software Foundation. All rights reserved.