瀏覽代碼

AMBARI-11382. test_execute_retryable_command_succeed fails intermittently

Sumit Mohanty 10 年之前
父節點
當前提交
d12a79c402
共有 1 個文件被更改,包括 4 次插入1 次删除
  1. 4 1
      ambari-agent/src/main/python/ambari_agent/ActionQueue.py

+ 4 - 1
ambari-agent/src/main/python/ambari_agent/ActionQueue.py

@@ -279,7 +279,10 @@ class ActionQueue(threading.Thread):
       if isCommandBackground:
         return
       else:
-        status = self.COMPLETED_STATUS if commandresult['exitcode'] == 0 else self.FAILED_STATUS
+        if commandresult['exitcode'] == 0:
+          status = self.COMPLETED_STATUS
+        else:
+          status = self.FAILED_STATUS
 
       if status != self.COMPLETED_STATUS and retryAble == True and maxAttempts > numAttempts:
         delay = self.get_retry_delay(delay)