diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/controllers/yarn-app/logs.js b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/controllers/yarn-app/logs.js index e1a8ec8dc27..d7eac3ffd5b 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/controllers/yarn-app/logs.js +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/controllers/yarn-app/logs.js @@ -263,5 +263,12 @@ export default Ember.Controller.extend({ isLogAggregationNotSucceeded: Ember.computed("model.app", function() { const logAggregationStatus = this.get("model.app.logAggregationStatus"); return logAggregationStatus !== "SUCCEEDED"; - }) + }), + + isTimelineUnHealthy: function() { + if (this.model && this.model.timelineHealth) { + return this.model.timelineHealth.get('isTimelineUnHealthy'); + } + return true; + }.property('model.timelineHealth') }); diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/routes/yarn-app/logs.js b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/routes/yarn-app/logs.js index b73bc80f175..9719f804f04 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/routes/yarn-app/logs.js +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/routes/yarn-app/logs.js @@ -31,7 +31,10 @@ export default AbstractRoute.extend(AppAttemptMixin, { attempts: this.fetchAttemptListFromRMorATS(app_id, this.store).catch(function() { return []; }), - app: this.fetchAppInfoFromRMorATS(app_id, this.store) + app: this.fetchAppInfoFromRMorATS(app_id, this.store), + timelineHealth: this.store.queryRecord('timeline-health', {}).catch(function() { + return null; + }) }); }, diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/templates/yarn-app/logs.hbs b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/templates/yarn-app/logs.hbs index 10fd73ec940..b6dd318779c 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/templates/yarn-app/logs.hbs +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/templates/yarn-app/logs.hbs @@ -32,43 +32,52 @@ Loading... {{/if}} - {{#if attemptList}} + {{#if isTimelineUnHealthy}}
-
- -
- -
+
+ + Logs are unavailable because Application Timeline Service seems unhealthy.
- {{#if attemptContainerList}} -
- -
- -
-
- {{else}} - {{#if (and selectedAttemptId (not _isLoadingTopPanel))}} -
-

No container data available!

-
- {{/if}} - {{/if}}
{{else}} -
-

No data available!

-
+ {{#if attemptList}} +
+
+ +
+ +
+
+ {{#if attemptContainerList}} +
+ +
+ +
+
+ {{else}} + {{#if (and selectedAttemptId (not _isLoadingTopPanel))}} +
+

No container data available!

+
+ {{/if}} + {{/if}} +
+ {{else}} +
+

No data available!

+
+ {{/if}} {{/if}}