diff options
| author | Jean-Sébastien Pédron <jean-sebastien@rabbitmq.com> | 2020-02-10 14:14:58 +0100 |
|---|---|---|
| committer | Jean-Sébastien Pédron <jean-sebastien@rabbitmq.com> | 2020-02-10 14:14:58 +0100 |
| commit | 14b69d279956705fa928f892be0148b74c957129 (patch) | |
| tree | 0ee4ee6d2d27fd364285ba093a8b7fe004b33ee3 | |
| parent | d188ea9042e5621432ab276290b955168d668d22 (diff) | |
| download | rabbitmq-server-git-14b69d279956705fa928f892be0148b74c957129.tar.gz | |
rabbit: Merge start_apps/2 and start_loaded_apps/2
The latter is only ever called by the former, so there is no need to
split them.
| -rw-r--r-- | src/rabbit.erl | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/src/rabbit.erl b/src/rabbit.erl index 41a54ba36c..4f62a55e0e 100644 --- a/src/rabbit.erl +++ b/src/rabbit.erl @@ -606,17 +606,16 @@ start_apps(Apps) -> -spec start_apps([app_name()], #{app_name() => restart_type()}) -> 'ok'. -%% TODO: start_apps/2 and start_loaded_apps/2 are now specific to -%% plugins. Those function should be moved over `rabbit_plugins`, along -%% with top_apps/1, once the latter stops using app_utils as well. +%% TODO: start_apps/2 and is now specific to plugins. This function +%% should be moved over `rabbit_plugins`, along with stop_apps/1, once +%% the latter stops using app_utils as well. start_apps(Apps, RestartTypes) -> + false = lists:member(rabbit, Apps), %% Assertion. + %% We need to load all applications involved in order to be able to + %% find new feature flags. app_utils:load_applications(Apps), ok = rabbit_feature_flags:refresh_feature_flags_after_app_load(Apps), - start_loaded_apps(Apps, RestartTypes). - -start_loaded_apps(Apps, RestartTypes) -> - false = lists:member(rabbit, Apps), %% Assertion. rabbit_prelaunch_conf:decrypt_config(Apps), lists:foreach( fun(App) -> |
