mirror of
https://github.com/valitydev/salt.git
synced 2024-11-08 09:23:56 +00:00
Show ZMQ version warning for < 3.2 (rather than < 3)
This commit is contained in:
parent
723405af5b
commit
e53820a982
@ -168,11 +168,13 @@ class Master(SMaster):
|
||||
Create a salt master server instance
|
||||
'''
|
||||
# Warn if ZMQ < 3
|
||||
if int(zmq.zmq_version()[0]) < 3:
|
||||
log.warning('You have a version of ZMQ less than ZMQ 3! There are '
|
||||
'known connection keep-alive issues with ZMQ < 3 '
|
||||
'which may result in loss of contact with minions. '
|
||||
'Please upgrade your ZMQ!')
|
||||
if (int(zmq.zmq_version()[0]) < 3 or
|
||||
(int(zmq.zmq_version()[0]) == 3 and
|
||||
int(zmq.zmq_version()[2]) < 2)):
|
||||
log.warning('You have a version of ZMQ less than ZMQ 3.2! There '
|
||||
'are known connection keep-alive issues with ZMQ < '
|
||||
'3.2 which may result in loss of contact with '
|
||||
'minions. Please upgrade your ZMQ!')
|
||||
SMaster.__init__(self, opts)
|
||||
|
||||
def _clear_old_jobs(self):
|
||||
|
@ -457,12 +457,14 @@ class Minion(object):
|
||||
'''
|
||||
Pass in the options dict
|
||||
'''
|
||||
# Warn if ZMQ < 3
|
||||
if HAS_ZMQ and int(zmq.zmq_version()[0]) < 3:
|
||||
log.warning('You have a version of ZMQ less than ZMQ 3! There are '
|
||||
'known connection keep-alive issues with ZMQ < 3 '
|
||||
'which may result in loss of contact with minions. '
|
||||
'Please upgrade your ZMQ!')
|
||||
# Warn if ZMQ < 3.2
|
||||
if HAS_ZMQ and (int(zmq.zmq_version()[0]) < 3 or
|
||||
(int(zmq.zmq_version()[0]) == 3 and
|
||||
int(zmq.zmq_version()[2]) < 2)):
|
||||
log.warning('You have a version of ZMQ less than ZMQ 3.2! There '
|
||||
'are known connection keep-alive issues with ZMQ < '
|
||||
'3.2 which may result in loss of contact with '
|
||||
'minions. Please upgrade your ZMQ!')
|
||||
# Late setup the of the opts grains, so we can log from the grains
|
||||
# module
|
||||
opts['grains'] = salt.loader.grains(opts)
|
||||
|
Loading…
Reference in New Issue
Block a user