Age | Commit message (Collapse) | Author |
|
|
|
Also use this type in the start/2 callback spec.
|
|
* josevalim/jv-persistent-set-env:
Allow persistent option on set_env/4 and unset_env/3
OTP-11708
|
|
|
|
An environment key set with the persistent option will not
be overridden by the ones configured in the application resource
file on load. This means persistent values will stick after the
application is loaded and also on application reload.
|
|
This adds two new functions to the application module that will
recursively look for missing dependencies to start the entire dependency
chain of a given application, and then the application itself, if
possible.
Its entire behavior is based on the currently existing 'start/1-2'
functions, which will report dependencies that have not yet been started
and other problems encountered. 'ensure_all_started/1-2' will use this
information the way any programmer would manually do it to automate the
process.
This kind of functionality, while not OTP-ish (releases do this start
sequence for the user), is still useful for testing purposes, quick
demonstrations, and programmers who do not wish or know how to use OTP
releases.
The function returns '{ok, StartedApps}' for all started or already
started applications (already started are omitted from the list), and
will return '{error, {AppName, Reason}}' on a failure to allow users to
rapidly know why the function failed.
Note that no specific check is made for direct or indirect circular
dependencies between applications, and these will make the function go
in an infinite loop.
|
|
Similar to application:start/1,2 except it returns 'ok' on already
started applications instead of {'error', {'already_started', ...}}.
|
|
|
|
The new function provides a default value for a configuration
parameter.
|
|
It was possible to insert {Mod::atom(),Vsn::term()} instead of
Mod::atom() in the modules list in a .app file. This was not visible
in the documentation of .app files, but it was visible in the
documentation of application:load/[1,2] (where the .app file term can
be used directly as first argument).
The Vsn part was never used, so this possibility has now been removed.
|
|
|
|
|
|
|
|
|
|
|