Merge pull request #13336 from rabbitmq/ignore-normal-exit-in-channel

rabbit_channel: Ignore DOWN message from monitored process if it exited normally
This commit is contained in:
Jean-Sébastien Pédron 2025-03-12 17:44:43 +01:00 committed by GitHub
commit 7c2ee95ed8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 6 additions and 0 deletions

View File

@ -36,6 +36,8 @@
%% When a queue is declared as exclusive on a channel, the channel
%% will notify queue collector of that queue.
-include_lib("kernel/include/logger.hrl").
-include_lib("rabbit_common/include/rabbit_framing.hrl").
-include_lib("rabbit_common/include/rabbit.hrl").
-include_lib("rabbit_common/include/rabbit_misc.hrl").
@ -729,6 +731,10 @@ handle_info({{'DOWN', QName}, _MRef, process, QPid, Reason},
handle_eol(QRef, State)
end;
handle_info({'DOWN', _MRef, process, Pid, normal}, State) ->
?LOG_DEBUG("Process ~0p monitored by channel ~0p exited", [Pid, self()]),
{noreply, State};
handle_info({'EXIT', _Pid, Reason}, State) ->
{stop, Reason, State};