Repository: eagle Updated Branches: refs/heads/master 845f89151 -> 342df9974
[EAGLE-1021] JPM Overview OPS trend use max agg https://issues.apache.org/jira/browse/EAGLE-1021 Author: zombieJ <[email protected]> Closes #932 from zombieJ/EAGLE-1021. Project: http://git-wip-us.apache.org/repos/asf/eagle/repo Commit: http://git-wip-us.apache.org/repos/asf/eagle/commit/342df997 Tree: http://git-wip-us.apache.org/repos/asf/eagle/tree/342df997 Diff: http://git-wip-us.apache.org/repos/asf/eagle/diff/342df997 Branch: refs/heads/master Commit: 342df9974c91f845608c9ff3c65b8c1818d56884 Parents: 845f891 Author: zombieJ <[email protected]> Authored: Mon May 15 15:22:21 2017 +0800 Committer: zombieJ <[email protected]> Committed: Mon May 15 15:22:21 2017 +0800 ---------------------------------------------------------------------- .../src/main/webapp/app/apps/jpm/ctrl/overviewCtrl.js | 9 +++++---- .../src/main/webapp/app/apps/jpm/partials/job/detail.html | 2 +- 2 files changed, 6 insertions(+), 5 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/eagle/blob/342df997/eagle-jpm/eagle-jpm-web/src/main/webapp/app/apps/jpm/ctrl/overviewCtrl.js ---------------------------------------------------------------------- diff --git a/eagle-jpm/eagle-jpm-web/src/main/webapp/app/apps/jpm/ctrl/overviewCtrl.js b/eagle-jpm/eagle-jpm-web/src/main/webapp/app/apps/jpm/ctrl/overviewCtrl.js index d50c4df..0e6275c 100644 --- a/eagle-jpm/eagle-jpm-web/src/main/webapp/app/apps/jpm/ctrl/overviewCtrl.js +++ b/eagle-jpm/eagle-jpm-web/src/main/webapp/app/apps/jpm/ctrl/overviewCtrl.js @@ -80,8 +80,9 @@ var endTime = Time.endTime(); var intervalMin = Time.diffInterval(startTime, endTime) / 1000 / 60; - function getTopList(metric, scopeVariable) { + function getTopList(metric, scopeVariable, aggType) { var deferred = $q.defer(); + aggType = aggType || 'avg'; metric = common.template(metric, { type: $scope.type.toLocaleLowerCase() @@ -96,7 +97,7 @@ var aggregation = $scope.aggregationMap[$scope.type]; var aggPromise = cache[metric] = cache[metric] || JPM.aggMetricsToEntities( - JPM.aggMetrics({site: $scope.site}, metric, [aggregation], "avg(value), sum(value) desc", intervalMin, startTime, endTime, 10) + JPM.aggMetrics({site: $scope.site}, metric, [aggregation], aggType + "(value), sum(value) desc", intervalMin, startTime, endTime, 10) , [0])._promise.then(function (list) { var series = $.map(list, function (metrics) { return JPM.metricsToSeries(metrics[0].tags[aggregation], metrics, { @@ -133,8 +134,8 @@ getTopList("hadoop.${type}.history.minute.virtual_memory_bytes", "virtualMemorySeries"); getTopList("hadoop.${type}.history.minute.hdfs_bytes_read", "hdfsBtyesReadSeries"); getTopList("hadoop.${type}.history.minute.hdfs_bytes_written", "hdfsBtyesWrittenSeries"); - getTopList("hadoop.${type}.history.minute.hdfs_read_ops", "hdfsReadOpsSeries"); - getTopList("hadoop.${type}.history.minute.hdfs_write_ops", "hdfsWriteOpsSeries"); + getTopList("hadoop.${type}.history.minute.hdfs_read_ops", "hdfsReadOpsSeries", 'max'); + getTopList("hadoop.${type}.history.minute.hdfs_write_ops", "hdfsWriteOpsSeries", 'max'); getTopList("hadoop.${type}.history.minute.file_bytes_read", "fileBytesReadSeries"); getTopList("hadoop.${type}.history.minute.file_bytes_written", "fileBytesWrittenSeries"); }; http://git-wip-us.apache.org/repos/asf/eagle/blob/342df997/eagle-jpm/eagle-jpm-web/src/main/webapp/app/apps/jpm/partials/job/detail.html ---------------------------------------------------------------------- diff --git a/eagle-jpm/eagle-jpm-web/src/main/webapp/app/apps/jpm/partials/job/detail.html b/eagle-jpm/eagle-jpm-web/src/main/webapp/app/apps/jpm/partials/job/detail.html index eeb5976..573b092 100644 --- a/eagle-jpm/eagle-jpm-web/src/main/webapp/app/apps/jpm/partials/job/detail.html +++ b/eagle-jpm/eagle-jpm-web/src/main/webapp/app/apps/jpm/partials/job/detail.html @@ -136,7 +136,7 @@ <tr> <th>Reduce vCores</th> <td class="text-no-break">{{common.number.toFixed(job.jobCounters.counters["org.apache.hadoop.mapreduce.JobCounter"].VCORES_MILLIS_REDUCES)}} ms</td> - <th>Map CPU</th> + <th>Reduce CPU</th> <td class="text-no-break">{{common.number.toFixed(job.jobCounters.counters.ReduceTaskAttemptCounter.CPU_MILLISECONDS)}} ms</td> <th>HDFS Write Bytes</th> <td title="{{job.jobCounters.counters['org.apache.hadoop.mapreduce.FileSystemCounter'].HDFS_BYTES_WRITTEN}}">
