Return-Path: X-Original-To: apmail-tez-commits-archive@minotaur.apache.org Delivered-To: apmail-tez-commits-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 4E54D174FD for ; Tue, 10 Feb 2015 20:44:50 +0000 (UTC) Received: (qmail 12996 invoked by uid 500); 10 Feb 2015 20:44:50 -0000 Delivered-To: apmail-tez-commits-archive@tez.apache.org Received: (qmail 12954 invoked by uid 500); 10 Feb 2015 20:44:50 -0000 Mailing-List: contact commits-help@tez.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@tez.apache.org Delivered-To: mailing list commits@tez.apache.org Received: (qmail 12945 invoked by uid 99); 10 Feb 2015 20:44:50 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 10 Feb 2015 20:44:50 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 08668E0375; Tue, 10 Feb 2015 20:44:50 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: hitesh@apache.org To: commits@tez.apache.org Date: Tue, 10 Feb 2015 20:44:51 -0000 Message-Id: <613a074632254ac294e5cda02eef54cd@git.apache.org> In-Reply-To: <525ac302c70f40d3a558bf9a8f3acbd2@git.apache.org> References: <525ac302c70f40d3a558bf9a8f3acbd2@git.apache.org> X-Mailer: ASF-Git Admin Mailer Subject: [2/2] tez git commit: TEZ-2069. Tez UI: appId should link to application in dag details view. (Sreenath Somarajapuram via hitesh) TEZ-2069. Tez UI: appId should link to application in dag details view. (Sreenath Somarajapuram via hitesh) (cherry picked from commit 48055300dbcb7dc4c5d0f8105fcb4b772aae176a) Project: http://git-wip-us.apache.org/repos/asf/tez/repo Commit: http://git-wip-us.apache.org/repos/asf/tez/commit/e8610693 Tree: http://git-wip-us.apache.org/repos/asf/tez/tree/e8610693 Diff: http://git-wip-us.apache.org/repos/asf/tez/diff/e8610693 Branch: refs/heads/branch-0.6 Commit: e8610693f73454d0fc2deecb16f9026cc86cb43d Parents: f661803 Author: Hitesh Shah Authored: Tue Feb 10 12:42:05 2015 -0800 Committer: Hitesh Shah Committed: Tue Feb 10 12:44:38 2015 -0800 ---------------------------------------------------------------------- CHANGES.txt | 1 + .../app/scripts/controllers/dag_controller.js | 44 +++++++++++++------- tez-ui/src/main/webapp/app/templates/dag.hbs | 8 +++- 3 files changed, 36 insertions(+), 17 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/tez/blob/e8610693/CHANGES.txt ---------------------------------------------------------------------- diff --git a/CHANGES.txt b/CHANGES.txt index 02b8c24..a8a00f5 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -6,6 +6,7 @@ Release 0.6.1: Unreleased INCOMPATIBLE CHANGES ALL CHANGES: + TEZ-2069. Tez UI: appId should link to application in dag details view. TEZ-2063. Tez UI: Flaky log url in tasks table. TEZ-2062. Tez UI: Showing 50 elements not working properly. TEZ-1917. Examples should extend TezExampleBase. http://git-wip-us.apache.org/repos/asf/tez/blob/e8610693/tez-ui/src/main/webapp/app/scripts/controllers/dag_controller.js ---------------------------------------------------------------------- diff --git a/tez-ui/src/main/webapp/app/scripts/controllers/dag_controller.js b/tez-ui/src/main/webapp/app/scripts/controllers/dag_controller.js index 1fdf053..b17157f 100644 --- a/tez-ui/src/main/webapp/app/scripts/controllers/dag_controller.js +++ b/tez-ui/src/main/webapp/app/scripts/controllers/dag_controller.js @@ -17,19 +17,18 @@ */ App.DagController = Em.ObjectController.extend(App.Helpers.DisplayHelper, { - controllerName: 'DagController', + controllerName: 'DagController', + pageTitle: 'Dag', + loading: true, - pageTitle: 'Dag', - - loading: true, - - updateLoading: function() { + updateLoading: function() { var that = this; var loaders = []; + var applicationId = this.get('applicationId'); if (this.get('status') === 'RUNNING') { // update the progress info if available. this need not block the UI var aminfoLoader = that.store.find('dagProgress', that.get('id'), { - appId: that.get('applicationId'), + appId: applicationId, dagIdx: that.get('idx') }).then(function(dagProgressInfo) { that.set('progress', dagProgressInfo.get('progress')); @@ -38,19 +37,32 @@ App.DagController = Em.ObjectController.extend(App.Helpers.DisplayHelper, { }); loaders.push(aminfoLoader); } + var appDetailLoader = this.store.find('appDetail', applicationId) + .then(function(app){ + that.set('appDetail', app); + }); + var tezAppLoader = this.store.find('tezApp', 'tez_' + applicationId) + .then(function(app){ + that.set('tezApp', app); + }); + Em.RSVP.allSettled(loaders).then(function(){ that.set('loading', false); }); }.observes('content'), - childDisplayViews: [ - Ember.Object.create({title: 'Details', linkTo: 'dag.index'}), - Ember.Object.create({title: 'View', linkTo: 'dag.view'}), - Ember.Object.create({title: 'Vertices', linkTo: 'dag.vertices'}), - Ember.Object.create({title: 'Tasks', linkTo: 'dag.tasks'}), - Ember.Object.create({title: 'Task Attempts', linkTo: 'dag.taskAttempts'}), - Ember.Object.create({title: 'Counters', linkTo: 'dag.counters'}), - Ember.Object.create({title: 'Swimlane', linkTo: 'dag.swimlane'}) - ], + enableAppIdLink: function() { + return !!(this.get('tezApp') && this.get('appDetail')); + }.property('applicationId', 'appDetail', 'tezApp'), + + childDisplayViews: [ + Ember.Object.create({title: 'Details', linkTo: 'dag.index'}), + Ember.Object.create({title: 'View', linkTo: 'dag.view'}), + Ember.Object.create({title: 'Vertices', linkTo: 'dag.vertices'}), + Ember.Object.create({title: 'Tasks', linkTo: 'dag.tasks'}), + Ember.Object.create({title: 'Task Attempts', linkTo: 'dag.taskAttempts'}), + Ember.Object.create({title: 'Counters', linkTo: 'dag.counters'}), + Ember.Object.create({title: 'Swimlane', linkTo: 'dag.swimlane'}) + ], }); http://git-wip-us.apache.org/repos/asf/tez/blob/e8610693/tez-ui/src/main/webapp/app/templates/dag.hbs ---------------------------------------------------------------------- diff --git a/tez-ui/src/main/webapp/app/templates/dag.hbs b/tez-ui/src/main/webapp/app/templates/dag.hbs index 6980401..b34aebe 100644 --- a/tez-ui/src/main/webapp/app/templates/dag.hbs +++ b/tez-ui/src/main/webapp/app/templates/dag.hbs @@ -33,7 +33,13 @@ {{t 'common.applicationId'}} - {{applicationId}} + + {{#if enableAppIdLink}} + {{#link-to 'tez-app' applicationId class='ember-table-content'}}{{applicationId}}{{/link-to}} + {{else}} + {{applicationId}} + {{/if}} + {{t 'common.user'}}