validate maxdelay for cron job

The parameter descriptions says the value should be a positive integer
(or 0). Validate the given value to reject invalid values such as
strings or even negative values.

Change-Id: Ib0937e1c3f6f97959b59e2c5812e3dfe696b6dba
This commit is contained in:
Takashi Kajinami 2024-04-08 16:43:43 +09:00
parent 83c9e4b17b
commit 7c7f60cc84
2 changed files with 2 additions and 2 deletions

@ -108,7 +108,7 @@ class nova::cron::archive_deleted_rows (
Boolean $task_log = false,
$sleep = undef,
Boolean $verbose = false,
$maxdelay = 0,
Integer[0] $maxdelay = 0,
Enum['present', 'absent'] $ensure = 'present',
) inherits nova::params {

@ -76,7 +76,7 @@ class nova::cron::purge_shadow_tables (
$age = 14,
Boolean $all_cells = false,
Boolean $verbose = false,
$maxdelay = 0,
Integer[0] $maxdelay = 0,
Enum['present', 'absent'] $ensure = 'present',
) inherits nova::params {