HELLO WORLD (SOAP OVER HTTP) $SUBSTITUTE_NAME_UPPER$ J2EE DEMO
============================================

This demo shows how to connect with an $SUBSTITUTE_NAME$ Web service using a
servlet deployed in an application server.


Running the Demo
================

To run this demo application:

    . Set JBoss environment
    . Set $SUBSTITUTE_NAME_UPPER$ environment
    . Build $SUBSTITUTE_NAME_UPPER$ J2EE Connector rar file
    . Launch the application server
    . Deploy the $SUBSTITUTE_NAME_UPPER$ J2EE Connector 
    . Build the demo
    . Deploy the web application to the application server
    . Launch the $SUBSTITUTE_NAME_UPPER$ Server
    . Accessing the web application 


Set JBoss environment
=====================
 (Unix) % export JBOSS_HOME=<jboss-home>
 (Windows) > set JBOSS_HOME=<jboss-home>


Set $SUBSTITUTE_NAME_UPPER$ environment
=====================

$SUBSTITUTE_PREREQ$


Build $SUBSTITUTE_NAME_UPPER$ J2EE Connector rar file
=================================
  (Unix)    % ant generate.rar
  (Windows) > ant generate.rar

This target updates the jboss endorsed directory first, then copies the 
following files to the $JBOSS_HOME/lib/endorsed directory:

- activation-1.1.jar
- jaxb-api-2.0.jar
- jaxb-impl-2.0.3.jar
- jaxb-xjc-2.0.3.jar
- stax-api-1.0.1.jar
- jsr181-api-1.0-MR1.jar-
- saaj-api-1.3.jar
- saaj-impl-1.3.jar



Launch the application server
=============================

    The demo requires an application server.  Make sure you have a running 
    instance of an application server. 
   

Deploy the $SUBSTITUTE_NAME$ J2EE Connector
===============================

    You must deploy the $SUBSTITUTE_NAME$ J2EE Connector to the application
    server before running the demo. A single resource adapter deployment is 
    shared by all of the demos, so you need to do this only once.


    How you deploy the $SUBSTITUTE_NAME$ J2EE Connector depends on your 
    application server. Please consult your vendor documentation on connector 
    deployment. Here are basic instructions to deploy the connector in JBoss 
    application servers.

  (Unix)    % ant deploy.cxf.rar
  (Windows) > ant deploy.cxf.rar

Or copy the connector RAR from its location in the $SUBSTITUTE_NAME$ installation to
the JBoss deployment directory.

  Copy connector file to deployment directory.
    (Unix)    % cd $$SUBSTITUTE_HOME$/lib/
              % cp cxf.rar \ 
                 $JBOSS_HOME/server/default/deploy

    (Windows) > cd %$SUBSTITUTE_HOME$%\lib\
              > copy cxf.rar 
                 %JBOSS_HOME%\server\default\deploy

  Copy the cxf_j2ee_1_5-ds.xml file to the JBoss deployment directory.
    (Unix)    % cp ./etc/cxfj2ee_1_5-ds.xml $JBOSS_HOME/server/default/deploy

    (Windows) > copy .\etc\cxfj2ee_1_5-ds.xml 
                   %JBOSS_HOME%\server\default\deploy


Building the Demo
=================

Building the demo requires that there is a JDK available and that the
$SUBSTITUTE_NAME$ environment is correctly set. 

Before building this demo, build common dir first.
  (Unix)    % cd common
            % ant
  (Windows) > cd common
            > ant

The demo may be built from the directory hello_world_soap_http.

Issue the command:

  (Unix)    % ant
  (Windows) > ant


Launch the $SUBSTITUTE_NAME$ Service
========================

Run the $SUBSTITUTE_NAME$ service provided by the hello_world demo.

To launch the service:

1.  Move into the sample/hello_world/ directory.
2.  launch server
    Issue the command: 
  (Unix)    % ant server
  (Windows) > ant server


See hello_world/README.txt file for full details.


Deploying the demo WAR archive
==============================

How to deploy a WAR archive is dependent on your 
application server. Please consult your vendor documentation
on application deployment. Here are basic instructions to deploy
the demo application for JBoss application servers.

  (Unix)    % ant deploy.war
  (Windows) > ant deploy.war

Or copy the WAR archive ./build/lib/helloworld.war 
to the JBoss deployment directory.
  
  (Unix)    % cp ./build/lib/helloworld.war \ 
              $JBOSS_HOME/server/default/deploy
  (Windows) > copy .\build\lib\helloworld.war 
              %JBOSS_HOME%\server\default\deploy


Accessing the web application 
=============================

Using a web browser access the URI below corresponding to your application 
server. (These URI assume that the application server is running in the same 
machine as the web browser)

JBoss
-----
http://localhost:8080/helloworld/*.do


The web application provides a simple Web front-end to the Hello World
Application. 

command-line
------------
You can also run a client in command-line.

  (Unix)    % ant client
  (Windows) > ant client
