Просмотр исходного кода

Merge pull request #10430 from lafirest/fix/simplify_retainer_cfg

fix(retainer): mark `flow-control` as non-importance field
zhongwencool 2 лет назад
Родитель
Сommit
b8d5fd83ef
2 измененных файлов с 7 добавлено и 2 удалено
  1. 5 2
      apps/emqx_retainer/src/emqx_retainer_schema.erl
  2. 2 0
      changes/ce/perf-10430.en.md

+ 5 - 2
apps/emqx_retainer/src/emqx_retainer_schema.erl

@@ -53,7 +53,8 @@ fields("retainer") ->
             sc(
                 ?R_REF(flow_control),
                 flow_control,
-                #{}
+                #{},
+                ?IMPORTANCE_HIDDEN
             )},
         {max_payload_size,
             sc(
@@ -125,7 +126,9 @@ desc(_) ->
 %%    hoconsc:mk(Type, #{desc => ?DESC(DescId)}).
 
 sc(Type, DescId, Default) ->
-    hoconsc:mk(Type, #{default => Default, desc => ?DESC(DescId)}).
+    sc(Type, DescId, Default, ?DEFAULT_IMPORTANCE).
+sc(Type, DescId, Default, Importance) ->
+    hoconsc:mk(Type, #{default => Default, desc => ?DESC(DescId), importance => Importance}).
 
 backend_config() ->
     hoconsc:mk(hoconsc:ref(?MODULE, mnesia_config), #{desc => ?DESC(backend)}).

+ 2 - 0
changes/ce/perf-10430.en.md

@@ -0,0 +1,2 @@
+Simplify the configuration of the `retainer` feature.
+- Mark `flow_control` as non-importance field.