Java runtime CLASSPATH

The Java CLASSPATH is an environment variable containing a list of resources (for example: Java class files, JAR and ZIP archive files) used during program execution. Within the OFBiz environment, the CLASSPATH may become quite complex with hundreds of entries. Therefore, it is comforting to know that OFBiz makes it easy for us to manipulate the CLASSPATH and add new resources.

How to do it...

Resources can be added to the runtime CLASSPATH by following these steps:

  1. Put that resource in any directory that is already listed in the CLASSPATH. Examples of default CLASSPATH directory locations include:
    ~framework/base/lib
    

    or

    ~framework/webapp/lib
    

    (Where "~" represents the fully qualified directory path of the OFBiz installation root location.)

  2. Restart OFBiz.

How it works...

OFBiz bootstraps itself by loading Java class files for execution based on initial CLASSPATH entries. As it starts up, it traverses each Component, building out the CLASSPATH and dynamically loading necessary class files based on the established Component directory layout and on each Component's ofbiz-component.xml file. By placing a new class or JAR file in an existing CLASSPATH directory, OFBiz will find and load the resource automatically as part of the normal startup process.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.144.252.204