diff options
| author | Michael Klishin <michael@clojurewerkz.org> | 2018-03-16 08:20:21 +0300 |
|---|---|---|
| committer | Michael Klishin <michael@clojurewerkz.org> | 2018-03-16 08:20:21 +0300 |
| commit | 1ef32474b0bd414e157411df17744f5fc7e3e5a6 (patch) | |
| tree | b38e61d512743d26c5c519c182a0322e33084612 | |
| parent | a4cb92a27dd93903417e2de59abb9bb9dff77571 (diff) | |
| download | rabbitmq-server-git-1ef32474b0bd414e157411df17744f5fc7e3e5a6.tar.gz | |
Include current node to the to-start list
| -rw-r--r-- | src/rabbit_vhost_sup_sup.erl | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/rabbit_vhost_sup_sup.erl b/src/rabbit_vhost_sup_sup.erl index 993f1d8430..e036a82e64 100644 --- a/src/rabbit_vhost_sup_sup.erl +++ b/src/rabbit_vhost_sup_sup.erl @@ -60,10 +60,10 @@ init([]) -> [rabbit_vhost_sup_wrapper, rabbit_vhost_sup]}]}}. start_on_all_nodes(VHost) -> - NodesStart = [ {Node, start_vhost(VHost, Node)} - || Node <- rabbit_nodes:all_running(), - %% Do not try to start a vhost on booting nodes. - rabbit:is_booted(Node) ], + %% Do not try to start a vhost on booting peer nodes + AllBooted = [Node || Node <- rabbit_nodes:all_running(), rabbit:is_booted(Node)], + Nodes = [node() | AllBooted], + NodesStarted = [{Node, start_vhost(VHost, Node)} || Node <- Nodes], Failures = lists:filter(fun ({_, {ok, _}}) -> false; ({_, {error, {already_started, _}}}) -> false; |
