Suppose I have an application A that depends on mnesia with a disk layout present. What I would do is make sure that mnesia works and allows a table disc_copies
of A . I am also considering a case where multiple applications must have access to mnesia.
What would be the most portable (and standard) way to achieve this kind of thing, without hard coding mnesia startup and creating a circuit in application callback module A ?
With interactive development, I just do
mnesia:create_schema([node()]).
inside the Erlang shell to initialize the schema on disk, then run the mnesia application using
mnesia:start().
and finally, launch others that depend on the database present.
source
share