Adding User-specific JAR and ZIP Files to the Workstation Classpath
When using lwork with a data directory that is separate from the ldt install directory (also known as LISA_HOME), JAR and ZIP files can be added in the lib folder of the data directory. These are added to the end of the Workstation's classpath. This is helpful when you do not have write access to the LISA_HOME\lib directory and there are third-party libraries or custom code that you want to make accessible to lwork.
DevTest Workstationwith a data directory that is separate from the
DevTestinstall directory (also known as LISA_HOME), JAR and ZIP files can be added in the lib folder of the data directory. These are added to the end of the Workstation's classpath. This is helpful when you do not have write access to the LISA_HOME\lib directory and there are third-party libraries or custom code that you want to make accessible to
The LISA_HOME\bin directory contains the following scripts that set the LISA_POST_CLASSPATH environment variable of the current terminal session to a classpath string containing all the JAR and ZIP files that are located in the lib folder of the data directory:
- updateUserPostClasspathEnv.bat (Windows)
- updateUserPostClasspathEnv.sh (Mac OS, UNIX)
Before executing these scripts, set the LISA_HOME environment variable to the location of your
DevTestinstallation. The default location for
- C:\Program Files\CA\DevTest (Windows)
- /opt/CA/DevTest (Mac OS, UNIX)
Export Environment Variables on Mac OS and UNIX
When using the updateUserPostClasspathEnv.sh UNIX shell script, run it with the source command (or the "." alias) so that the LISA_POST_CLASSPATH variable is exported from the script into the current session. Here is an example of running the script, exporting the environment variable, and launching
cd $LISA_HOME/binsource ./updateUserPostClasspathEnv.sh./Workstation
Export Environment Variables on Windows
Using a command prompt:
cd LISA_HOME/binupdateUserPostClasspathEnv.bat Workstation.exe
cd LISA_HOME/bin.\updateUserPostClasspathEnv.bat .\Workstation.exe
When the LISA_POST_CLASSPATH environment variable has been set by the script, launch
DevTest Workstationfrom the same terminal session. Any classes from the JAR and ZIP files from the lib directory will be accessible.
LISA_POST_CLASSPATH Environment Variable Scope
DevTest Workstationto be aware of JAR and ZIP files from the lib folder of the data directory, the LISA_POST_CLASSPATH environment variable must be set in the same environment that
DevTest Workstationis running in. If the LISA_POST_CLASSPATH environment variable has only been set in the current terminal session by the updateUserPostClasspathEnv script, then
DevTest Workstationmust be run from the same terminal session.
If new JAR or ZIP files have been added to the lib folder of the directory data changes since the LISA_POST_CLASSPATH environment variable was set, then you must run the updateUserPostClasspathEnv again.
If you do not want to run the updateUserPostClasspathEnv script every time before running
DevTest Workstationin a terminal session, you can use the output of the script to help you set the LISA_POST_CLASSPATH environment variable at the system or user level for your operating system. Setting the LISA_POST_CLASSPATH environment variable at the system or user level causes all new instances of
DevTest Workstationto use it unless it has been overwritten at the terminal session level.