Chromium Code Reviews| Index: Tools/GardeningServer/ui/ct-failure-analyzer.html |
| diff --git a/Tools/GardeningServer/ui/ct-failure-analyzer.html b/Tools/GardeningServer/ui/ct-failure-analyzer.html |
| index 22431aabf91c4ebb8c239d4e38c3bb0c499eb2ca..662599837986b4784ca16c08edef7df7fa633937 100644 |
| --- a/Tools/GardeningServer/ui/ct-failure-analyzer.html |
| +++ b/Tools/GardeningServer/ui/ct-failure-analyzer.html |
| @@ -32,7 +32,7 @@ found in the LICENSE file. |
| "https://build.chromium.org/p/chromium.mac", |
| "https://build.chromium.org/p/chromium.memory", |
| "https://build.chromium.org/p/chromium.win" |
| - ], |
| + ] |
| }, |
| _failureListComparator: function(tree, a, b) { |
| @@ -69,15 +69,21 @@ found in the LICENSE file. |
| var annotationPromise = CTFailureGroup.fetchAnnotations(); |
| net.json('http://sheriff-o-matic.appspot.com/alerts').then(function(data) { |
| annotationPromise.then(function(annotations) { |
| - // FIXME: Don't special-case the blink master. |
| - this.builderLatestRevisions = new CTBuilderRevisions(data.latest_revisions['chromium.webkit']); |
| - this.failures = {}; |
| - this.lastUpdateDate = new Date(data.date * 1000); |
| - data.range_groups.forEach(function(group) { |
| - this._processFailuresForGroup(group, data.alerts, annotations); |
| - }.bind(this)); |
| - Object.keys(this.failures, function (tree, failuresByTree) { |
| - this.failures[tree].sort(this._failureListComparator.bind(this, tree)); |
| + net.json('http://localhost:8123/builder_alerts.json').then(function(trooper_data) { |
| + trooper_data = JSON.parse(trooper_data.content); |
| + // FIXME: Don't special-case the blink master. |
| + this.builderLatestRevisions = new CTBuilderRevisions(data.latest_revisions['chromium.webkit']); |
| + this.failures = {}; |
| + this.lastUpdateDate = new Date(data.date * 1000); |
| + data.range_groups.forEach(function(group) { |
| + this._processFailuresForGroup(group, data.alerts, annotations); |
| + }.bind(this)); |
| + trooper_data.range_groups.forEach(function(group) { |
| + this._processFailuresForGroup(group, trooper_data.alerts, annotations, 'trooper'); |
| + }.bind(this)); |
| + Object.keys(this.failures, function (tree, failuresByTree) { |
| + this.failures[tree].sort(this._failureListComparator.bind(this, tree)); |
| + }.bind(this)); |
| }.bind(this)); |
| }.bind(this)); |
| }.bind(this)); |
| @@ -95,7 +101,7 @@ found in the LICENSE file. |
| return 0; |
| }, |
| - _processFailuresForGroup: function(group, failures, annotations) { |
| + _processFailuresForGroup: function(group, failures, annotations, tree) { |
|
ojan
2014/08/16 02:15:39
Nit: I typically annotate optional arguments with
|
| var failuresByReason = {}; |
| var masterToTree = {}; |
| @@ -123,7 +129,7 @@ found in the LICENSE file. |
| reason: reason, |
| }); |
| - var tree = masterToTree[failure.master_url]; |
| + tree = tree || masterToTree[failure.master_url]; |
| // FIXME: Use a model class instead of a dumb object. |
| if (!failuresByReason[failureKey]) |