The APP Utils module
Methods
-
static defaultConfiguration()
-
Initialize application configuration.
-
static loadDefaultComponents()
-
Load default components for application.
-
static optComponents(comps, method, cb)
-
Apply command to loaded components. This method would invoke the component {method} in series. Any component {method} return err, it would return err directly.
Parameters:
Name Type Description compsArray loaded component list methodString component lifecycle method name, such as: start, stop cbfunction -
static startByType()
-
Start servers by type.
-
static stopComps(comps, index, force, cb)
-
Stop components.
Parameters:
Name Type Description compsArray component list indexNumber current component index forceBoolean whether stop component immediately cbfunction