Building it yourself - Client Samples


Getting started
Identifying the directory structure
Rebuilding the Client Samples

Getting started

Make a backup copy of the directory before attempting to modify or rebuild the Samples. Create a zip file of the samples directory. You can restore the samples directory to its original state by extracting the zip file.

Before executing commands in the sections that follow, make sure is in your PATH.

Identifying the directory structure of the Samples build

Locate the Samples in the following directories:

src" Contains the Sample source code for the Client Samples.
lib" Contains the Web archive (WAR) files, Java archive (JAR) files, and Enterprise archive (EAR) files for the Samples.
javadoc" Contains the Javadoc documentation generated when the Samples build.
docs" Contains detailed documentation for each Sample.
bin" Contains any script or batch programs for the Samples. These files do not need to be built or compiled.
bld" Contains the generated class files. These class files are used to generate the .jar, .war, or .ear files.

Rebuilding the Client Samples

The Samples automatically install with the WebSphere Application Server Client. You do not have to build the Samples before using them. The directions that follow describe the steps to rebuild the Samples, along with additional information for modifying them.

Executing the Samples build script

To rebuild any of the Client Samples, change to the directory for the particular client sample. For example:

To rebuild the Samples, change to the directory of the Sample you want to rebuild:

The buildClientSamples.bat script is located in the directory. The script sets the appropriate classpath information and executes the Ant 1.4 build utility. Ant reads the build.xml files, which describe how to build the Samples. Refer to the Jakarta Web site for additional documentation on Ant 1.4.

Removing and reinstalling the EAR file

All of the Samples are ready to run once they finish building. Installation is not necessary.

Several Samples communicate to a related server-based Sample and contain some deployment information, including RMI stub information contained in the EJB JAR files. To update any of these server interfaces, follow the instructions in the WebSphere Application Server Samples Gallery. Copy the updated JAR files to the appropriate directory, where they can be reincorporated into the Samples build process.