From 0683c4cdedd30b633733b313494c27c0adade4b6 Mon Sep 17 00:00:00 2001 From: Raz Luvaton <16746759+rluvaton@users.noreply.github.com> Date: Tue, 30 Jan 2024 18:52:48 +0200 Subject: [PATCH 1/2] add consumer tag and queue name in the ack timeout warning message --- deps/rabbit/src/rabbit_channel.erl | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/deps/rabbit/src/rabbit_channel.erl b/deps/rabbit/src/rabbit_channel.erl index 2df695a6e7a6..f96e4c1a2701 100644 --- a/deps/rabbit/src/rabbit_channel.erl +++ b/deps/rabbit/src/rabbit_channel.erl @@ -2780,13 +2780,15 @@ evaluate_consumer_timeout1(PA = #pending_ack{delivered_at = Time}, {noreply, State} end. -handle_consumer_timed_out(Timeout,#pending_ack{delivery_tag = DeliveryTag}, +handle_consumer_timed_out(Timeout,#pending_ack{delivery_tag = DeliveryTag, tag = ConsumerTag, queue = QName}, State = #ch{cfg = #conf{channel = Channel}}) -> - rabbit_log_channel:warning("Consumer ~ts on channel ~w has timed out " - "waiting for delivery acknowledgement. Timeout used: ~tp ms. " + rabbit_log_channel:warning("Consumer '~ts' on channel ~w and ~ts has timed out " + "waiting for ~ts delivery acknowledgement. Timeout used: ~tp ms. " "This timeout value can be configured, see consumers doc guide to learn more", - [rabbit_data_coercion:to_binary(DeliveryTag), - Channel, Timeout]), + [ConsumerTag, + Channel, + rabbit_misc:rs(QName), + rabbit_data_coercion:to_binary(DeliveryTag), Timeout]), Ex = rabbit_misc:amqp_error(precondition_failed, "delivery acknowledgement on channel ~w timed out. " "Timeout value used: ~tp ms. " From a188fbc44dfb12f9823ac85621dbb6c8880fffe0 Mon Sep 17 00:00:00 2001 From: Michael Klishin Date: Tue, 30 Jan 2024 23:07:22 -0500 Subject: [PATCH 2/2] Log message wording for #10444 --- deps/rabbit/src/rabbit_channel.erl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/deps/rabbit/src/rabbit_channel.erl b/deps/rabbit/src/rabbit_channel.erl index f96e4c1a2701..c30e4f32f7ce 100644 --- a/deps/rabbit/src/rabbit_channel.erl +++ b/deps/rabbit/src/rabbit_channel.erl @@ -2783,12 +2783,12 @@ evaluate_consumer_timeout1(PA = #pending_ack{delivered_at = Time}, handle_consumer_timed_out(Timeout,#pending_ack{delivery_tag = DeliveryTag, tag = ConsumerTag, queue = QName}, State = #ch{cfg = #conf{channel = Channel}}) -> rabbit_log_channel:warning("Consumer '~ts' on channel ~w and ~ts has timed out " - "waiting for ~ts delivery acknowledgement. Timeout used: ~tp ms. " + "waiting for a consumer acknowledgement of a delivery with delivery tag = ~b. Timeout used: ~tp ms. " "This timeout value can be configured, see consumers doc guide to learn more", [ConsumerTag, Channel, rabbit_misc:rs(QName), - rabbit_data_coercion:to_binary(DeliveryTag), Timeout]), + DeliveryTag, Timeout]), Ex = rabbit_misc:amqp_error(precondition_failed, "delivery acknowledgement on channel ~w timed out. " "Timeout value used: ~tp ms. "