You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by mp...@apache.org on 2014/09/30 17:02:22 UTC
git commit: AMBARI-7544. Ambari Agent become stopped after
installation (heartBeat lost). (mpapirkovskyy)
Repository: ambari
Updated Branches:
refs/heads/trunk 5518104c1 -> cf4108794
AMBARI-7544. Ambari Agent become stopped after installation (heartBeat lost). (mpapirkovskyy)
Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/cf410879
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/cf410879
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/cf410879
Branch: refs/heads/trunk
Commit: cf4108794dd79e75df8368adf7fa934a31a96027
Parents: 5518104
Author: Myroslav Papirkovskyy <mp...@hortonworks.com>
Authored: Tue Sep 30 18:01:17 2014 +0300
Committer: Myroslav Papirkovskyy <mp...@hortonworks.com>
Committed: Tue Sep 30 18:01:17 2014 +0300
----------------------------------------------------------------------
ambari-agent/src/main/python/ambari_agent/ActionQueue.py | 4 ++--
ambari-agent/src/main/python/ambari_agent/Controller.py | 6 +++++-
2 files changed, 7 insertions(+), 3 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/ambari/blob/cf410879/ambari-agent/src/main/python/ambari_agent/ActionQueue.py
----------------------------------------------------------------------
diff --git a/ambari-agent/src/main/python/ambari_agent/ActionQueue.py b/ambari-agent/src/main/python/ambari_agent/ActionQueue.py
index 476955f..07c1ed7 100644
--- a/ambari-agent/src/main/python/ambari_agent/ActionQueue.py
+++ b/ambari-agent/src/main/python/ambari_agent/ActionQueue.py
@@ -137,8 +137,8 @@ class ActionQueue(threading.Thread):
" of cluster " + queued_command['clusterName'] + \
" to the queue.")
- # Kill if in progress
- self.customServiceOrchestrator.cancel_command(task_id, reason)
+ # Kill if in progress
+ self.customServiceOrchestrator.cancel_command(task_id, reason)
def run(self):
while not self.stopped():
http://git-wip-us.apache.org/repos/asf/ambari/blob/cf410879/ambari-agent/src/main/python/ambari_agent/Controller.py
----------------------------------------------------------------------
diff --git a/ambari-agent/src/main/python/ambari_agent/Controller.py b/ambari-agent/src/main/python/ambari_agent/Controller.py
index 7859a2d..154d6c8 100644
--- a/ambari-agent/src/main/python/ambari_agent/Controller.py
+++ b/ambari-agent/src/main/python/ambari_agent/Controller.py
@@ -146,7 +146,11 @@ class Controller(threading.Thread):
def cancelCommandInQueue(self, commands):
""" Remove from the queue commands, kill the process if it's in progress """
if commands:
- self.actionQueue.cancel(commands)
+ try:
+ self.actionQueue.cancel(commands)
+ except Exception, err:
+ logger.error("Exception occurred on commands cancel: %s", err.message)
+ pass
pass
def addToQueue(self, commands):