Sample applications that you can examine and deploy to the Enterprise Server are available. If you installed the Enterprise Server as part of installing the Java EE 5 SDK bundle from Java EE 5 Downloads, the samples may already be installed. You can download these samples separately from the Code Samples page if you installed the Enterprise Server without them initially.
Most Enterprise Server samples have the following directory structure:
The docs directory contains instructions for how to use the sample.
The build.xml file defines asant targets for the sample. See Chapter 3, The asant Utility.
The src/java directory under each component contains source code for the sample.
The src/conf directory under each component contains the deployment descriptors.
With a few exceptions, sample applications follow the standard directory structure described here: http://java.sun.com/blueprints/code/projectconventions.html.
The samples-install-dir/bp-project/main.xml file defines properties common to all sample applications and implements targets needed to compile, assemble, deploy, and undeploy sample applications. In most sample applications, the build.xml file imports main.xml.
In addition to the Java EE 5 sample applications, samples are also available on the GlassFish web site at https://glassfish-samples.dev.java.net/.