Skip to content
This repository has been archived by the owner on Nov 9, 2017. It is now read-only.

Commit

Permalink
Adapt UI to new metrics
Browse files Browse the repository at this point in the history
  • Loading branch information
ammendonca committed Jun 25, 2015
1 parent 751f97c commit 040cafb
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion ui/console/src/main/scripts/gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ var gulp = require('gulp'),

var POM_MAIN_PATH = '../../../../pom.xml';
var DIST_TARGET_PATH = '../../../../dist/target/';
var WF_CONSOLE_PATH = 'wildfly-8.2.0.Final/modules/org/hawkular/nest/main/deployments/hawkular-console.war/dist/';
var WF_CONSOLE_PATH = 'wildfly-9.0.0.CR2/modules/org/hawkular/nest/main/deployments/hawkular-console.war/dist/';

var plugins = gulpLoadPlugins({});
var pkg = require('./package.json');
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,7 @@ <h3>Deployments</h3>
<td class="state" ng-show="res.state === 'up'"><i class="fa fa-check-circle-o"></i> OK</td>
<td class="state" ng-show="res.state === 'down'"><i class="fa fa-square"></i> Stopped</td>
<td class="state" ng-show="res.state === 'unknown'"><i class="fa fa-times-circle-o"></i> Failed</td>
<td class="state" ng-hide="res.state"><i class="fa fa-chain-broken"></i> Unknown</td>
<td><strong>{{res.properties.name | limitTo14 : res.properties.name.length-13 : 12}}</strong> <span ng-show="false">({{res.properties.name | limitTo14 : res.properties.name.length-13 : 12}})</span> <span class="label label-danger label-alert pull-right" tooltip-trigger tooltip-placement="top" tooltip="Deployment alerts">{{res.alerts}}</span></td>
<td ng-show="true">Enabled</td>
<td ng-show="false">Disabled</td>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,15 +82,15 @@ module HawkularMetrics {
getResourceList(currentTenantId?: TenantId): any {
this.alertList = []; // FIXME: when we have alerts for app server
var tenantId:TenantId = currentTenantId || this.$rootScope.currentPersona.id;
this.HawkularInventory.ResourceOfType.query({tenantId: tenantId, resourceTypeId: 'Deployment'}, (aResourceList, getResponseHeaders) => {
this.HawkularInventory.ResourceOfType.query({resourceTypeId: 'Deployment'}, (aResourceList, getResponseHeaders) => {
var promises = [];
var tmpResourceList = [];
angular.forEach(aResourceList, function(res, idx) {
if (res.id.startsWith(new RegExp('\\[' + this.$routeParams.resourceId + '~/'))) {
tmpResourceList.push(res);
promises.push(this.HawkularMetric.AvailabilityMetricData.query({
promises.push(this.HawkularMetric.AvailabilityMetricData(this.$rootScope.currentPersona.id).query({
tenantId: tenantId,
availabilityId: 'AI~R~' + res.id + '~AT~Deployment Status',
availabilityId: 'AI~R~' + res.id + '~AT~Deployment Status~Deployment Status',
distinct: true}, (resource) => {
var latestData = resource[resource.length-1];
if (latestData) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,9 +85,8 @@ module HawkularMetrics {
this.startTimeStamp = this.endTimeStamp - (this.$routeParams.timeOffset || 3600000);

var tenantId:TenantId = currentTenantId || this.$rootScope.currentPersona.id;
this.HawkularMetric.NumericMetricData.query({
tenantId: tenantId,
numericId: 'MI~R~[' + this.$routeParams.resourceId + '~/]~MT~Heap Used',
this.HawkularMetric.GaugeMetricData(this.$rootScope.currentPersona.id).queryMetrics({
gaugeId: 'MI~R~[' + this.$routeParams.resourceId + '~/]~MT~WildFly Memory Metrics~Heap Used',
start: this.startTimeStamp,
end: this.endTimeStamp,
buckets: 1}, (resource) => {
Expand Down

0 comments on commit 040cafb

Please sign in to comment.