From 652e977b3c3c1ea6ab814e3ba123790d89ae0975 Mon Sep 17 00:00:00 2001 From: "Zaiming (Stone) Shi" Date: Mon, 26 Feb 2024 13:50:33 +0100 Subject: [PATCH] chore: for dashboad add a 'minimum' attribute for duration_s type --- apps/emqx_conf/src/emqx_conf_schema_types.erl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/emqx_conf/src/emqx_conf_schema_types.erl b/apps/emqx_conf/src/emqx_conf_schema_types.erl index 1688284ca..8c7e8ef7a 100644 --- a/apps/emqx_conf/src/emqx_conf_schema_types.erl +++ b/apps/emqx_conf/src/emqx_conf_schema_types.erl @@ -172,7 +172,7 @@ readable("duration()") -> readable("duration_s()") -> #{ swagger => #{type => string, example => <<"1h">>}, - dashboard => #{type => duration}, + dashboard => #{type => duration, minimum => <<"1s">>}, docgen => #{type => "Duration(s)", example => <<"1h">>, desc => ?DESC(duration)} }; readable("duration_ms()") -> @@ -190,7 +190,7 @@ readable("timeout_duration()") -> readable("timeout_duration_s()") -> #{ swagger => #{type => string, example => <<"1h">>}, - dashboard => #{type => duration}, + dashboard => #{type => duration, minimum => <<"1s">>}, docgen => #{type => "Duration(s)", example => <<"1h">>, desc => ?DESC(duration)} }; readable("timeout_duration_ms()") ->