[
https://issues.apache.org/jira/browse/PHOENIX-5436?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16919938#comment-16919938
]
Hadoop QA commented on PHOENIX-5436:
------------------------------------
{color:red}-1 overall{color}. Here are the results of testing the latest
attachment
http://issues.apache.org/jira/secure/attachment/12979010/Histogram_View_of_some_Global_Client_metrics.patch
against master branch at commit 197b6e30c894b657758c5d0cb3c6182d6c8d4723.
ATTACHMENT ID: 12979010
{color:green}+1 @author{color}. The patch does not contain any @author
tags.
{color:green}+0 tests included{color}. The patch appears to be a
documentation, build,
or dev patch that doesn't require tests.
{color:green}+1 javac{color}. The applied patch does not increase the
total number of javac compiler warnings.
{color:red}-1 release audit{color}. The applied patch generated 4 release
audit warnings (more than the master's current 0 warnings).
{color:red}-1 lineLengths{color}. The patch introduces the following lines
longer than 100:
+ * Class that adds histogram snapshots (mean, max, nth percentile value
etc.) for some Global Client Metrics as an
+ private static final Logger LOGGER =
LoggerFactory.getLogger(GlobalClientHistogramMetrics.class);
+ private static final boolean isGlobalMetricsEnabled =
QueryServicesOptions.withDefaults().isGlobalHistogramMetricsEnabled();
+ // The MetricRegistry should be retrieved from the GlobalClientMetrics
class as the histogram snapshots are added
+ histMetric.histo = new MutableTimeHistogram(histMetric.name(),
histMetric.metricType.description());
+ // Force the JVM to load the class and invoke the static block of
GlobalClientMetrics so that the MetricRegistry needed here is already created.
+ LOGGER.info("Attempting to retrieve Metric Registry for Phoenix
Global Metrics from" +
Class.forName("org.apache.phoenix.monitoring.GlobalClientMetrics"));
+ MetricRegistryInfo registryInfo = new MetricRegistryInfo("PHOENIX",
"Phoenix Client Metrics", "phoenix", "Phoenix,sub=CLIENT", true);
+ metricRegistry.register(globalMetric.metricType.columnName(), new
PhoenixGlobalMetricHistogram(globalMetric.histo));
+ } else if (metric instanceof
GlobalClientHistogramMetrics.PhoenixGlobalMetricHistogram) {
{color:green}+1 core tests{color}. The patch passed unit tests in .
Test results:
https://builds.apache.org/job/PreCommit-PHOENIX-Build/2935//testReport/
Release audit warnings:
https://builds.apache.org/job/PreCommit-PHOENIX-Build/2935//artifact/patchprocess/patchReleaseAuditWarnings.txt
Console output:
https://builds.apache.org/job/PreCommit-PHOENIX-Build/2935//console
This message is automatically generated.
> Histogram view of Global Client Metrics
> ---------------------------------------
>
> Key: PHOENIX-5436
> URL: https://issues.apache.org/jira/browse/PHOENIX-5436
> Project: Phoenix
> Issue Type: Improvement
> Reporter: abhishek sen
> Priority: Minor
> Labels: histogram, metric-collector, metrics
> Attachments: Histogram_View_of_some_Global_Client_metrics.patch
>
> Original Estimate: 336h
> Remaining Estimate: 336h
>
> Currently the
> [GlobalClientMetrics|https://github.com/apache/phoenix/blob/master/phoenix-core/src/main/java/org/apache/phoenix/monitoring/GlobalClientMetrics.java]
> enum-class defines Phoenix Global Client Metrics as an enum and each
> metric-enum tracks a [Phoenix
> Metric|https://github.com/apache/phoenix/blob/master/phoenix-core/src/main/java/org/apache/phoenix/monitoring/Metric.java]
> object implemented by
> [AtomicMetric|https://github.com/apache/phoenix/blob/master/phoenix-core/src/main/java/org/apache/phoenix/monitoring/AtomicMetric.java]
> class. This tracks a single counter, but in some use cases we want the
> distribution of a particular metric value over some period of time. One
> example could be the metric
> [TASK_EXECUTION_TIME|https://github.com/apache/phoenix/blob/master/phoenix-core/src/main/java/org/apache/phoenix/monitoring/MetricType.java#L47].
> The Global Client metric tracks the aggregate value for the execution time
> of the task. More useful information to monitor would be the distribution of
> task execution time instead.
> Now, in order to incorporate histogram view of the metric, we can use the
> [Histogram
> Implementation|https://github.com/apache/hbase/blob/master/hbase-metrics/src/main/java/org/apache/hadoop/hbase/metrics/impl/HistogramImpl.java]
> from hbase-metrics-api package. The current GlobalClientMetric also
> ultimately adapts to hbase-metrics-api interface but it
> [implements|https://github.com/apache/phoenix/blob/master/phoenix-core/src/main/java/org/apache/phoenix/monitoring/GlobalClientMetrics.java#L155]
> the
> [Gauge|https://github.com/apache/hbase/blob/master/hbase-metrics-api/src/main/java/org/apache/hadoop/hbase/metrics/Gauge.java]
> class which can only keep track of a single value not a histogram. So one
> way could be to create a new GlobalClientHistogramMetrics enum class which
> keeps track of a Histogram (based onĀ
> [MutableTimeHistogram|https://github.com/apache/hbase/blob/master/hbase-hadoop2-compat/src/main/java/org/apache/hadoop/metrics2/lib/MutableTimeHistogram.java])
> for each enum-metric instead of a single counter as it is now. The updating
> of the these new metric can go
> [here|https://github.com/apache/phoenix/blob/master/phoenix-core/src/main/java/org/apache/phoenix/job/JobManager.java#L289]
> within JobManager class where the currently available Global as well as
> request-level metrics are being updated.
--
This message was sent by Atlassian Jira
(v8.3.2#803003)