diff options
| author | Matthias Radestock <matthias@rabbitmq.com> | 2013-05-20 13:46:48 +0100 |
|---|---|---|
| committer | Matthias Radestock <matthias@rabbitmq.com> | 2013-05-20 13:46:48 +0100 |
| commit | 040a6ffbff8d2d38fde6bec97615510907ef5dbd (patch) | |
| tree | ed6dea4a2462c5ded316e304bca0160804a4b812 /src | |
| parent | 06946547e1c48da955faf01a10bed62ea221cad1 (diff) | |
| parent | 47b44d3b0d073d5f5600643fbeb58ce0fa9f89bc (diff) | |
| download | rabbitmq-server-git-040a6ffbff8d2d38fde6bec97615510907ef5dbd.tar.gz | |
merge stable into default
Diffstat (limited to 'src')
| -rw-r--r-- | src/rabbit_autoheal.erl | 9 | ||||
| -rw-r--r-- | src/rabbit_channel.erl | 5 |
2 files changed, 5 insertions, 9 deletions
diff --git a/src/rabbit_autoheal.erl b/src/rabbit_autoheal.erl index c00c2dd6e0..529d46b45a 100644 --- a/src/rabbit_autoheal.erl +++ b/src/rabbit_autoheal.erl @@ -39,13 +39,8 @@ %% To coordinate the restarting nodes we pick a special node from the %% winning partition - the "winner". Restarting nodes then stop, tell %% the winner they have done so, and wait for it to tell them it is -%% safe to start again. -%% -%% The winner and the leader are not necessarily the same node! Since -%% the leader may end up restarting, we also make sure that it does -%% not announce its decision (and thus cue other nodes to restart) -%% until it has seen a request from every node that has experienced a -%% partition. +%% safe to start again. The winner and the leader are not necessarily +%% the same node. %% %% Possible states: %% 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})}; |
