Skip to content

Commit

Permalink
Keep StartMode argument for mixed-version compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
dcorbacho committed Jun 3, 2024
1 parent 1bb7c47 commit c95d318
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions deps/rabbit/src/rabbit_amqqueue_sup.erl
Original file line number Diff line number Diff line change
Expand Up @@ -9,18 +9,18 @@

-behaviour(supervisor).

-export([start_link/1]).
-export([start_link/2]).

-export([init/1]).

-include_lib("rabbit_common/include/rabbit.hrl").

%%----------------------------------------------------------------------------

-spec start_link(amqqueue:amqqueue()) ->
-spec start_link(amqqueue:amqqueue(), any()) ->
{'ok', pid(), pid()}.

start_link(Q) ->
start_link(Q, _StartMode) ->
Marker = spawn_link(fun() -> receive stop -> ok end end),
StartMFA = {rabbit_amqqueue_process, start_link, [Q, Marker]},
ChildSpec = #{id => rabbit_amqqueue,
Expand Down
2 changes: 1 addition & 1 deletion deps/rabbit/src/rabbit_amqqueue_sup_sup.erl
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ start_link() ->
start_queue_process(Node, Q) ->
#resource{virtual_host = VHost} = amqqueue:get_name(Q),
{ok, Sup} = find_for_vhost(VHost, Node),
{ok, _SupPid, QPid} = supervisor:start_child(Sup, [Q]),
{ok, _SupPid, QPid} = supervisor:start_child(Sup, [Q, declare]),
QPid.

init([]) ->
Expand Down

0 comments on commit c95d318

Please sign in to comment.