summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAlexandru Scvortov <alexandru@rabbitmq.com>2012-02-16 19:10:30 +0000
committerAlexandru Scvortov <alexandru@rabbitmq.com>2012-02-16 19:10:30 +0000
commit4fc59f32b9ec02ae6f5bd8a22b31ad1e08cff76e (patch)
tree803cd9f1565bf1c76059a1ff67fbcc9a31c1caa6 /src
parent36498d8ea29cf6dd6fd9b295b7a0ebc62349fdd7 (diff)
downloadrabbitmq-server-git-4fc59f32b9ec02ae6f5bd8a22b31ad1e08cff76e.tar.gz
warn when messages are lost
When a DLQ dies, the messages published to it are confirmed, after warning the user. The alternative would be to put the messages back on the queue, but that would be a bit surprising.
Diffstat (limited to 'src')
-rw-r--r--src/rabbit_amqqueue_process.erl2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/rabbit_amqqueue_process.erl b/src/rabbit_amqqueue_process.erl
index 4eecb3bbc1..7d6e41f2f7 100644
--- a/src/rabbit_amqqueue_process.erl
+++ b/src/rabbit_amqqueue_process.erl
@@ -794,6 +794,8 @@ handle_queue_down(QPid, State = #q{queue_monitors = QMons,
none ->
noreply(State);
{value, MsgSeqNosSet} ->
+ rabbit_log:warning("Dead queue lost ~p messages~n",
+ [gb_sets:size(MsgSeqNosSet)]),
handle_confirm(gb_sets:to_list(MsgSeqNosSet), QPid,
State#q{queue_monitors =
dict:erase(QPid, QMons)})