Merge pull request #13120 from ieQu1/dev/ds-api-site-status

fix(dsapi): Check status of the node via Mria
This commit is contained in:
zmstone 2024-05-25 05:42:05 +02:00 committed by GitHub
commit b2f5e50f16
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 1 deletions

View File

@ -307,7 +307,7 @@ get_site(get, #{bindings := #{site := Site}}) ->
?NOT_FOUND(<<"Site not found: ", Site/binary>>);
true ->
Node = emqx_ds_replication_layer_meta:node(Site),
IsUp = lists:member(Node, [node() | nodes()]),
IsUp = mria:cluster_status(Node) =:= running,
Shards = shards_of_site(Site),
?OK(#{
node => Node,