You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by at...@apache.org on 2014/01/20 14:39:17 UTC
git commit: AMBARI-4350 Background Operations Popup: stdout does not
show for Install tasks. (atkach)
Updated Branches:
refs/heads/trunk b26bca933 -> e96845faa
AMBARI-4350 Background Operations Popup: stdout does not show for Install tasks. (atkach)
Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/e96845fa
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/e96845fa
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/e96845fa
Branch: refs/heads/trunk
Commit: e96845faaf447b6f88d40ea4691bca0ae42cb51d
Parents: b26bca9
Author: atkach <at...@hortonworks.com>
Authored: Mon Jan 20 15:39:11 2014 +0200
Committer: atkach <at...@hortonworks.com>
Committed: Mon Jan 20 15:39:11 2014 +0200
----------------------------------------------------------------------
ambari-web/app/utils/host_progress_popup.js | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/ambari/blob/e96845fa/ambari-web/app/utils/host_progress_popup.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/utils/host_progress_popup.js b/ambari-web/app/utils/host_progress_popup.js
index 54e2007..41f1223 100644
--- a/ambari-web/app/utils/host_progress_popup.js
+++ b/ambari-web/app/utils/host_progress_popup.js
@@ -317,7 +317,8 @@ App.HostPopup = Em.Object.create({
if (existedHosts && (existedHosts.length > 0) && this.get('currentServiceId') === this.get('previousServiceId')) {
existedHosts.forEach(function (host) {
var newHostInfo = hostsMap[host.get('name')];
- if (newHostInfo && newHostInfo.isModified) {
+ //update only hosts with changed tasks or currently opened tasks of host
+ if (newHostInfo && (newHostInfo.isModified || this.get('currentHostName') === host.get('name'))) {
var hostStatus = self.getStatus(newHostInfo.logTasks);
var hostProgress = self.getProgress(newHostInfo.logTasks);
host.set('status', App.format.taskStatus(hostStatus[0]));
@@ -327,13 +328,14 @@ App.HostPopup = Em.Object.create({
host.set('progress', hostProgress);
host.set('barWidth', "width:" + hostProgress + "%;");
host.set('logTasks', newHostInfo.logTasks);
- //update only currently opened tasks of host
- if (this.get('currentHostName') === host.get('name')) {
- var existTasks = host.get('tasks');
+ var existTasks = host.get('tasks');
+ if (existTasks) {
newHostInfo.logTasks.forEach(function (_task) {
var existTask = existTasks.findProperty('id', _task.Tasks.id);
if (existTask) {
existTask.set('status', App.format.taskStatus(_task.Tasks.status));
+ existTask.set('stdout', _task.Tasks.stdout);
+ existTask.set('stderr', _task.Tasks.stderr);
} else {
existTasks.pushObject(this.createTask(_task));
}