Skip to content

Commit b521f1f

Browse files
committed
Remove x-cancel-on-ha-failover
1 parent 2a15f9c commit b521f1f

File tree

1 file changed

+1
-20
lines changed

1 file changed

+1
-20
lines changed

deps/rabbit/src/rabbit_channel.erl

Lines changed: 1 addition & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1752,19 +1752,7 @@ handle_consuming_queue_down_or_eol(QName,
17521752
end,
17531753
gb_sets:fold(
17541754
fun (CTag, StateN = #ch{consumer_mapping = CMap}) ->
1755-
case queue_down_consumer_action(CTag, CMap) of
1756-
remove ->
1757-
cancel_consumer(CTag, QName, StateN);
1758-
{recover, {NoAck, ConsumerPrefetch, Exclusive, Args}} ->
1759-
case catch basic_consume(
1760-
QName, NoAck, ConsumerPrefetch, CTag,
1761-
Exclusive, Args, true, StateN) of
1762-
{ok, StateN1} ->
1763-
StateN1;
1764-
_Err ->
1765-
cancel_consumer(CTag, QName, StateN)
1766-
end
1767-
end
1755+
cancel_consumer(CTag, QName, StateN)
17681756
end, State#ch{queue_consumers = maps:remove(QName, QCons)}, ConsumerTags).
17691757

17701758
%% [0] There is a slight danger here that if a queue is deleted and
@@ -1787,13 +1775,6 @@ cancel_consumer(CTag, QName,
17871775
{queue, QName}]),
17881776
State#ch{consumer_mapping = maps:remove(CTag, CMap)}.
17891777

1790-
queue_down_consumer_action(CTag, CMap) ->
1791-
{_, {_, _, _, Args} = ConsumeSpec} = maps:get(CTag, CMap),
1792-
case rabbit_misc:table_lookup(Args, <<"x-cancel-on-ha-failover">>) of
1793-
{bool, true} -> remove;
1794-
_ -> {recover, ConsumeSpec}
1795-
end.
1796-
17971778
binding_action_with_checks(
17981779
Action, SourceNameBin0, DestinationType, DestinationNameBin0,
17991780
RoutingKey, Arguments, VHostPath, ConnPid, AuthzContext,

0 commit comments

Comments
 (0)