Framework launcher in Package:Org.ofbiz.base.start
Entrance is: main method of Start.java
Start.java Launcher Content:
|
Steps |
Details |
|
Into the compared with his test |
help/status/shutdown/ or execute a command |
|
Load configuration |
from environment variable ofbiz.system.props
Get configuration files from the command org/ofbiz/base/start/" +  command + ". Properties
about configuration and variable loading, focusing on /framework/start/src/org/ofbiz/base/start/ Config.java readconfig (string config) |
|
Initializing the classpath load class library |
List of class libraries see Config.java initclasspath () and readconfig () |
|
Initialize the log folder |
- |
|
Creating a listener thread |
Start the socket server, listen for 0 ports (see ofbiz.admin.port properties, Start.properties or other) |
|
Join addshutdownhook to runtime |
Trigger on exit, do graceful exit |
|
Initialize startloaders |
Create a list of initiator instances, most of which are Containerloader an element, and in some cases splashloader.
Start.java , initstartloaders (), Containerloader.java , load (), Loadcontainer ()
Componentcontainer.java, init ()->loadcomponents ()->loadcomponentfromconfig () Loadcomponentdirectory ()
->file configfile = fileutil.getfile (componentlocation + "/ofbiz-component.xml");-> loop call LoadComponent () add the module's jar package to classpath
Where Componentconfig.java is the parsing of the XML file in java .
|
|
Start () of Start ()->startuploader, Start () of the container |
Container list defaults from framework/base/config/ofbiz-containers.xml |
Start Entrance Start.java analysis