Set number of poll switch retries to 5
Take number of retries into account, set default to 5. Change-Id: I820074d87b9e82a6b51cc63ecc70d0cc179a244c
This commit is contained in:
parent
6c9fbe6341
commit
0deff5f1fe
@ -36,7 +36,7 @@ flags.add('switch_credential',
|
|||||||
default='version=v2c,community=public')
|
default='version=v2c,community=public')
|
||||||
flags.add('switch_max_retries', type='int',
|
flags.add('switch_max_retries', type='int',
|
||||||
help='max retries of poll switch',
|
help='max retries of poll switch',
|
||||||
default=-1)
|
default=5)
|
||||||
flags.add('switch_retry_interval', type='int',
|
flags.add('switch_retry_interval', type='int',
|
||||||
help='interval to repoll switch',
|
help='interval to repoll switch',
|
||||||
default=10)
|
default=10)
|
||||||
@ -195,7 +195,6 @@ def _poll_switches(client):
|
|||||||
logging.info('switch %s is not updated', switch_ip)
|
logging.info('switch %s is not updated', switch_ip)
|
||||||
elif switch['state'] == 'under_monitoring':
|
elif switch['state'] == 'under_monitoring':
|
||||||
logging.info('switch %s is ready', switch_ip)
|
logging.info('switch %s is ready', switch_ip)
|
||||||
|
|
||||||
try:
|
try:
|
||||||
return _get_machines(client)
|
return _get_machines(client)
|
||||||
except Exception:
|
except Exception:
|
||||||
|
Loading…
Reference in New Issue
Block a user