mirror of
https://github.com/UzixLS/migresia.git
synced 2025-07-19 07:11:28 +03:00
Changing name back to list_nodes
This commit is contained in:
@ -24,7 +24,7 @@
|
|||||||
|
|
||||||
-module(migresia).
|
-module(migresia).
|
||||||
|
|
||||||
-export([create_new_migration/2, check/1, migrate/1, list_disc_copy_nodes/0]).
|
-export([create_new_migration/2, check/1, migrate/1, list_nodes/0]).
|
||||||
|
|
||||||
-define(TABLE, schema_migrations).
|
-define(TABLE, schema_migrations).
|
||||||
|
|
||||||
@ -82,7 +82,7 @@ start_mnesia(RemoteToo) ->
|
|||||||
ok ->
|
ok ->
|
||||||
case RemoteToo of
|
case RemoteToo of
|
||||||
false -> ok;
|
false -> ok;
|
||||||
true -> {ResultList, BadNodes} = rpc:multicall(list_disc_copy_nodes(), application, ensure_started, [mnesia]),
|
true -> {ResultList, BadNodes} = rpc:multicall(list_nodes(), application, ensure_started, [mnesia]),
|
||||||
BadStatuses = [X || X <- ResultList, X /= ok],
|
BadStatuses = [X || X <- ResultList, X /= ok],
|
||||||
if BadNodes /= [] -> io:format(" => Error:~p~n", [not_all_nodes_running]), {error, not_all_nodes_running};
|
if BadNodes /= [] -> io:format(" => Error:~p~n", [not_all_nodes_running]), {error, not_all_nodes_running};
|
||||||
BadStatuses /= [] -> io:format(" => Error:~p~n", [BadStatuses]), {error, BadStatuses};
|
BadStatuses /= [] -> io:format(" => Error:~p~n", [BadStatuses]), {error, BadStatuses};
|
||||||
@ -91,5 +91,5 @@ start_mnesia(RemoteToo) ->
|
|||||||
end
|
end
|
||||||
end.
|
end.
|
||||||
|
|
||||||
list_disc_copy_nodes() ->
|
list_nodes() ->
|
||||||
mnesia:table_info(schema, disc_copies).
|
mnesia:table_info(schema, disc_copies).
|
Reference in New Issue
Block a user