diff options
author | Hubert Plociniczak <hubert@lshift.net> | 2008-09-11 17:33:43 +0100 |
---|---|---|
committer | Hubert Plociniczak <hubert@lshift.net> | 2008-09-11 17:33:43 +0100 |
commit | 03715ed3ca7374af437b277815e6a1953e90233d (patch) | |
tree | 388c38d4e5179f8fb6f940ff155eb215fd6f1fe0 | |
parent | 3a7ab39ddeea3cc9f2bc9f3d1bfdb79387f88e24 (diff) | |
download | rabbitmq-server-03715ed3ca7374af437b277815e6a1953e90233d.tar.gz |
Use parse_status to correctly determine
the status of the node. No need to print node's apps.
-rw-r--r-- | src/rabbit_multi.erl | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/rabbit_multi.erl b/src/rabbit_multi.erl index 9373e8cb..2ff59dc8 100644 --- a/src/rabbit_multi.erl +++ b/src/rabbit_multi.erl @@ -94,9 +94,10 @@ action(status, [], RpcTimeout) -> call_all_nodes( fun({Node, Pid}) -> io:format("Node '~p' with Pid ~p: ", [Node, Pid]), - case rpc:call(Node, rabbit, status, [], RpcTimeout) of - {badrpc, Error} -> io:format("~p~n", [Error]); - [{running_applications, Apps} | _] -> io:format("~p~n", [Apps]) + case parse_status( + rpc:call(Node, rabbit, status, [], RpcTimeout)) of + false -> io:format("~p~n", ["not running"]); + true -> io:format("~p~n", ["running"]) end end); |