Merge "Set the min and max value of IntOpt config options"

This commit is contained in:
Zuul 2018-12-18 10:02:46 +00:00 committed by Gerrit Code Review
commit 0a65911caf
3 changed files with 8 additions and 1 deletions

View File

@ -32,7 +32,10 @@ from blazar.utils import service as service_utils
opts = [
cfg.IntOpt('port', default=1234,
cfg.IntOpt('port',
default=1234,
min=0,
max=65535,
help='Port that will be used to listen on'),
]

View File

@ -38,11 +38,13 @@ manager_opts = [
'support.)'),
cfg.IntOpt('minutes_before_end_lease',
default=60,
min=0,
help='Minutes prior to the end of a lease in which actions '
'like notification and snapshot are taken. If this is '
'set to 0, then these actions are not taken.'),
cfg.IntOpt('event_max_retries',
default=1,
min=0,
max=50,
help='Number of times to retry an event action.')
]

View File

@ -56,9 +56,11 @@ plugin_opts = [
'of compute hosts by polling the Nova API.'),
cfg.IntOpt('polling_interval',
default=60,
min=1,
help='Interval (seconds) of polling for health checking.'),
cfg.IntOpt('healing_interval',
default=60,
min=0,
help='Interval (minutes) of reservation healing. '
'If 0 is specified, the interval is infinite and all the '
'reservations in the future is healed at one time.'),