================================================================================
                          WSO2 Application Server Samples
================================================================================

Introduction
============
WSO2 Application Server ships with number of samples integrated to illustrate its
functionality and capabilities. This README will provide prerequisites, abstract
of each sample and instructions to run the samples. Following list will give you
the samples which are integrated,

1. HelloWorld -
   This is a simple sample that demonstrates the functionality of the Axis2 services
   deployed as web services in WSO2 Web Service Application Server .

2. HelloWorldWebapp -
   This sample will show how WSO2 Application server supports to deploy a webapp.

3. Chad -
   This sample will create simple web service for voting and a web based client to use
   that web service.

4. TinyURL -
   In this sample the capabilities of WSO2 Application Server to handle both SOAP and
   Representational State Transfer (REST) will be demonstrated.

5. FlickrClient -
    This sample will generate code for a WSDL 2.0 description and invoke a real world
    application RESTfully.

6. VirtualDirectoryListing -
    This sample is to demonstrate how to do virtual directory listing using a tomcat
    webapp.

7. TomcatWebApps -
    a. GenericJavaBeanResource
       This is simple webapp sample to demonstrate JNDI DataSource look-ups in Embedded
       Tomcat for resources defined in webapp contextXml descriptor.

    b. JDBCDataSource
       This is a webapp sample to demonstrate JDBC DataSource lookups for JDBC resources
       defined in contextXml descriptor.

    c. CarbonDataSourceAccessExample
       This is simple webapp sample to demonstrate the JNDI look-ups of Carbon DataSources
       which are exposed as JNDI resources from carbon in WSO2 Application Server

8. Jaxws-Jaxrs
    This contains series of samples to illustrate the use of Jaxws and Jaxrs in WSO2
    Application Server.

    a. jaxrs_basic -
       The samples shows a basic REST based Web Services using JAX-RS.

    c. jaxrs_sample_02 -
       The sample shows some advanced functionality of REST based Web Services using
       JAX-RS.

    d. jaxrs_content_negotiation -
       The sample shows how to do content negotiation so that the same resource can be
       served using multiple representations.

    e. async_jaxws -
       This sample illustrates the use of the JAX-WS asynchronous invocation model.

    f. java_first_jaxws -
       This sample illustrates how to develop a service using the "code first" approach
       using the JAX-WS APIs.

    g. wsdl_first_jaxws -
       This sample shows how to build and call a web service using a given WSDL (also
       called Contract First).

    h. handlers_jaxws -
       This sample shows how JAX-WS handlers are used.

    i. mtom_jaxws -
       This sample illustrates the use of a SOAP message with an attachment and
       XML-binary Optimized Packaging.

    j. ut -
       This sample shows how WS-Security support in JAX-WS services may be enabled.

    k. sign_encrypt -
       This sample shows how WS-Security support in JAX-WS may be enabled.
	   
9. jaggerySamples
    In this there are two simple sample that demonstrates the some functionality of the jaggery 
    deployed as jaggery applicatioins in WSO2 Web Service Application Server .

10. CarbonSaaSApp
     This app will demonstrate the SaaS capabilities in the AS

11. JavaEE-TomEE
     Set of JavaEE apps that use, CDI, EJB, JSF, JaxRS, JaxWS

12. SSOValveSample
     This sample show the Single Sign On capabilities of the AS


Sample hierarchy under the 'samples' directory
==============================================

samples
  ├── ASVersionSamples
  │   ├── ASVersionSample#1
  │   ├── ASVersionSample#2
  │   ├── ASVersionSample#3
  ├── CarbonSaaSApp
  ├── Chad
  ├── EntitlementFilter
  ├── example
  ├── FlickrClient
  ├── HelloWorld
  ├── HelloWorldWebapp
  ├── jaggerySamples
  ├── JavaEE-TomEE
  │   ├── CDI-Servlet
  │   ├── javaee-examples
  │   ├── JPA-JaxRS
  │   ├── JPA-JaxWS
  │   ├── JPA-Servlet
  │   ├── JSF-BVAL
  │   ├── JSF-EJB
  │   ├── JTA-Servlet
  ├── Jaxws-Jaxrs
  │   ├── async_jaxws
  │   ├── handlers_jaxws
  │   ├── java_first_jaxws
  │   ├── jaxrs_basic
  │   ├── jaxrs_content_negotiation
  │   ├── jaxrs_starbucks_service
  │   ├── mtom_jaxws
  │   ├── wsdl_first_jaxws
  │   └── ws_security
  ├── SSOValveSample
  │   ├── bar-app
  │   ├── foo-app
  ├── TinyURL
  ├── TomcatWebApps
  │   ├── CarbonDataSourceAccessExample
  │   ├── GenericJavaBeanResource
  │   └── JDBCDataSource
  ├── VirtualDirectoryListing
  └── WebappVersioning

Requirements
=============

1. JDK 1.7 or higher
2. Apache ANT 1.7 or higher
3. Apache Maven 3.0.4 or higher
4. A JavaScript compatible web browser
5. An active Internet connection


Setting Up and Running the Samples
==================================

Each sample folder contain a pom.xml, build.xml or both to build the samples. You can run
those using Apache Maven or Apache Ant to build the samples. After building those you can
use run-client scripts to run the client side of the sample if it is provided.Else Refer the
README files in each of the sample subdirectories for more detailed instructions on how to
run the samples. Because some samples need specific instruction to run them.


After Running the Samples
=========================

These samples only illustrate limited number of capabilities in WSO2 Application Server.
Therefore it's highly recommended to go through our documentation
at http://docs.wso2.org/wiki/application-server-documentation to learn
more about the product and its features.
