diff options
| author | Simon MacMullen <simon@rabbitmq.com> | 2013-05-20 12:23:11 +0100 |
|---|---|---|
| committer | Simon MacMullen <simon@rabbitmq.com> | 2013-05-20 12:23:11 +0100 |
| commit | b7df1b1e014eb2e46d7e5b40831ac20b9264c818 (patch) | |
| tree | 288cea864544d5a0e68c72ad90d0da5a3d3711e0 /src | |
| parent | 97494a765a8bef90b202357f04d96e4b39cc255e (diff) | |
| download | rabbitmq-server-git-b7df1b1e014eb2e46d7e5b40831ac20b9264c818.tar.gz | |
Pass through tx'ed acks and rejects in the correct order.
Diffstat (limited to 'src')
| -rw-r--r-- | src/rabbit_channel.erl | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/rabbit_channel.erl b/src/rabbit_channel.erl index 37041d346e..1de14b5ce4 100644 --- a/src/rabbit_channel.erl +++ b/src/rabbit_channel.erl @@ -1085,8 +1085,9 @@ handle_method(#'tx.commit'{}, _, #ch{tx = none}) -> handle_method(#'tx.commit'{}, _, State = #ch{tx = {Msgs, Acks}, limiter = Limiter}) -> State1 = rabbit_misc:queue_fold(fun deliver_to_queues/2, State, Msgs), - lists:foreach(fun ({ack, A}) -> ack(A, State1); - ({Requeue, A}) -> reject(Requeue, A, Limiter) + Rev = fun (X) -> lists:reverse(lists:sort(X)) end, + lists:foreach(fun ({ack, A}) -> ack(Rev(A), State1); + ({Requeue, A}) -> reject(Requeue, Rev(A), Limiter) end, lists:reverse(Acks)), {noreply, maybe_complete_tx(State1#ch{tx = committing})}; |
