diff options
author | Simon MacMullen <simon@rabbitmq.com> | 2012-12-14 13:07:21 +0000 |
---|---|---|
committer | Simon MacMullen <simon@rabbitmq.com> | 2012-12-14 13:07:21 +0000 |
commit | 1db2d04c860e4299b0f0722488f6244f2932113a (patch) | |
tree | e04105d9899544e87eef7351bfe48a2dbbb5a69a /src/rabbit_control_main.erl | |
parent | c52adc5c6768378e2a876ec116e96f70493931c3 (diff) | |
download | rabbitmq-server-1db2d04c860e4299b0f0722488f6244f2932113a.tar.gz |
Cancel sync
Diffstat (limited to 'src/rabbit_control_main.erl')
-rw-r--r-- | src/rabbit_control_main.erl | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/rabbit_control_main.erl b/src/rabbit_control_main.erl index b4272555..12096ff5 100644 --- a/src/rabbit_control_main.erl +++ b/src/rabbit_control_main.erl @@ -51,6 +51,7 @@ {forget_cluster_node, [?OFFLINE_DEF]}, cluster_status, {sync_queue, [?VHOST_DEF]}, + {cancel_sync_queue, [?VHOST_DEF]}, add_user, delete_user, @@ -287,6 +288,12 @@ action(sync_queue, Node, [Queue], Opts, Inform) -> rpc_call(Node, rabbit_amqqueue, sync, [list_to_binary(Queue), list_to_binary(VHost)]); +action(cancel_sync_queue, Node, [Queue], Opts, Inform) -> + VHost = proplists:get_value(?VHOST_OPT, Opts), + Inform("Stopping synchronising queue ~s in ~s", [Queue, VHost]), + rpc_call(Node, rabbit_amqqueue, cancel_sync, + [list_to_binary(Queue), list_to_binary(VHost)]); + action(wait, Node, [PidFile], _Opts, Inform) -> Inform("Waiting for ~p", [Node]), wait_for_application(Node, PidFile, rabbit_and_plugins, Inform); |