Sun Java Solaris Communities My SDN Account Join SDN
 
Java Pet Store Demo 1.3.1

Java Pet Store Demo 1.3.1 > Enabling WebServices in the Demo

 

Enabling Web-services in the Demo

This section describes how to enable the Web-services feature of the Java Pet Store Demo. You must have first installed the basic version of the demo as described here.

System Requirements

You need to download and install the following additional software: 

Required Environment Variables

You need to set an additional environment variable: 

    JWSDP_HOME must point to the root directory of your Java Web Services Developer Pack (JWSDP) installation. For example, if you installed the JWSDP in /usr/local/java/jwsdp1.0, then that path should be the value of JWSDP_HOME. We will refer to this path as <jwsdp.home> in the rest of the document. 

Installing the Demo

To install the demo with the webservices features enabled, follow these steps:

Run the script to integrate webservice technologies into J2EE

If you are using Unix, open a shell prompt and enter these commands:

cd <jwsdp.home>/bin
sh jwsdponj2ee.sh $J2EE_HOME
If you are using Windows, open a command prompt and enter these commands:
cd <jwsdp.home>\bin
jwsdponj2ee.bat %J2EE_HOME%

Start the Cloudscape database.

If you are using Unix, open a shell prompt and enter these commands:

cd $J2EE_HOME/bin
cloudscape -start
If you are using Windows, open a command prompt and enter these commands:
cd %J2EE_HOME%\bin
cloudscape.bat -start
Start the J2EE server.

If you are using Unix, open a shell prompt and enter these commands:

cd $J2EE_HOME/bin
j2ee -verbose
If you are using Windows, open a command prompt and enter these commands:
cd %J2EE_HOME%\bin
j2ee.bat -verbose
    Change directory to the Web-services enabled petstore.

    If you are using Unix, open a shell prompt and enter these commands:

    cd <petstore.home>/webservices
    If you are using Windows, open a command prompt and enter these commands:
    cd <petstore.home>\webservices
    Run the setup script to deploy the applications.

    If you are using Unix, open a shell prompt and enter these commands:

    sh setup.sh deploy
    If you are using Windows, open a command prompt and enter these commands:
    setup.bat deploy
After installing the demo, you can start using it .

For information on what changes were made to WebService-enable the Java PetStore Demo application, click here.