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

Merge pull request #8485 from zhongwencool/delete-config-listeners-api

chore: remove /configs/listeners, use /listeners/ API instead
zhongwencool 3 лет назад
Родитель
Сommit
bc53064ae7

+ 2 - 1
CHANGES-5.0.md

@@ -17,7 +17,8 @@
 ## Enhancements
 
 * Improve the dashboard listener startup log, the listener name is no longer spliced with port information,
-  and the colon(:) is no longer displayed when IP is not specified.[#8480](https://github.com/emqx/emqx/pull/8480)
+  and the colon(:) is no longer displayed when IP is not specified. [#8480](https://github.com/emqx/emqx/pull/8480)
+* Remove `/configs/listeners` API, use `/listeners/` instead. [#8485](https://github.com/emqx/emqx/pull/8485)
 
 # 5.0.3
 

+ 4 - 10
apps/emqx_dashboard/src/emqx_dashboard.appup.src

@@ -1,13 +1,7 @@
 %% -*- mode: erlang -*-
 %% Unless you know what you are doing, DO NOT edit manually!!
 {VSN,
-  [{"5.0.0",
-    [{load_module,emqx_dashboard,brutal_purge,soft_purge,[]},
-     {load_module,emqx_dashboard_api,brutal_purge,soft_purge,[]},
-     {load_module,emqx_dashboard_token,brutal_purge,soft_purge,[]}]},
-   {<<".*">>,[]}],
-  [{"5.0.0",
-    [{load_module,emqx_dashboard,brutal_purge,soft_purge,[]},
-     {load_module,emqx_dashboard_api,brutal_purge,soft_purge,[]},
-     {load_module,emqx_dashboard_token,brutal_purge,soft_purge,[]}]},
-   {<<".*">>,[]}]}.
+  %% we should always restart dashboard to make sure api rules/swagger is updated
+  [{<<".*">>,[{restart_application, emqx_dashboard}]}],
+  [{<<".*">>,[{restart_application, emqx_dashboard}]}]
+}.

+ 2 - 1
apps/emqx_management/src/emqx_mgmt_api_configs.erl

@@ -62,7 +62,8 @@
         <<"prometheus">>,
         <<"telemetry">>,
         <<"sys_topics">>,
-        <<"limiter">>
+        <<"limiter">>,
+        <<"listeners">>
     ] ++ global_zone_roots()
 ).