riftsaw SVN: r1362 - in trunk: samples/quickstart and 4 other directories.
by riftsaw-commits@lists.jboss.org
Author: jeff.yuchang
Date: 2011-05-09 02:47:07 -0400 (Mon, 09 May 2011)
New Revision: 1362
Added:
trunk/samples/quickstart/simple_flow/
trunk/samples/quickstart/simple_flow/.project
trunk/samples/quickstart/simple_flow/.settings/
trunk/samples/quickstart/simple_flow/.settings/org.eclipse.wst.common.component
trunk/samples/quickstart/simple_flow/.settings/org.eclipse.wst.common.project.facet.core.xml
trunk/samples/quickstart/simple_flow/bpelContent/
trunk/samples/quickstart/simple_flow/bpelContent/SimpleFlow.bpel
trunk/samples/quickstart/simple_flow/bpelContent/SimpleFlow.wsdl
trunk/samples/quickstart/simple_flow/bpelContent/deploy.xml
trunk/samples/quickstart/simple_flow/build.xml
trunk/samples/quickstart/simple_flow/messages/
trunk/samples/quickstart/simple_flow/messages/simpleflow_request.xml
trunk/samples/quickstart/simple_flow/messages/simpleflow_response.xml
trunk/samples/quickstart/simple_flow/readme.txt
Modified:
trunk/distribution/src/main/assembly/bin.xml
Log:
*RIFTSAE-383, added simple flow quick start.
Modified: trunk/distribution/src/main/assembly/bin.xml
===================================================================
--- trunk/distribution/src/main/assembly/bin.xml 2011-04-28 10:21:32 UTC (rev 1361)
+++ trunk/distribution/src/main/assembly/bin.xml 2011-05-09 06:47:07 UTC (rev 1362)
@@ -115,6 +115,7 @@
<include>quickstart/simple_pick/**</include>
<include>quickstart/while_wait/**</include>
<include>quickstart/management/**</include>
+ <include>quickstart/simple_flow/**</include>
<include>tutorial/BPEL-BluePrint1/**</include>
<include>tutorial/BPEL-BluePrint2/**</include>
<include>tutorial/BPEL-BluePrint3/**</include>
Added: trunk/samples/quickstart/simple_flow/.project
===================================================================
--- trunk/samples/quickstart/simple_flow/.project (rev 0)
+++ trunk/samples/quickstart/simple_flow/.project 2011-05-09 06:47:07 UTC (rev 1362)
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>simple_flow</name>
+ <comment></comment>
+ <projects>
+ </projects>
+ <buildSpec>
+ <buildCommand>
+ <name>org.eclipse.wst.common.project.facet.core.builder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.wst.validation.validationbuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.bpel.validator.builder</name>
+ <arguments>
+ <dictionary>
+ <key>debug</key>
+ <value>false</value>
+ </dictionary>
+ </arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>org.eclipse.jem.workbench.JavaEMFNature</nature>
+ <nature>org.eclipse.wst.common.modulecore.ModuleCoreNature</nature>
+ <nature>org.eclipse.wst.common.project.facet.core.nature</nature>
+ </natures>
+</projectDescription>
Added: trunk/samples/quickstart/simple_flow/.settings/org.eclipse.wst.common.component
===================================================================
--- trunk/samples/quickstart/simple_flow/.settings/org.eclipse.wst.common.component (rev 0)
+++ trunk/samples/quickstart/simple_flow/.settings/org.eclipse.wst.common.component 2011-05-09 06:47:07 UTC (rev 1362)
@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project-modules id="moduleCoreId" project-version="1.5.0">
+ <wb-module deploy-name="flowexample">
+ <wb-resource deploy-path="/" source-path="/bpelContent"/>
+ </wb-module>
+</project-modules>
Added: trunk/samples/quickstart/simple_flow/.settings/org.eclipse.wst.common.project.facet.core.xml
===================================================================
--- trunk/samples/quickstart/simple_flow/.settings/org.eclipse.wst.common.project.facet.core.xml (rev 0)
+++ trunk/samples/quickstart/simple_flow/.settings/org.eclipse.wst.common.project.facet.core.xml 2011-05-09 06:47:07 UTC (rev 1362)
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<faceted-project>
+ <fixed facet="jbt.bpel.facet.core"/>
+ <installed facet="jbt.bpel.facet.core" version="2.0"/>
+</faceted-project>
Added: trunk/samples/quickstart/simple_flow/bpelContent/SimpleFlow.bpel
===================================================================
--- trunk/samples/quickstart/simple_flow/bpelContent/SimpleFlow.bpel (rev 0)
+++ trunk/samples/quickstart/simple_flow/bpelContent/SimpleFlow.bpel 2011-05-09 06:47:07 UTC (rev 1362)
@@ -0,0 +1,108 @@
+<!-- flowexample BPEL Process [Generated by the Eclipse BPEL Designer] -->
+<bpel:process name="flowexample"
+ targetNamespace="http://www.jboss.org/riftsaw/sample/flowexample"
+ suppressJoinFailure="yes"
+ xmlns:tns="http://www.jboss.org/riftsaw/sample/flowexample"
+ xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
+ xmlns:ns1="http://www.w3.org/2001/XMLSchema">
+
+ <!-- Import the client WSDL -->
+ <bpel:import location="SimpleFlow.wsdl" namespace="http://www.jboss.org/riftsaw/sample/flowexample"
+ importType="http://schemas.xmlsoap.org/wsdl/" />
+
+ <!-- ================================================================= -->
+ <!-- PARTNERLINKS -->
+ <!-- List of services participating in this BPEL process -->
+ <!-- ================================================================= -->
+ <bpel:partnerLinks>
+ <!-- The 'client' role represents the requester of this service. -->
+ <bpel:partnerLink name="client"
+ partnerLinkType="tns:flowexample"
+ myRole="flowexampleProvider"
+ />
+ </bpel:partnerLinks>
+
+ <!-- ================================================================= -->
+ <!-- VARIABLES -->
+ <!-- List of messages and XML documents used within this BPEL process -->
+ <!-- ================================================================= -->
+ <bpel:variables>
+ <!-- Reference to the message passed as input during initiation -->
+ <bpel:variable name="input"
+ messageType="tns:flowexampleRequestMessage"/>
+
+ <!--
+ Reference to the message that will be returned to the requester
+ -->
+ <bpel:variable name="output"
+ messageType="tns:flowexampleResponseMessage"/>
+ <bpel:variable name="flow1" type="ns1:string"></bpel:variable>
+ <bpel:variable name="flow2" type="ns1:string"></bpel:variable>
+ </bpel:variables>
+
+ <!-- ================================================================= -->
+ <!-- ORCHESTRATION LOGIC -->
+ <!-- Set of activities coordinating the flow of messages across the -->
+ <!-- services integrated within this business process -->
+ <!-- ================================================================= -->
+ <bpel:sequence name="main">
+
+ <!-- Receive input from requester.
+ Note: This maps to operation defined in flowexample.wsdl
+ -->
+ <bpel:receive name="receiveInput" partnerLink="client"
+ portType="tns:flowexample"
+ operation="process" variable="input"
+ createInstance="yes"/>
+
+ <!-- Generate reply to synchronous request -->
+
+
+ <bpel:flow name="Flow"><bpel:sequence name="Sequence">
+ <bpel:assign validate="no" name="Assign">
+ <bpel:copy>
+ <bpel:from>
+ <bpel:literal xml:space="preserve">is executed by flow1 </bpel:literal>
+ </bpel:from>
+ <bpel:to variable="flow1">
+ </bpel:to>
+ </bpel:copy>
+ </bpel:assign>
+ </bpel:sequence><bpel:sequence name="Sequence1">
+ <bpel:assign validate="no" name="Assign1">
+ <bpel:copy>
+ <bpel:from>
+ <bpel:literal xml:space="preserve">and the flow2</bpel:literal>
+ </bpel:from>
+ <bpel:to variable="flow2"></bpel:to>
+ </bpel:copy>
+ </bpel:assign>
+ </bpel:sequence></bpel:flow>
+ <bpel:assign validate="no" name="Assign2">
+ <bpel:copy>
+ <bpel:from><bpel:literal><tns:flowexampleResponse xmlns:tns="http://www.jboss.org/riftsaw/sample/flowexample" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
+ <tns:result></tns:result>
+</tns:flowexampleResponse>
+</bpel:literal></bpel:from>
+ <bpel:to variable="output" part="payload"></bpel:to>
+ </bpel:copy>
+ <bpel:copy>
+ <bpel:from>
+
+
+ <![CDATA[concat($input.payload/tns:input, $flow1, $flow2)]]>
+ </bpel:from>
+ <bpel:to part="payload" variable="output">
+ <bpel:query queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath1.0"><![CDATA[tns:result]]></bpel:query>
+ </bpel:to>
+ </bpel:copy>
+ </bpel:assign>
+ <bpel:reply name="replyOutput"
+ partnerLink="client"
+ portType="tns:flowexample"
+ operation="process"
+ variable="output"
+ />
+ </bpel:sequence>
+</bpel:process>
+
Added: trunk/samples/quickstart/simple_flow/bpelContent/SimpleFlow.wsdl
===================================================================
--- trunk/samples/quickstart/simple_flow/bpelContent/SimpleFlow.wsdl (rev 0)
+++ trunk/samples/quickstart/simple_flow/bpelContent/SimpleFlow.wsdl 2011-05-09 06:47:07 UTC (rev 1362)
@@ -0,0 +1,99 @@
+<?xml version="1.0"?>
+<definitions name="flowexample"
+ targetNamespace="http://www.jboss.org/riftsaw/sample/flowexample"
+ xmlns:tns="http://www.jboss.org/riftsaw/sample/flowexample"
+ xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+ xmlns="http://schemas.xmlsoap.org/wsdl/"
+ xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+ >
+
+<!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ TYPE DEFINITION - List of types participating in this BPEL process
+ The BPEL Designer will generate default request and response types
+ but you can define or import any XML Schema type and use them as part
+ of the message types.
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <types>
+ <schema attributeFormDefault="unqualified" elementFormDefault="qualified"
+ targetNamespace="http://www.jboss.org/riftsaw/sample/flowexample"
+ xmlns="http://www.w3.org/2001/XMLSchema">
+
+ <element name="flowexampleRequest">
+ <complexType>
+ <sequence>
+ <element name="input" type="string"/>
+ </sequence>
+ </complexType>
+ </element>
+
+ <element name="flowexampleResponse">
+ <complexType>
+ <sequence>
+ <element name="result" type="string"/>
+ </sequence>
+ </complexType>
+ </element>
+ </schema>
+ </types>
+
+
+<!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ MESSAGE TYPE DEFINITION - Definition of the message types used as
+ part of the port type defintions
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <message name="flowexampleRequestMessage">
+ <part name="payload" element="tns:flowexampleRequest"/>
+ </message>
+ <message name="flowexampleResponseMessage">
+ <part name="payload" element="tns:flowexampleResponse"/>
+ </message>
+
+<!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ PORT TYPE DEFINITION - A port type groups a set of operations into
+ a logical service unit.
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+
+ <!-- portType implemented by the flowexample BPEL process -->
+ <portType name="flowexample">
+ <operation name="process">
+ <input message="tns:flowexampleRequestMessage" />
+ <output message="tns:flowexampleResponseMessage"/>
+ </operation>
+ </portType>
+<!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ PARTNER LINK TYPE DEFINITION
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <plnk:partnerLinkType name="flowexample">
+ <plnk:role name="flowexampleProvider" portType="tns:flowexample"/>
+ </plnk:partnerLinkType>
+
+
+<!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ BINDING DEFINITION - Defines the message format and protocol details
+ for a web service.
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <binding name="flowexampleBinding" type="tns:flowexample">
+ <soap:binding style="document"
+ transport="http://schemas.xmlsoap.org/soap/http" />
+ <operation name="process">
+ <soap:operation
+ soapAction="http://www.jboss.org/riftsaw/sample/flowexample/process" />
+ <input>
+ <soap:body use="literal" />
+ </input>
+ <output>
+ <soap:body use="literal" />
+ </output>
+ </operation>
+ </binding>
+
+<!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ SERVICE DEFINITION - A service groups a set of port into
+ a service unit.
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <service name="flowexample">
+ <port name="flowexamplePort" binding="tns:flowexampleBinding">
+ <soap:address location="http://localhost:8080/Quickstart_bpel_simple_flow" />
+ </port>
+ </service>
+</definitions>
\ No newline at end of file
Added: trunk/samples/quickstart/simple_flow/bpelContent/deploy.xml
===================================================================
--- trunk/samples/quickstart/simple_flow/bpelContent/deploy.xml (rev 0)
+++ trunk/samples/quickstart/simple_flow/bpelContent/deploy.xml 2011-05-09 06:47:07 UTC (rev 1362)
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" xmlns:flowexample="http://www.jboss.org/riftsaw/sample/flowexample">
+ <process name="flowexample:flowexample">
+ <active>true</active>
+ <retired>false</retired>
+ <process-events generate="all"/>
+ <provide partnerLink="client">
+ <service name="flowexample:flowexample" port="flowexamplePort"/>
+ </provide>
+ </process>
+</deploy>
\ No newline at end of file
Added: trunk/samples/quickstart/simple_flow/build.xml
===================================================================
--- trunk/samples/quickstart/simple_flow/build.xml (rev 0)
+++ trunk/samples/quickstart/simple_flow/build.xml 2011-05-09 06:47:07 UTC (rev 1362)
@@ -0,0 +1,34 @@
+<project name="Quickstart_simple_flow" default="deploy" basedir=".">
+
+ <description>
+ ${ant.project.name}
+ ${line.separator}
+ </description>
+
+ <property file="../../../install/deployment.properties" />
+ <import file="../../common/base-build.xml"/>
+
+ <property name="version" value="1" />
+
+ <property name="sample.jar.name" value="${ant.project.name}-${version}.jar" />
+
+ <target name="deploy">
+ <echo>Deploy ${ant.project.name}</echo>
+ <jar basedir="bpelContent" destfile="${deploy.dir}/${sample.jar.name}" />
+ </target>
+
+ <target name="undeploy">
+ <echo>Undeploy ${ant.project.name}</echo>
+ <delete file="${deploy.dir}/${sample.jar.name}" />
+ </target>
+
+ <target name="sendhello">
+ <echo>Send test message to: ${ant.project.name}</echo>
+ <java classname="org.apache.ode.tools.sendsoap.cline.HttpSoapSender">
+ <arg value="http://localhost:8080/Quickstart_bpel_simple_flow"/>
+ <arg value="messages/simpleflow_request.xml"/>
+ <classpath refid="rs-exec-classpath"/>
+ </java>
+ </target>
+
+</project>
Added: trunk/samples/quickstart/simple_flow/messages/simpleflow_request.xml
===================================================================
--- trunk/samples/quickstart/simple_flow/messages/simpleflow_request.xml (rev 0)
+++ trunk/samples/quickstart/simple_flow/messages/simpleflow_request.xml 2011-05-09 06:47:07 UTC (rev 1362)
@@ -0,0 +1,8 @@
+<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:wsdl="http://www.jboss.org/riftsaw/sample/flowexample">
+ <soapenv:Header/>
+ <soapenv:Body>
+ <wsdl:flowexampleRequest>
+ <wsdl:input>Simple Flow </wsdl:input>
+ </wsdl:flowexampleRequest>
+ </soapenv:Body>
+</soapenv:Envelope>
Added: trunk/samples/quickstart/simple_flow/messages/simpleflow_response.xml
===================================================================
--- trunk/samples/quickstart/simple_flow/messages/simpleflow_response.xml (rev 0)
+++ trunk/samples/quickstart/simple_flow/messages/simpleflow_response.xml 2011-05-09 06:47:07 UTC (rev 1362)
@@ -0,0 +1,9 @@
+<env:Envelope xmlns:env='http://schemas.xmlsoap.org/soap/envelope/'>
+ <env:Header>
+ </env:Header>
+ <env:Body>
+ <flowexampleResponse xmlns='http://www.jboss.org/riftsaw/sample/flowexample'>
+ <tns:result xmlns:tns='http://www.jboss.org/riftsaw/sample/flowexample'>Simple Flow is executed by flow1 and the flow2</tns:result>
+ </flowexampleResponse>
+ </env:Body>
+</env:Envelope>
Added: trunk/samples/quickstart/simple_flow/readme.txt
===================================================================
--- trunk/samples/quickstart/simple_flow/readme.txt (rev 0)
+++ trunk/samples/quickstart/simple_flow/readme.txt 2011-05-09 06:47:07 UTC (rev 1362)
@@ -0,0 +1,25 @@
+Quickstart Examples - Level 1 - Simple Flow
+============================================
+
+This example demonstrate a process with flow activity, the 'assign' and 'assign1'
+activities will be parallel executed in the process.
+
+To deploy the example, open a command line window in the example's folder,
+and simply type 'ant deploy'. To undeploy, use the command 'ant undeploy'.
+
+To test the example, for example using the SOAPUI client, an example
+'simpleflow_request' message can be found in the messages sub-folder, with the
+relevant WSDL being located in the bpel sub-folder.
+
+Alternatively, use the 'ant sendhello' command (from a command line window)
+to send the message.
+
+NOTE: The "ant deploy" command will by default deploy version 1 of the
+example to the server. If you wish to change the example, and redeploy,
+then you will need to update the version number in the build.xml, or
+override the version property, e.g. "ant -Dversion=2 deploy" (and similarly
+when undeploying "ant -Dversion=2 undeploy").
+
+Some handy URLs:
+http://localhost:8080/bpel-console is the BPEL console
+http://localhost:8080/Quickstart_bpel_simple_flow?wsdl is the URL to the BPEL process' WSDL