diff options
| author | kjnilsson <knilsson@pivotal.io> | 2019-04-11 17:47:55 +0100 |
|---|---|---|
| committer | kjnilsson <knilsson@pivotal.io> | 2019-04-11 17:47:55 +0100 |
| commit | fa3cad4ee15b04f1564e11bdb94d9685e627f800 (patch) | |
| tree | ba45eb09afa57cc2473829b65cd1ecc96ba966fa | |
| parent | 96b9fb0f5cf6e563203e4b71af3a636cb3e95bfb (diff) | |
| download | rabbitmq-server-git-fa3cad4ee15b04f1564e11bdb94d9685e627f800.tar.gz | |
Fix tests by make quorum queue discovery defensive
| -rw-r--r-- | src/rabbit_vm.erl | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/rabbit_vm.erl b/src/rabbit_vm.erl index 34ba6bc111..702d96c7dc 100644 --- a/src/rabbit_vm.erl +++ b/src/rabbit_vm.erl @@ -183,7 +183,13 @@ queue_sups() -> quorum_sups() -> %% TODO: in the future not all ra servers may be queues and we needs %% some way to filter this - [Pid || {_, Pid, _, _} <- supervisor:which_children(ra_server_sup_sup)]. + case whereis(ra_server_sup_sup) of + undefined -> + []; + _ -> + [Pid || {_, Pid, _, _} <- + supervisor:which_children(ra_server_sup_sup)] + end. msg_stores() -> all_vhosts_children(msg_store_transient) |
