Skip to content

Commit 49912ca

Browse files
committed
QQ: avoid dead lock in queue federation.
When processing the queue federation startup even the process may call back into the ra process causing a deadlock. in this case we spawn a temporary process to avoid this.
1 parent a33664c commit 49912ca

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

deps/rabbit/src/rabbit_quorum_queue.erl

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -547,6 +547,10 @@ spawn_deleter(QName) ->
547547
delete(Q, false, false, <<"expired">>)
548548
end).
549549

550+
spawn_notify_decorators(QName, startup = Fun, Args) ->
551+
spawn(fun() ->
552+
notify_decorators(QName, Fun, Args)
553+
end);
550554
spawn_notify_decorators(QName, Fun, Args) ->
551555
%% run in ra process for now
552556
catch notify_decorators(QName, Fun, Args).

0 commit comments

Comments
 (0)