Q

Default folder in WebSphere

I'm using VAJ and the IBM Websphere test Environment for testing. The system requires a property file to be loaded in when a servlet starts in order to resolve all system specific values. (i.e. IP addresses of machine, LDAP servers, etc). This allows for ease of portability when deploying onto various platforms. When I run the application via the Servlet Launcher, the class called to load in the properties file throws an exception indicating...

that the properties file can not be found. The class that loads the properties file does not have a hard codes path. (ie. The code just looks for .properties). I have located the default folder on our iSeries box, but I cannot located the default folder in the WebSphere test Environment. Do you know where the default directory is located or where to set the default directory location when testing programs in the WebSphere test environment of Visual Age for Java?

Don Yantzi, one of our VisualAge for Java developers, provided the following:

The "default" folder you are mentioning for the WebSphere Test Environment is the resource directory for the VisualAge for Java project which contains your servlet. For example, if your servlet are in a VisualAge for Java project called "Intranet Application" then you would put the .properties files in the directory <vajava install>ideproject_resourcesintranet application , where <vajava install> is the directory where VisualAge For Java is installed. If you are using WebSphere Development Tools for AS/400 this would be c:wdt400vajava by default.

Background information: You setup the CLASSPATH for the WebSphere test environment by specifying other VisualAge for Java projects that contain your servlets, JavaBeans, etc... In VisualAge for Java 3.02 this is done by setting the CLASSPATH for the Servlet Launcher class. In version 3.5 this is performed via the WebSphere Test Environment Control Center. Adding a VisualAge for Java project to the CLASSPATH automatically adds its associated project resources directory. The Java Virtual Machine (JVM) uses the CLASSPATH to locate .properties files.


This was first published in April 2001
This Content Component encountered an error

Have a question for an expert?

Please add a title for your question

Get answers from a TechTarget expert on whatever's puzzling you.

You will be able to add details on the next page.

0 comments

Oldest 

Forgot Password?

No problem! Submit your e-mail address below. We'll send you an email containing your password.

Your password has been sent to:

-ADS BY GOOGLE

SearchEnterpriseLinux

SearchDataCenter

Close