mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
Forward events to all masters syndic connected to.
This commit is contained in:
parent
8a90c7059b
commit
0e4a744d95
1 changed files with 5 additions and 3 deletions
|
@ -2589,6 +2589,8 @@ class SyndicManager(MinionBase):
|
|||
'''
|
||||
if kwargs is None:
|
||||
kwargs = {}
|
||||
successful = False
|
||||
# Call for each master
|
||||
for master, syndic_future in self.iter_master_options(master_id):
|
||||
if not syndic_future.done() or syndic_future.exception():
|
||||
log.error('Unable to call {0} on {1}, that syndic is not connected'.format(func, master))
|
||||
|
@ -2596,12 +2598,12 @@ class SyndicManager(MinionBase):
|
|||
|
||||
try:
|
||||
getattr(syndic_future.result(), func)(*args, **kwargs)
|
||||
return
|
||||
successful = True
|
||||
except SaltClientError:
|
||||
log.error('Unable to call {0} on {1}, trying another...'.format(func, master))
|
||||
self._mark_master_dead(master)
|
||||
continue
|
||||
log.critical('Unable to call {0} on any masters!'.format(func))
|
||||
if not successful:
|
||||
log.critical('Unable to call {0} on any masters!'.format(func))
|
||||
|
||||
def _return_pub_syndic(self, values, master_id=None):
|
||||
'''
|
||||
|
|
Loading…
Add table
Reference in a new issue