mirror of
https://github.com/processone/ejabberd.git
synced 2024-09-27 14:30:55 +02:00
Log Mnesia table type on creation
This commit is contained in:
parent
533a4eec96
commit
56b4d3902a
@ -258,7 +258,13 @@ validator() ->
|
|||||||
[unique]).
|
[unique]).
|
||||||
|
|
||||||
create(Name, TabDef) ->
|
create(Name, TabDef) ->
|
||||||
?INFO_MSG("Creating Mnesia table '~s'", [Name]),
|
Type = lists:foldl(
|
||||||
|
fun({ram_copies, _}, _) -> " ram ";
|
||||||
|
({disc_copies, _}, _) -> " disc ";
|
||||||
|
({disc_only_copies, _}, _) -> " disc_only ";
|
||||||
|
(_, Acc) -> Acc
|
||||||
|
end, " ", TabDef),
|
||||||
|
?INFO_MSG("Creating Mnesia~stable '~s'", [Type, Name]),
|
||||||
case mnesia_op(create_table, [Name, TabDef]) of
|
case mnesia_op(create_table, [Name, TabDef]) of
|
||||||
{atomic, ok} ->
|
{atomic, ok} ->
|
||||||
add_table_copy(Name);
|
add_table_copy(Name);
|
||||||
|
Loading…
Reference in New Issue
Block a user