| JSF Car Store Sample Application |
JSF Car Store Sample Application
This document describes how to use the the JavaServer Faces (JSF) car store sample application with Sun Java System Web Server.This document contains the following sections:
- Overview
- Compiling and Assembling the Application
- Deploying the Sample Application
- Running the Sample Application
- Undeploying the Sample Application
Overview
This sample application demonstrates how to use an online car store that is localized in American English, French, German, and Latin American Spanish. This example is a proof-of-concept application which demonstrates that JavaServer Faces technology can be used to build industrial-strength web applications. It is not intended to be representative of best practices for web application design.
Compiling and Assembling the Application
To compile and assemble the sample application, complete the following steps:
- Compile and assemble the WAR file by changing to the source directory at install_root/samples/java/webapps/jsf/carstore/src and running the ant command.
- The default target default is executed to build the WAR file.
Note - Make sure that the necessary parameters for running the samples are specified in the install_root/samples/java/webapps/common.properties.
- Deploy the application.
- After you have re-created the sample application from scratch, you can proceed to Deploying the Sample Application.
- (Optional.) Clean the web application project area.
- # ant clean
This removes the assemble and build directories for the sample application. The WAR file is now ready for deployment.
Deploying the Sample Application
To deploy the sample application, complete the following steps:If you want to verify registration of the application, proceed to Verifying Deployment. Otherwise, proceed to Running the Sample Application.
- Change to the source directory at install_root/samples/java/webapps/jsf/carstore/src.
- Run the ant tool using the deploy task.
To verify the registration and deployment of the application, complete the following steps:
Change to the source directory at install_root/samples/java/webapps/jsf/carstore/src.
Run the ant tool using the list_apps task.
# ant list_apps
The jsf-carstore module is listed as one of the components.
Running the Sample Application
You can run the application through the following URL:http://Sun_Java_System_Web_Server_hostname:port/jsf-carstore
Undeploying the Sample Application
After successfully deploying and running the application, you might decide to undeploy it and remove the files. To undeploy the application, complete the following steps:
Change to the source directory at install_root/samples/java/webapps/jsf/carstore/src.
Run the ant tool using the undeploy task.
Copyright © 2007 Sun Microsystems, Inc. All rights reserved.