Re-raise error to preserve restart behavior

This commit is contained in:
Mike Place 2015-12-10 12:54:05 -07:00
parent dc480e332a
commit a04280ceb3
2 changed files with 3 additions and 2 deletions

View file

@ -728,7 +728,8 @@ class Minion(MinionBase):
# Please read PR #23978 before changing, hopefully avoiding regressions.
# Good luck, we're all counting on you. Thanks.
future_exception = self._connect_master_future.exc_info()
if future_exception and future_exception[0] is not salt.exceptions.SaltClientError:
if future_exception:
# This needs to be re-raised to preserve restart_on_error behavior.
raise six.reraise(*future_exception)
@tornado.gen.coroutine

View file

@ -80,7 +80,7 @@ def minion_process(queue):
minion = salt.cli.daemons.Minion()
minion.start()
except (Exception, SaltClientError, SaltReqTimeoutError, SaltSystemExit) as exc:
log.error('Minion failed to start: ', exc_info=True)
log.error('Minion failed to start', exc_info=False)
restart = True
except SystemExit as exc:
restart = False