Skip to content

Commit

Permalink
Fix channel rate limiter for ack messages
Browse files Browse the repository at this point in the history
  • Loading branch information
acogoluegnes committed Jul 26, 2021
1 parent 23432f3 commit a6f591d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions deps/rabbit/src/rabbit_channel.erl
Original file line number Diff line number Diff line change
Expand Up @@ -2121,13 +2121,13 @@ notify_limiter(Limiter, Acked) ->
%% common case.
case rabbit_limiter:is_active(Limiter) of
false -> ok;
true -> case lists:foldl(fun ({_, CTag, _, _}, Acc) when is_integer(CTag) ->
true -> case lists:foldl(fun (#pending_ack{tag = CTag}, Acc) when is_integer(CTag) ->
%% Quorum queues use integer CTags
%% classic queues use binaries
%% Quorum queues do not interact
%% with limiters
Acc;
({_, _, _, _}, Acc) -> Acc + 1
(_, Acc) -> Acc + 1
end, 0, Acked) of
0 -> ok;
Count -> rabbit_limiter:ack(Limiter, Count)
Expand Down

0 comments on commit a6f591d

Please sign in to comment.