Add reset of watchdog timeout flag

For the long lived worker, the flag never gets reset, which means that
every job that runs after a job that times out will show as failed for
no good reason.

Change-Id: I6cae11c1e89f6ccc78cb5bfaf61ef78e846e87be
This commit is contained in:
Monty Taylor 2016-12-07 09:57:42 -06:00
parent e9bc74fb39
commit 4afdd8a89d
No known key found for this signature in database
GPG Key ID: 7BAE94BC7141A594
1 changed files with 6 additions and 0 deletions

View File

@ -1421,6 +1421,8 @@ class NodeWorker(object):
preexec_fn=os.setsid,
env=env_copy,
)
# Reset timeout flag
self._watchdog_timeout = False
ret = None
watchdog = Watchdog(ANSIBLE_DEFAULT_PRE_TIMEOUT,
self._ansibleTimeout,
@ -1462,6 +1464,8 @@ class NodeWorker(object):
preexec_fn=os.setsid,
env=env_copy,
)
# Reset timeout flag
self._watchdog_timeout = False
ret = None
watchdog = Watchdog(timeout + ANSIBLE_WATCHDOG_GRACE,
self._ansibleTimeout,
@ -1514,6 +1518,8 @@ class NodeWorker(object):
preexec_fn=os.setsid,
env=env_copy,
)
# Reset timeout flag
self._watchdog_timeout = False
ret = None
watchdog = Watchdog(ANSIBLE_DEFAULT_POST_TIMEOUT,
self._ansibleTimeout,