summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Radestock <matthias@rabbitmq.com>2011-07-06 17:40:37 +0100
committerMatthias Radestock <matthias@rabbitmq.com>2011-07-06 17:40:37 +0100
commit8f136d8ead5b9a9ce9bea51eb1535dee065227ad (patch)
tree59e8e5ecb8f176a0d935ee314bec9f07b2a127e5
parent8f8faabe84201fb68c4644b37ac7de498f3f0d39 (diff)
downloadrabbitmq-server-8f136d8ead5b9a9ce9bea51eb1535dee065227ad.tar.gz
ditch per-x-q confirm statsbug24216
They don't work properly (see comment in code) and are emitted in a very awkward place. And they expose implementation detail - there is no a priori reason why queues should be involved in confirms - and are of questionable utility.
-rw-r--r--src/rabbit_channel.erl8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/rabbit_channel.erl b/src/rabbit_channel.erl
index 0c211b46..84728980 100644
--- a/src/rabbit_channel.erl
+++ b/src/rabbit_channel.erl
@@ -539,17 +539,13 @@ process_confirms(MsgSeqNos, QPid, Nack, State = #ch{unconfirmed_mq = UMQ,
fun(MsgSeqNo, {_MXs, UMQ0, _UQM} = Acc) ->
case gb_trees:lookup(MsgSeqNo, UMQ0) of
{value, XQ} -> remove_unconfirmed(MsgSeqNo, QPid, XQ,
- Acc, Nack, State);
+ Acc, Nack);
none -> Acc
end
end, {[], UMQ, UQM}, MsgSeqNos),
{MXs, State#ch{unconfirmed_mq = UMQ1, unconfirmed_qm = UQM1}}.
-remove_unconfirmed(MsgSeqNo, QPid, {XName, Qs}, {MXs, UMQ, UQM}, Nack,
- State) ->
- %% these confirms will be emitted even when a queue dies, but that
- %% should be fine, since the queue stats get erased immediately
- maybe_incr_stats([{{QPid, XName}, 1}], confirm, State),
+remove_unconfirmed(MsgSeqNo, QPid, {XName, Qs}, {MXs, UMQ, UQM}, Nack) ->
UQM1 = case gb_trees:lookup(QPid, UQM) of
{value, MsgSeqNos} ->
MsgSeqNos1 = gb_sets:delete(MsgSeqNo, MsgSeqNos),