Skip to content

Commit 4d0f93e

Browse files
committed
Fix Prometheus and dependencies loading
A new dependency of the Prometheus library (ddskerl) is not loaded properly, breaking stop_app in some occasions. Per discussion with @lhoguin and @dumbbell. References #14885
1 parent 8c9e252 commit 4d0f93e

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

deps/rabbit/src/rabbit.erl

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1038,9 +1038,10 @@ do_run_postlaunch_phase(Plugins) ->
10381038
%% * Collectors: the `rabbitmq_prometheus' plugin explicitly registers
10391039
%% all collectors.
10401040
%% * Instrumenters: no instrumenters are used.
1041-
_ = application:load(prometheus),
1042-
ok = application:set_env(prometheus, collectors, [default]),
1043-
ok = application:set_env(prometheus, instrumenters, []),
1041+
ok = application:set_env(prometheus, collectors, [default],
1042+
[{persistent, true}]),
1043+
ok = application:set_env(prometheus, instrumenters, [],
1044+
[{persistent, true}]),
10441045

10451046
%% However, we want to run their boot steps and actually start
10461047
%% them one by one, to ensure a dependency is fully started

0 commit comments

Comments
 (0)