diff options
| author | Simon MacMullen <simon@rabbitmq.com> | 2013-11-06 11:39:20 +0000 |
|---|---|---|
| committer | Simon MacMullen <simon@rabbitmq.com> | 2013-11-06 11:39:20 +0000 |
| commit | 902275142718816646ec4bdd4ef20c6b5743a8bd (patch) | |
| tree | 6f641a4ff697c85f0c2e9d96743c3cd1a95af80a | |
| parent | 6712c606f7b35dddc3ca10901abdd02a750a57f9 (diff) | |
| download | rabbitmq-server-git-902275142718816646ec4bdd4ef20c6b5743a8bd.tar.gz | |
Maybe sync on slave promotion.
| -rw-r--r-- | src/rabbit_mirror_queue_misc.erl | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/rabbit_mirror_queue_misc.erl b/src/rabbit_mirror_queue_misc.erl index 8ad7c62fd2..ca36e0db07 100644 --- a/src/rabbit_mirror_queue_misc.erl +++ b/src/rabbit_mirror_queue_misc.erl @@ -94,10 +94,11 @@ remove_from_queue(QueueName, Self, LiveGMPids) -> %% Either master hasn't changed, so %% we're ok to update mnesia; or we have %% become the master. - store_updated_slaves( - Q #amqqueue { pid = QPid1, + Q1 = Q#amqqueue{pid = QPid1, slave_pids = SPids1, - gm_pids = GMPids1 }), + gm_pids = GMPids1}, + store_updated_slaves(Q1), + maybe_auto_sync(Q1), {ok, QPid1, [QPid | SPids] -- Alive}; _ -> %% Master has changed, and we're not it, |
