Skip to content

Commit 37ec060

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

File tree

3 files changed

+2
-23
lines changed

3 files changed

+2
-23
lines changed

deps/rabbit/src/rabbit_amqqueue.erl

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -877,7 +877,6 @@ declare_args() ->
877877
{<<"x-queue-leader-locator">>, fun check_queue_leader_locator_arg/2}].
878878

879879
consume_args() -> [{<<"x-priority">>, fun check_int_arg/2},
880-
{<<"x-cancel-on-ha-failover">>, fun check_bool_arg/2},
881880
{<<"x-stream-offset">>, fun check_stream_offset_arg/2}].
882881

883882
check_int_arg({Type, _}, _) ->

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,

deps/rabbit/src/rabbit_classic_queue.erl

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -511,8 +511,7 @@ capabilities() ->
511511
<<"x-overflow">>, <<"x-queue-mode">>, <<"x-queue-version">>,
512512
<<"x-single-active-consumer">>, <<"x-queue-type">>,
513513
<<"x-queue-master-locator">>],
514-
consumer_arguments => [<<"x-cancel-on-ha-failover">>,
515-
<<"x-priority">>, <<"x-credit">>],
514+
consumer_arguments => [<<"x-priority">>, <<"x-credit">>],
516515
server_named => true}.
517516

518517
notify_decorators(Q) when ?is_amqqueue(Q) ->

0 commit comments

Comments
 (0)