Author: kurtstam
Date: 2010-04-14 14:25:55 -0400 (Wed, 14 Apr 2010)
New Revision: 620
Added:
branches/ODE/ODE-1.x/agents/pom.xml
branches/ODE/ODE-1.x/axis2-war/pom.xml
branches/ODE/ODE-1.x/axis2-war/src/main/assembly/
branches/ODE/ODE-1.x/axis2-war/src/main/assembly/bin.xml
branches/ODE/ODE-1.x/axis2-war/src/main/webapp/WEB-INF/classes/META-INF/
branches/ODE/ODE-1.x/axis2-war/src/main/webapp/WEB-INF/classes/META-INF/services/
branches/ODE/ODE-1.x/axis2-war/src/main/webapp/WEB-INF/classes/META-INF/services/org.apache.commons.logging.LogFactory
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/ClusteredOutgoingTrafficTest.java
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/NoP2PTest.java
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/correlation/CorrelationUnicityTest.java
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/management/Retire2Test.java
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/Ping.bpel
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/Ping.wsdl
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/PingPong.wsdl
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/Pong.bpel
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/Pong.wsdl
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/deploy.xml
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/testRequest.soap
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestCorrelationUnicity/
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestCorrelationUnicity/CorrelationMultiTest.bpel
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestCorrelationUnicity/CorrelationMultiTest.wsdl
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestCorrelationUnicity/deploy.xml
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestCorrelationUnicity/dummy-service.wsdl
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestCorrelationUnicity/testRequest.soap
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestCorrelationUnicity/testRequest2.soap
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestHttpBindingExtensions/
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/1/
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/1/TestRetire.bpel
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/1/TestRetire.wsdl
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/1/deploy.xml
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/1/testRequest1.soap
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/1/testRequest2.soap
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/2/
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/2/TestRetire.bpel
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/2/TestRetire.wsdl
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/2/deploy.xml
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/Ping.bpel
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/Ping.wsdl
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/PingPong.wsdl
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/Pong.bpel
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/Pong.wsdl
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/deploy.xml
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/testRequest.soap
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestRampart/
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestRampart/process-template/
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestRampart/services/
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestRampart4Process/
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestRampart4Process/basic/
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestRampart4Process/basic/process-template/
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestRampartBasic/process-template/
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestRampartBasic/services/
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestRampartBkp/
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestRampartBkp/service_repositories/
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestRampartBkp/service_repositories/sample01/
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestRampartBkp/service_repositories/sample01/modules/
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestRampartBkp/service_repositories/sample01/services/
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestRampartPolicy/process-template/
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestRampartPolicy/services/
branches/ODE/ODE-1.x/axis2/pom.xml
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/util/ClusterUrlTransformer.java
branches/ODE/ODE-1.x/bpel-api-jca/pom.xml
branches/ODE/ODE-1.x/bpel-api/pom.xml
branches/ODE/ODE-1.x/bpel-api/src/main/java/org/apache/ode/bpel/capi/
branches/ODE/ODE-1.x/bpel-api/src/main/java/org/apache/ode/bpel/dao/
branches/ODE/ODE-1.x/bpel-api/src/main/java/org/apache/ode/bpel/epr/
branches/ODE/ODE-1.x/bpel-api/src/main/java/org/apache/ode/bpel/xsl/
branches/ODE/ODE-1.x/bpel-api/src/main/resources/
branches/ODE/ODE-1.x/bpel-api/src/main/xsd/
branches/ODE/ODE-1.x/bpel-api/src/test/java/org/apache/ode/bpel/capi/
branches/ODE/ODE-1.x/bpel-compiler/pom.xml
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/ExpressionValidatorFactory.java
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/api/ExpressionValidator.java
branches/ODE/ODE-1.x/bpel-compiler/src/test/java/org/apache/ode/bpel/elang/
branches/ODE/ODE-1.x/bpel-compiler/src/test/java/org/apache/ode/bpel/elang/xpath20/
branches/ODE/ODE-1.x/bpel-compiler/src/test/java/org/apache/ode/bpel/elang/xpath20/runtime/
branches/ODE/ODE-1.x/bpel-compiler/src/test/java/org/apache/ode/bpel/elang/xquery10/
branches/ODE/ODE-1.x/bpel-compiler/src/test/java/org/apache/ode/bpel/elang/xquery10/compiler/
branches/ODE/ODE-1.x/bpel-compiler/src/test/java/org/apache/ode/bpel/elang/xquery10/compiler/XQuery10ExpressionCompilerImplTest.java
branches/ODE/ODE-1.x/bpel-connector/pom.xml
branches/ODE/ODE-1.x/bpel-dao/pom.xml
branches/ODE/ODE-1.x/bpel-epr/pom.xml
branches/ODE/ODE-1.x/bpel-epr/src/main/test/
branches/ODE/ODE-1.x/bpel-epr/src/main/test/org/
branches/ODE/ODE-1.x/bpel-epr/src/main/test/org/apache/
branches/ODE/ODE-1.x/bpel-epr/src/main/test/org/apache/ode/
branches/ODE/ODE-1.x/bpel-epr/src/main/test/org/apache/ode/bpel/
branches/ODE/ODE-1.x/bpel-epr/src/main/test/org/apache/ode/bpel/epr/
branches/ODE/ODE-1.x/bpel-epr/src/main/test/org/apache/ode/bpel/epr/WSDL11EndpointTest.java
branches/ODE/ODE-1.x/bpel-obj/pom.xml
branches/ODE/ODE-1.x/bpel-ql/pom.xml
branches/ODE/ODE-1.x/bpel-ql/test/
branches/ODE/ODE-1.x/bpel-ql/test/junit/
branches/ODE/ODE-1.x/bpel-ql/test/test-cases/
branches/ODE/ODE-1.x/bpel-runtime/pom.xml
branches/ODE/ODE-1.x/bpel-runtime/pom2.xml
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/IMAManager.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/migration/OutstandingRequestsMigration.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/replayer/
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/replayer/RemainingExchangesException.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/replayer/Replayer.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/replayer/ReplayerBpelRuntimeContextImpl.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/replayer/ReplayerContext.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/replayer/ReplayerScheduler.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/util/
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/elang/xpath20/runtime/XsdTypesTest.java
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/engine/MyRoleMessageExchangeImplTest.java
branches/ODE/ODE-1.x/bpel-runtime/src/test/resources/recovery/failure-to-fault2.bpel
branches/ODE/ODE-1.x/bpel-schemas/pom.xml
branches/ODE/ODE-1.x/bpel-schemas/src/main/xsd/activityRecovery.xsd
branches/ODE/ODE-1.x/bpel-scripts/pom.xml
branches/ODE/ODE-1.x/bpel-scripts/src/bpel/
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/circularReference/
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/circularReference/CircularReference.bpel
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/circularReference/CircularReference1.wsdl
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/circularReference/CircularReference2.wsdl
branches/ODE/ODE-1.x/bpel-store/pom.xml
branches/ODE/ODE-1.x/bpel-test/pom.xml
branches/ODE/ODE-1.x/bpel-test/src/test/resources/META-INF/
branches/ODE/ODE-1.x/bpel-test/src/test/resources/META-INF/services/
branches/ODE/ODE-1.x/bpel-test/src/test/resources/META-INF/services/org.apache.commons.logging.LogFactory
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAssignMissingData/TestIgnoreMissingFromData.bpel
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAssignMissingData/TestIgnoreMissingFromData.wsdl
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAssignMissingData/test1.properties
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAssignMissingData/test2.properties
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/TestIMA.bpel
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/TestIMA.wsdl
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/deploy.xml
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/test1.properties
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/test2.properties
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/test3.properties
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/test4.properties
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestXQueryExpression/HelloXQueryWorld.xsl
branches/ODE/ODE-1.x/dao-hibernate-db/build.xml
branches/ODE/ODE-1.x/dao-hibernate-db/pom.xml
branches/ODE/ODE-1.x/dao-hibernate/pom.xml
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/NativeHiLoGenerator.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/GZipDataType.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/hobj/
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/ql/
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/ql/instances/
branches/ODE/ODE-1.x/dao-hibernate/src/test/java/org/apache/ode/daohib/bpel/ProcessManagementDaoTest.java
branches/ODE/ODE-1.x/dao-hibernate/src/test/resources/
branches/ODE/ODE-1.x/dao-hibernate/src/test/resources/log4j.properties
branches/ODE/ODE-1.x/dao-jpa-ojpa-derby/build.xml
branches/ODE/ODE-1.x/dao-jpa-ojpa-derby/pom.xml
branches/ODE/ODE-1.x/dao-jpa/pom.xml
branches/ODE/ODE-1.x/dependencies.rb
branches/ODE/ODE-1.x/distro/pom.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/HelloWorld2-RPC-http/
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/HelloWorld2-RPC-http/HelloWorld2-RPC.wsdl
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/HelloWorld2-RPC-http/build.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/HelloWorld2-RPC-process/
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/HelloWorld2-RPC-process/HelloWorld2-RPC.bpel
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/HelloWorld2-RPC-process/HelloWorld2-RPC.wsdl
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/HelloWorld2-RPC-process/build.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/HelloWorld2-RPC-process/deploy.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/build.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/jbi.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/message.soap
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/HelloWorld2-http/
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/HelloWorld2-http/HelloWorld2.wsdl
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/HelloWorld2-http/build.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/HelloWorld2-process/
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/HelloWorld2-process/HelloWorld2.bpel
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/HelloWorld2-process/HelloWorld2.wsdl
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/HelloWorld2-process/build.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/HelloWorld2-process/deploy.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/build.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/jbi.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/message.soap
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/build.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/jbi.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/message.soap
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping-http/
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping-http/Ping.wsdl
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping-http/build.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping/
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping/Ping.bpel
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping/Ping.wsdl
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping/Pong.wsdl
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping/build.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping/deploy.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/pong/
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/pong/Pong.bpel
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/pong/Pong.wsdl
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/pong/build.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/pong/deploy.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/ProcessManagement/
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/ProcessManagement/ProcessManagement-HTTP/
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/ProcessManagement/ProcessManagement-HTTP/build.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/ProcessManagement/ProcessManagement-HTTP/pmapi.wsdl
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/ProcessManagement/build.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/ProcessManagement/jbi.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/ProcessManagement/message.soap
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/base-sa.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/base-su.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/base.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/example.properties
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/osgi.bnd
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/pom.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/java/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/java/org/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/java/org/apache/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/java/org/apache/ode/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/java/org/apache/ode/ping/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/java/org/apache/ode/ping/AttachPing.java
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/META-INF/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/META-INF/spring/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/META-INF/spring/xbean.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/Ping.bpel
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/Ping.wsdl
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/Ping.xsd
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/Pong.bpel
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/Pong.wsdl
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/Pong.xsd
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/common.wsdl
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/deploy.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/README.txt
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/pom.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/src/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/src/main/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/src/main/resources/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/src/main/resources/Ping.wsdl
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/src/main/resources/Ping.xsd
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/src/main/resources/Pong.wsdl
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/src/main/resources/Pong.xsd
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/src/main/resources/common.wsdl
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/http-su/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/http-su/pom.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/http-su/src/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/http-su/src/main/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/http-su/src/main/resources/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/http-su/src/main/resources/xbean.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/pom.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/src/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/src/main/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/src/main/java/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/src/main/java/org/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/src/main/java/org/apache/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/src/main/java/org/apache/ode/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/src/main/java/org/apache/ode/ping/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/src/main/java/org/apache/ode/ping/AttachPing.java
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/src/main/resources/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/src/main/resources/Ping.bpel
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/src/main/resources/Pong.bpel
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/src/main/resources/deploy.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/pom.xml
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/sa/
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/sa/pom.xml
branches/ODE/ODE-1.x/distro/src/main/
branches/ODE/ODE-1.x/distro/src/main/assembly/
branches/ODE/ODE-1.x/distro/src/main/assembly/jbi.xml
branches/ODE/ODE-1.x/distro/src/main/assembly/war.xml
branches/ODE/ODE-1.x/jacob-ap/pom.xml
branches/ODE/ODE-1.x/jacob-ap/src/main/resources/org/
branches/ODE/ODE-1.x/jacob-ap/src/main/resources/org/apache/
branches/ODE/ODE-1.x/jacob-ap/src/main/resources/org/apache/ode/
branches/ODE/ODE-1.x/jacob-ap/src/main/resources/org/apache/ode/jacob/
branches/ODE/ODE-1.x/jacob-ap/src/main/resources/org/apache/ode/jacob/ap/
branches/ODE/ODE-1.x/jacob/pom.xml
branches/ODE/ODE-1.x/jacob/src/generated/
branches/ODE/ODE-1.x/jacob/src/test/java/com/
branches/ODE/ODE-1.x/jacob/src/test/java/com/fs/
branches/ODE/ODE-1.x/jacob/src/test/java/com/fs/examples/
branches/ODE/ODE-1.x/jacob/src/test/java/com/fs/jacob/
branches/ODE/ODE-1.x/jacob/src/xdt/com/
branches/ODE/ODE-1.x/jacob/src/xdt/com/fs/
branches/ODE/ODE-1.x/jacob/src/xdt/com/fs/jacob/
branches/ODE/ODE-1.x/jbi-bundle/
branches/ODE/ODE-1.x/jbi-bundle/pom.xml
branches/ODE/ODE-1.x/jbi-bundle/src/
branches/ODE/ODE-1.x/jbi-bundle/src/main/
branches/ODE/ODE-1.x/jbi-bundle/src/main/filtered-resources/
branches/ODE/ODE-1.x/jbi-bundle/src/main/filtered-resources/features.xml
branches/ODE/ODE-1.x/jbi-bundle/src/main/java/
branches/ODE/ODE-1.x/jbi-bundle/src/main/java/org/
branches/ODE/ODE-1.x/jbi-bundle/src/main/java/org/apache/
branches/ODE/ODE-1.x/jbi-bundle/src/main/java/org/apache/ode/
branches/ODE/ODE-1.x/jbi-bundle/src/main/java/org/apache/ode/jbi/
branches/ODE/ODE-1.x/jbi-bundle/src/main/java/org/apache/ode/jbi/osgi/
branches/ODE/ODE-1.x/jbi-bundle/src/main/java/org/apache/ode/jbi/osgi/ServiceUnitActivator.java
branches/ODE/ODE-1.x/jbi-bundle/src/main/resources/
branches/ODE/ODE-1.x/jbi-bundle/src/main/resources/META-INF/
branches/ODE/ODE-1.x/jbi-bundle/src/main/resources/META-INF/persistence.xml
branches/ODE/ODE-1.x/jbi-bundle/src/main/resources/META-INF/spring/
branches/ODE/ODE-1.x/jbi-bundle/src/main/resources/META-INF/spring/ode-jbi.xml
branches/ODE/ODE-1.x/jbi-karaf-commands/
branches/ODE/ODE-1.x/jbi-karaf-commands/org.apache.ode.commands.bnd
branches/ODE/ODE-1.x/jbi-karaf-commands/src/
branches/ODE/ODE-1.x/jbi-karaf-commands/src/main/
branches/ODE/ODE-1.x/jbi-karaf-commands/src/main/java/
branches/ODE/ODE-1.x/jbi-karaf-commands/src/main/java/org/
branches/ODE/ODE-1.x/jbi-karaf-commands/src/main/java/org/apache/
branches/ODE/ODE-1.x/jbi-karaf-commands/src/main/java/org/apache/ode/
branches/ODE/ODE-1.x/jbi-karaf-commands/src/main/java/org/apache/ode/karaf/
branches/ODE/ODE-1.x/jbi-karaf-commands/src/main/java/org/apache/ode/karaf/commands/
branches/ODE/ODE-1.x/jbi-karaf-commands/src/main/java/org/apache/ode/karaf/commands/OdeCommandsBase.java
branches/ODE/ODE-1.x/jbi-karaf-commands/src/main/java/org/apache/ode/karaf/commands/OdeListCommand.java
branches/ODE/ODE-1.x/jbi-karaf-commands/src/main/java/org/apache/ode/karaf/commands/OdeTerminateCommand.java
branches/ODE/ODE-1.x/jbi-karaf-commands/src/main/resources/
branches/ODE/ODE-1.x/jbi-karaf-commands/src/main/resources/OSGI-INF/
branches/ODE/ODE-1.x/jbi-karaf-commands/src/main/resources/OSGI-INF/blueprint/
branches/ODE/ODE-1.x/jbi-karaf-commands/src/main/resources/OSGI-INF/blueprint/ode-commands.xml
branches/ODE/ODE-1.x/jbi-karaf/
branches/ODE/ODE-1.x/jbi-karaf/pom.xml
branches/ODE/ODE-1.x/jbi-karaf/src/
branches/ODE/ODE-1.x/jbi-karaf/src/main/
branches/ODE/ODE-1.x/jbi-karaf/src/main/resources/
branches/ODE/ODE-1.x/jbi-karaf/src/main/resources/features.xml
branches/ODE/ODE-1.x/jbi/pom.xml
branches/ODE/ODE-1.x/jbi/src/main/assembly/
branches/ODE/ODE-1.x/jbi/src/main/assembly/bin.xml
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/bridge/
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/CommunicationJbiTest.java
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/DigestJbiTest.java
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/EmptyRespJbiTest.java
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/MagicSessionExternalJbiTest.java
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/MagicSessionJbiTest.java
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/OnEventAlarmJbiTest.java
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/ReplayerJbiTest.java
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/RetireJbiTest.java
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/msgmap/
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/msgmap/JbiWsdl11WrapperMapperTest.java
branches/ODE/ODE-1.x/jbi/src/test/jbi/
branches/ODE/ODE-1.x/jbi/src/test/jbi/ode-jbi.properties
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/EPRTest.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/EPRTest2.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation.wsdl
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation000.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation001.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation010.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation011.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation100.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation101.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation110.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation111.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationArtifacts.wsdl
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB000.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB001.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB010.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB011.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB100.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB101.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB110.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB111.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/deploy.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/smx.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/test.properties
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/smx.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/test.properties
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v1-1/
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v1-1/OnEventCorrelation.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v1-1/OnEventCorrelation.wsdl
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v1-1/OnEventCorrelationArtifacts.wsdl
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v1-1/deploy.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v2-1/
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v2-1/OnEventCorrelation.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v2-1/OnEventCorrelation.wsdl
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v2-1/OnEventCorrelationArtifacts.wsdl
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v2-1/deploy.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/
branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/Ping.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/Ping.wsdl
branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/Pong.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/Pong.wsdl
branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/deploy.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/smx.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/test.properties
branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionExternalJbiTest/
branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionExternalJbiTest/Main.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionExternalJbiTest/Main.wsdl
branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionExternalJbiTest/Responder.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionExternalJbiTest/deploy.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionExternalJbiTest/smx.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionExternalJbiTest/test.properties
branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionJbiTest/
branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionJbiTest/Main.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionJbiTest/Main.wsdl
branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionJbiTest/Responder.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionJbiTest/deploy.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionJbiTest/smx.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionJbiTest/test.properties
branches/ODE/ODE-1.x/jbi/src/test/resources/OnEventAlarmJbiTest/
branches/ODE/ODE-1.x/jbi/src/test/resources/OnEventAlarmJbiTest/OnEventCorrelation.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/OnEventAlarmJbiTest/OnEventCorrelation.wsdl
branches/ODE/ODE-1.x/jbi/src/test/resources/OnEventAlarmJbiTest/OnEventCorrelationArtifacts.wsdl
branches/ODE/ODE-1.x/jbi/src/test/resources/OnEventAlarmJbiTest/deploy.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/OnEventAlarmJbiTest/smx.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/OnEventAlarmJbiTest/test.properties
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/OnEventCorrelation.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/OnEventCorrelation.wsdl
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/OnEventCorrelation2.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/OnEventCorrelationArtifacts.wsdl
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/deploy.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/initiateLiveRequest.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/initiateRequest.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/replayLiveRequest.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/replayRequest.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/replayRollbackOnFault.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/replayRollbackOnFault2.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/replayXQueryRequest.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/smx.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/test.properties
branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/
branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/smx.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/test.properties
branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-1/
branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-1/OnEventCorrelation.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-1/OnEventCorrelation.wsdl
branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-1/OnEventCorrelationArtifacts.wsdl
branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-1/deploy.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-2/
branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-2/OnEventCorrelation.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-2/OnEventCorrelation.wsdl
branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-2/OnEventCorrelationArtifacts.wsdl
branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-2/deploy.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/fault.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/fault1.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/smx-base.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/test.wsdl
branches/ODE/ODE-1.x/jca-ra/pom.xml
branches/ODE/ODE-1.x/jca-server/pom.xml
branches/ODE/ODE-1.x/pom.xml
branches/ODE/ODE-1.x/repositories.rb
branches/ODE/ODE-1.x/scheduler-simple/pom.xml
branches/ODE/ODE-1.x/scheduler-simple/src/test/java/org/apache/ode/scheduler/simple/GeronimoDelegateSupport.java
branches/ODE/ODE-1.x/tasks/bnd.rake
branches/ODE/ODE-1.x/tools/pom.xml
branches/ODE/ODE-1.x/tools/src/main/java/org/apache/ode/tools/urlalias/
branches/ODE/ODE-1.x/utils/pom.xml
branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/dao/
branches/ODE/ODE-1.x/utils/src/test/resources/common/
branches/ODE/ODE-1.x/utils/src/test/resources/log4j.properties
Modified:
branches/ODE/ODE-1.x/
branches/ODE/ODE-1.x/.project
branches/ODE/ODE-1.x/RELEASE_NOTES
branches/ODE/ODE-1.x/Rakefile
branches/ODE/ODE-1.x/axis2-war/src/main/webapp/WEB-INF/classes/log4j.properties
branches/ODE/ODE-1.x/axis2-war/src/main/webapp/js/ODE.js
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/Axis2TestBase.java
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/BpelActivityTest.java
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanFailureHibTest.java
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanFaultHibTest.java
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanFaultTest.java
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanSuccessHibTest.java
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanSuccessTest.java
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanTestBase.java
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/ProcessCronCleanupTest.java
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/SystemCronCleanupTest.java
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/management/DeploymentTest.java
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/management/InstanceManagementTest.java
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestSoapHeader2/hello.xsd
branches/ODE/ODE-1.x/axis2-war/src/test/webapp/WEB-INF/conf.hib-derby/ode-axis2.properties
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/BindingContextImpl.java
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/ODEServer.java
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/ODEService.java
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/OdeFault.java
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/SoapExternalService.java
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/deploy/DeploymentPoller.java
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/httpbinding/HttpExternalService.java
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/service/DeploymentBrowser.java
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/service/DeploymentWebService.java
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/util/AxisUtils.java
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/util/GeronimoFactory.java
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/util/SoapMessageConverter.java
branches/ODE/ODE-1.x/axis2/src/main/wsdl/pmapi.wsdl
branches/ODE/ODE-1.x/bpel-api/src/main/java/org/apache/ode/bpel/explang/EvaluationContext.java
branches/ODE/ODE-1.x/bpel-api/src/main/java/org/apache/ode/bpel/iapi/ProcessConf.java
branches/ODE/ODE-1.x/bpel-api/src/main/java/org/apache/ode/bpel/iapi/Scheduler.java
branches/ODE/ODE-1.x/bpel-api/src/main/java/org/apache/ode/bpel/pmapi/ProcessInfoCustomizer.java
branches/ODE/ODE-1.x/bpel-api/src/main/java/org/apache/ode/bpel/pmapi/ProcessManagement.java
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/AssignGenerator.java
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/BpelC.java
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/BpelCompiler.java
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/DefaultResourceFinder.java
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/ResourceFinder.java
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/WSDLRegistry.java
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/WsdlFinderXMLEntityResolver.java
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/api/CompilerContext.java
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/api/ExpressionCompiler.java
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/wsdl/XMLSchemaType.java
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/wsdl/XMLSchemaTypeSerializer.java
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/elang/xpath10/compiler/JaxenBpelHandler.java
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/elang/xpath10/compiler/XPathMessages.java
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/elang/xpath20/compiler/JaxpVariableResolver.java
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/elang/xpath20/compiler/XPath20ExpressionCompilerImpl.java
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/elang/xquery10/compiler/XQuery10ExpressionCompilerImpl.java
branches/ODE/ODE-1.x/bpel-compiler/src/test/java/org/apache/ode/bpel/compiler/StaticCheckSuite.java
branches/ODE/ODE-1.x/bpel-compiler/src/test/java/org/apache/ode/bpel/compiler/StaticCheckTCase.java
branches/ODE/ODE-1.x/bpel-compiler/src/test/java/org/apache/ode/bpel/compiler/XPathTest.java
branches/ODE/ODE-1.x/bpel-compiler/src/test/java/org/apache/ode/bpel/compiler_2_0/GoodCompileTCase.java
branches/ODE/ODE-1.x/bpel-compiler/src/test/resources/log4j.properties
branches/ODE/ODE-1.x/bpel-dao/src/main/java/org/apache/ode/bpel/dao/CorrelatorDAO.java
branches/ODE/ODE-1.x/bpel-dao/src/main/java/org/apache/ode/bpel/dao/MessageExchangeDAO.java
branches/ODE/ODE-1.x/bpel-dao/src/main/java/org/apache/ode/bpel/dao/ProcessInstanceDAO.java
branches/ODE/ODE-1.x/bpel-dao/src/main/java/org/apache/ode/bpel/dao/ProcessManagementDAO.java
branches/ODE/ODE-1.x/bpel-epr/src/main/java/org/apache/ode/il/DynamicService.java
branches/ODE/ODE-1.x/bpel-epr/src/main/java/org/apache/ode/il/MockScheduler.java
branches/ODE/ODE-1.x/bpel-epr/src/main/java/org/apache/ode/il/config/OdeConfigProperties.java
branches/ODE/ODE-1.x/bpel-epr/src/main/java/org/apache/ode/il/dbutil/Database.java
branches/ODE/ODE-1.x/bpel-obj/src/main/java/org/apache/ode/bpel/o/OActivity.java
branches/ODE/ODE-1.x/bpel-obj/src/main/java/org/apache/ode/bpel/o/OAssign.java
branches/ODE/ODE-1.x/bpel-obj/src/main/java/org/apache/ode/bpel/o/OBase.java
branches/ODE/ODE-1.x/bpel-obj/src/main/java/org/apache/ode/bpel/o/OConstants.java
branches/ODE/ODE-1.x/bpel-obj/src/main/java/org/apache/ode/bpel/o/OProcess.java
branches/ODE/ODE-1.x/bpel-ql/build.properties
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/elang/xpath20/runtime/JaxpFunctionResolver.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/elang/xpath20/runtime/JaxpVariableResolver.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/elang/xpath20/runtime/XPath20ExpressionRuntime.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/elang/xquery10/runtime/XQuery10ExpressionRuntime.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/BpelEngineImpl.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/BpelProcess.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/BpelRuntimeContextImpl.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/BpelServerImpl.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/BrokeredMyRoleMessageExchangeImpl.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/MessageExchangeImpl.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/MessageImpl.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/MyRoleMessageExchangeImpl.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/OutstandingRequestManager.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/PartnerLinkMyRoleImpl.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/PartnerLinkPartnerRoleImpl.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/PartnerRoleMessageExchangeImpl.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/ProcessAndInstanceManagementImpl.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/WorkEvent.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/cron/CronScheduler.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/cron/SystemSchedulesConfig.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/migration/MigrationHandler.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/extvar/jdbc/JdbcExternalVariableModule.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/memdao/CorrelatorDaoImpl.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/memdao/MessageExchangeDAOImpl.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/memdao/ProcessInstanceDaoImpl.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/memdao/ProcessManagementDaoImpl.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/ACTIVITYGUARD.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/ASSIGN.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/BpelRuntimeContext.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/EH_ALARM.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/EH_EVENT.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/ExprEvaluationContextImpl.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/INVOKE.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/PICK.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/PropertyAliasEvaluationContext.java
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/WAIT.java
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/elang/xpath20/runtime/MockCompilerContext.java
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/elang/xpath20/runtime/XPath20ExpressionRuntimeTest.java
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/runtime/ActivityRecoveryTest.java
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/runtime/CoreBpelTest.java
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/runtime/MockBpelServer.java
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/runtime/ProcessManagementTest.java
branches/ODE/ODE-1.x/bpel-runtime/src/test/resources/log4j.properties
branches/ODE/ODE-1.x/bpel-runtime/src/test/resources/recovery/deploy.xml
branches/ODE/ODE-1.x/bpel-runtime/src/test/resources/recovery/failure-to-fault.bpel
branches/ODE/ODE-1.x/bpel-schemas/src/main/xsd/dd.xsd
branches/ODE/ODE-1.x/bpel-schemas/src/main/xsd/pmapi.xsd
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/xsd-import/helloworld-Server.bpel
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/xsd-import/helloworld-Server.wsdl
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/xsd-import/helloworld.wsdl
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/xsd-import/message.xsd
branches/ODE/ODE-1.x/bpel-store/src/main/java/org/apache/ode/store/DeploymentUnitDir.java
branches/ODE/ODE-1.x/bpel-store/src/main/java/org/apache/ode/store/ProcessConfImpl.java
branches/ODE/ODE-1.x/bpel-store/src/main/java/org/apache/ode/store/ProcessStoreImpl.java
branches/ODE/ODE-1.x/bpel-store/src/main/java/org/apache/ode/store/jpa/DbConfStoreConnectionFactory.java
branches/ODE/ODE-1.x/bpel-test/src/main/java/org/apache/ode/test/BPELTestAbstract.java
branches/ODE/ODE-1.x/bpel-test/src/test/java/org/apache/ode/test/MessageRouting20Test.java
branches/ODE/ODE-1.x/bpel-test/src/test/java/org/apache/ode/test/PubSubTest.java
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/FaultService/faultService.wsdl
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/NegativeCorrelationTest/NegativeCorrelationTest.bpel
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/NegativeCorrelationTest/NegativeCorrelationTest.wsdl
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/NegativeInitializationTest/NegativeInitializationTest.bpel
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/NegativeInitializationTest/NegativeInitializationTest.wsdl
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/NegativeTargetNSTest1/NegativeTargetNSTest1.bpel
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/NegativeTargetNSTest1/NegativeTargetNSTest1.wsdl
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/ProbeService/probeService.wsdl
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAlarm/HandleTimer-Timer.bpel
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAssignDate/NewDiagram-Pool.bpel
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAssignMissingData/deploy.xml
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestCorrelationMultiNegative/deploy.xml
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestCorrelationMultiNegative/testCorrelation.bpel
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestDuration/BugCastDayTimeDurationToDuration-Pool.bpel
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestInsertMissingData/TestInsertMissingData.bpel
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestInsertMissingData/TestInsertMissingData.wsdl
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestInsertMissingData/deploy.xml
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestInsertMissingData/test1.properties
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/PickProcess.bpel
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/PickService.wsdl
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/dealDeck.xml
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/deploy.xml
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/pickClub.xml
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/pickDiamond.xml
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/pickHeart.xml
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/pickSpade.xml
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestXQueryExpression/HelloXQueryWorld.bpel
branches/ODE/ODE-1.x/bpel-test/src/test/resources/log4j.properties
branches/ODE/ODE-1.x/dao-hibernate-db/src/main/sql/common.sql
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/SessionManager.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/ActivityRecoveryDaoImpl.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/BpelDAOConnectionImpl.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/CorrelatorDaoImpl.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/CriteriaBuilder.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/FaultDAOImpl.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/HibernateDao.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/MessageDaoImpl.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/MessageExchangeDaoImpl.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/PartnerLinkDAOImpl.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/ProcessDaoImpl.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/ProcessInstanceDaoImpl.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/ProcessManagementDaoImpl.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/ScopeDaoImpl.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/XmlDataDaoImpl.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HActivityRecovery.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HBpelEvent.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HCorrelationProperty.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HCorrelatorSelector.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HFaultData.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HLargeData.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HMessage.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HMessageExchange.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HObject.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HPartnerLink.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HProcessInstance.java
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HXmlData.java
branches/ODE/ODE-1.x/dao-hibernate/src/test/java/org/apache/ode/daohib/bpel/BaseTestDAO.java
branches/ODE/ODE-1.x/dao-jpa-ojpa-derby/src/main/scripts/common.sql
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/BPELDAOConnectionFactoryImpl.java
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/CorrelatorDAOImpl.java
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/MessageDAOImpl.java
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/MessageExchangeDAOImpl.java
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/ProcessInstanceDAOImpl.java
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/ProcessManagementDAOImpl.java
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/XmlDataDAOImpl.java
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/EndpointReferenceContextImpl.java
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/JbiEndpointReference.java
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeComponent.java
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeConfigProperties.java
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeConsumer.java
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeContext.java
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeLifeCycle.java
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeSUManager.java
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeService.java
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeServiceUnit.java
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/ServiceBridge.java
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/msgmap/JbiWsdl11WrapperMapper.java
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/msgmap/ServiceMixMapper.java
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/ExtVarJbiTest.java
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/HelloWorldJbiTest.java
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/JbiTestBase.java
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/OdeJbiComponentLifeCycleTest.java
branches/ODE/ODE-1.x/jbi/src/test/resources/ExtVarJbiTest/smx.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/HelloWorldJbiTest/HelloWorld2.bpel
branches/ODE/ODE-1.x/jbi/src/test/resources/HelloWorldJbiTest/HelloWorld2.wsdl
branches/ODE/ODE-1.x/jbi/src/test/resources/HelloWorldJbiTest/smx.xml
branches/ODE/ODE-1.x/jbi/src/test/resources/HelloWorldJbiTest/test.properties
branches/ODE/ODE-1.x/jbi/src/test/resources/log4j.properties
branches/ODE/ODE-1.x/scheduler-simple/src/main/java/org/apache/ode/scheduler/simple/DatabaseDelegate.java
branches/ODE/ODE-1.x/scheduler-simple/src/main/java/org/apache/ode/scheduler/simple/JdbcDelegate.java
branches/ODE/ODE-1.x/scheduler-simple/src/main/java/org/apache/ode/scheduler/simple/Job.java
branches/ODE/ODE-1.x/scheduler-simple/src/main/java/org/apache/ode/scheduler/simple/SimpleScheduler.java
branches/ODE/ODE-1.x/scheduler-simple/src/test/java/org/apache/ode/scheduler/simple/DelegateSupport.java
branches/ODE/ODE-1.x/scheduler-simple/src/test/java/org/apache/ode/scheduler/simple/RetriesTest.java
branches/ODE/ODE-1.x/tasks/derby.rake
branches/ODE/ODE-1.x/tasks/jbi.rake
branches/ODE/ODE-1.x/tasks/nativedb.rake
branches/ODE/ODE-1.x/tools/src/main/java/org/apache/ode/tools/bpelc/BpelCompileCommand.java
branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/DOMUtils.java
branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/GUID.java
branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/Properties.java
branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/WatchDog.java
branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/xsd/SchemaModelImpl.java
branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/xsd/XSUtils.java
branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/xsl/XslTransformHandler.java
branches/ODE/ODE-1.x/utils/src/test/java/org/apache/ode/utils/xsd/SchemaCaptureTest.java
Log:
merging in the changes from ODE-1.3.3 to ODE-1.x (rev 933917), ODE is close to a 1.3.4
release.
Property changes on: branches/ODE/ODE-1.x
___________________________________________________________________
Name: svn:ignore
+ .project
Modified: branches/ODE/ODE-1.x/.project
===================================================================
--- branches/ODE/ODE-1.x/.project 2010-04-14 15:43:12 UTC (rev 619)
+++ branches/ODE/ODE-1.x/.project 2010-04-14 18:25:55 UTC (rev 620)
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
- <name>ODE-1.x</name>
+ <name>riftsaw-ODE-1.x</name>
<comment></comment>
<projects>
</projects>
Modified: branches/ODE/ODE-1.x/RELEASE_NOTES
===================================================================
--- branches/ODE/ODE-1.x/RELEASE_NOTES 2010-04-14 15:43:12 UTC (rev 619)
+++ branches/ODE/ODE-1.x/RELEASE_NOTES 2010-04-14 18:25:55 UTC (rev 620)
@@ -2,11 +2,10 @@
Apache ODE Release Notes
========================
-Apache ODE 1.3.3 is a security release for the process deployment web
-service, which was sensible to deployment messages with forged names.
-It also includes a few bug fixes and improvements.
+Apache ODE 1.3.2 includes about 130 bug fixes and new features.
+It's also the most stable version of ODE released so far.
-Apache ODE 1.3.3 requires Java 1.5.x. The WAR distribution can run in
+Apache ODE 1.3.2 requires Java 1.5.x. The WAR distribution can run in
most J2EE servlet container. The JBI distribution should be able to
run in any JBI container but has only been tested with ServiceMix
3.1 so far. See the BUILDING file if you want to build your own
@@ -17,5 +16,5 @@
See our Jira for more information:
-https://issues.apache.org/jira/secure/IssueNavigator.jspa?reset=true&&pid=12310270&status=5&status=6&fixfor=12313905&sorter/field=priority&sorter/order=DESC
+https://issues.apache.org/jira/browse/ODE/fixforversion/12313906
Modified: branches/ODE/ODE-1.x/Rakefile
===================================================================
--- branches/ODE/ODE-1.x/Rakefile 2010-04-14 15:43:12 UTC (rev 619)
+++ branches/ODE/ODE-1.x/Rakefile 2010-04-14 18:25:55 UTC (rev 620)
@@ -14,7 +14,7 @@
# limitations under the License.
#
-gem "buildr", "~>1.2.4"
+gem "buildr", "~>1.3"
require "buildr"
require "buildr/xmlbeans.rb"
require "buildr/openjpa"
@@ -22,145 +22,27 @@
require "buildr/jetty"
require "buildr/hibernate"
+require File.join(File.dirname(__FILE__), 'repositories.rb')
+require File.join(File.dirname(__FILE__), 'dependencies.rb')
+
# Keep this structure to allow the build system to update version numbers.
-VERSION_NUMBER = "1.3.3"
-NEXT_VERSION = "1.3.3"
+VERSION_NUMBER = "1.3.4-SNAPSHOT"
-ANNONGEN = "annogen:annogen:jar:0.1.0"
-ANT = "ant:ant:jar:1.6.5"
-AXIOM = [ group("axiom-api", "axiom-impl",
"axiom-dom",
- :under=>"org.apache.ws.commons.axiom",
:version=>"1.2.5") ]
-AXIS2_ALL = group("axis2-adb", "axis2-codegen",
"axis2-kernel",
- "axis2-java2wsdl", "axis2-jibx",
"axis2-saaj", "axis2-xmlbeans",
- :under=>"org.apache.axis2",
:version=>"1.3")
-AXIS2_TEST = group("httpcore", "httpcore-nio",
"httpcore-niossl",
- :under=>"org.apache.httpcomponents",
:version=>"4.0-alpha5")
-AXIS2_MODULES = struct(
- :mods => ["org.apache.rampart:rampart:mar:1.3",
- "org.apache.rampart:rahas:mar:1.3",
- "org.apache.axis2:addressing:mar:1.3"],
- :libs => [group("rampart-core", "rampart-policy",
"rampart-trust",
- :under=>"org.apache.rampart",
- :version=>"1.3"),
- "org.apache.ws.security:wss4j:jar:1.5.3",
- "org.apache.santuario:xmlsec:jar:1.4.0",
- "opensaml:opensaml:jar:1.1",
- "bouncycastle:bcprov-jdk15:jar:132"]
-)
-AXIS2_WAR = "org.apache.axis2:axis2-webapp:war:1.3"
-BACKPORT =
"backport-util-concurrent:backport-util-concurrent:jar:3.0"
-COMMONS = struct(
- :codec =>"commons-codec:commons-codec:jar:1.3",
- :collections =>"commons-collections:commons-collections:jar:3.1",
- :dbcp =>"commons-dbcp:commons-dbcp:jar:1.2.1",
- :fileupload =>"commons-fileupload:commons-fileupload:jar:1.1.1",
- :httpclient =>"commons-httpclient:commons-httpclient:jar:3.0",
- :lang =>"commons-lang:commons-lang:jar:2.3",
- :logging =>"commons-logging:commons-logging:jar:1.1",
- :io =>"commons-io:commons-io:jar:1.4",
- :pool =>"commons-pool:commons-pool:jar:1.2",
- :primitives =>"commons-primitives:commons-primitives:jar:1.0"
-)
-DERBY = "org.apache.derby:derby:jar:10.4.1.3"
-DERBY_TOOLS = "org.apache.derby:derbytools:jar:10.4.1.3"
-DOM4J = "dom4j:dom4j:jar:1.6.1"
-GERONIMO = struct(
- :kernel
=>"org.apache.geronimo.modules:geronimo-kernel:jar:2.0.1",
- :transaction
=>"org.apache.geronimo.components:geronimo-transaction:jar:2.0.1",
- :connector
=>"org.apache.geronimo.components:geronimo-connector:jar:2.0.1"
-)
-HIBERNATE = [ "org.hibernate:hibernate:jar:3.2.5.ga",
"asm:asm:jar:1.5.3",
- "antlr:antlr:jar:2.7.6",
"cglib:cglib:jar:2.1_3", "net.sf.ehcache:ehcache:jar:1.2.3" ]
-HSQLDB = "hsqldb:hsqldb:jar:1.8.0.7"
-JAVAX = struct(
- :activation =>"javax.activation:activation:jar:1.1",
- #:activation
=>"geronimo-spec:geronimo-spec-activation:jar:1.0.2-rc4",
- :connector
=>"org.apache.geronimo.specs:geronimo-j2ee-connector_1.5_spec:jar:1.0",
- :ejb
=>"org.apache.geronimo.specs:geronimo-ejb_2.1_spec:jar:1.1",
- :javamail =>"geronimo-spec:geronimo-spec-javamail:jar:1.3.1-rc5",
- :jms =>"geronimo-spec:geronimo-spec-jms:jar:1.1-rc4",
- :persistence =>"javax.persistence:persistence-api:jar:1.0",
- :servlet
=>"org.apache.geronimo.specs:geronimo-servlet_2.4_spec:jar:1.0",
- :stream =>"stax:stax-api:jar:1.0.1",
- :transaction
=>"org.apache.geronimo.specs:geronimo-jta_1.1_spec:jar:1.1",
- :resource
=>"org.apache.geronimo.specs:geronimo-j2ee-connector_1.5_spec:jar:1.0"
-)
-JAXEN = "jaxen:jaxen:jar:1.1.1"
-JBI = group("org.apache.servicemix.specs.jbi-api-1.0",
:under=>"org.apache.servicemix.specs", :version=>"1.1.0")
-JENCKS = "org.jencks:jencks:jar:all:1.3"
-JIBX = "jibx:jibx-run:jar:1.1-beta3"
-LOG4J = "log4j:log4j:jar:1.2.13"
-OPENJPA = ["org.apache.openjpa:openjpa:jar:1.3.0-SNAPSHOT",
- "net.sourceforge.serp:serp:jar:1.13.1"]
+BUNDLE_VERSIONS = {
+ "ode.version" => VERSION_NUMBER,
+ "commons.collections.version" => artifact(COMMONS.collections).version,
+ "commons.httpclient.bundle.version" => "3.1_1",
+ "commons.lang.version" => artifact(COMMONS.lang).version,
+ "commons.pool.version" => artifact(COMMONS.pool).version,
+ "derby.version" => artifact(DERBY).version,
+ "geronimo.specs.version" => "1.1.1",
+ "servicemix.nmr.version" => "1.1.0-SNAPSHOT",
+ "servicemix.shared.version" => "2009.02-SNAPSHOT",
+ "servicemix.specs.version" => "1.4-SNAPSHOT",
+}
+Release.find.tag_name = lambda { |version| "APACHE_ODE_#{version.upcase}" } if
Release.find
-SAXON = group("saxon", "saxon-xpath",
"saxon-dom", "saxon-xqj", :under=>"net.sf.saxon",
:version=>"9.x")
-SERVICEMIX = [
- group("servicemix-core",
- :under=>"org.apache.servicemix",
:version=>"3.3"),
- group("servicemix-soap", "servicemix-common",
"servicemix-shared", "servicemix-http", "servicemix-eip",
- :under=>"org.apache.servicemix",
:version=>"2008.01"),
- group("servicemix-utils",
- :under=>"org.apache.servicemix",
:version=>"1.0.0"),
- "commons-httpclient:commons-httpclient:jar:3.0",
- "org.mortbay.jetty:jetty:jar:6.1.12rc1",
- "org.mortbay.jetty:jetty-client:jar:6.1.12rc1",
- "org.mortbay.jetty:jetty-sslengine:jar:6.1.12rc1",
- "org.mortbay.jetty:servlet-api-2.5:jar:6.1.12rc1",
- "org.mortbay.jetty:jetty-util:jar:6.1.12rc1",
- "org.codehaus.woodstox:wstx-asl:jar:3.2.2",
-
"org.apache.geronimo.specs:geronimo-activation_1.1_spec:jar:1.0.1",
-
"org.apache.geronimo.specs:geronimo-annotation_1.0_spec:jar:1.1",
-
"org.apache.geronimo.specs:geronimo-javamail_1.4_spec:jar:1.2",
-
"org.apache.geronimo.specs:geronimo-stax-api_1.0_spec:jar:1.0.1",
-
"org.apache.geronimo.specs:geronimo-jms_1.1_spec:jar:1.1",
- "org.jencks:jencks:jar:2.1",
- "org.objectweb.howl:howl:jar:1.0.1-1",
- "org.apache.activemq:activemq-core:jar:4.1.1",
- "org.apache.activemq:activemq-ra:jar:4.1.1",
- "commons-beanutils:commons-beanutils:jar:1.7.0",
- "tranql:tranql-connector-derby-common:jar:1.1"
- ]
-SPRING = ["org.springframework:spring:jar:2.5.6"]
-TRANQL = [ "tranql:tranql-connector:jar:1.1",
"axion:axion:jar:1.0-M3-dev", COMMONS.primitives ]
-WOODSTOX = "woodstox:wstx-asl:jar:3.2.1"
-WSDL4J = "wsdl4j:wsdl4j:jar:1.6.1"
-XALAN = "org.apache.ode:xalan:jar:2.7.0-2"
-XERCES = "xerces:xercesImpl:jar:2.9.0"
-XSTREAM = "xstream:xstream:jar:1.2"
-WS_COMMONS = struct(
- :axiom =>AXIOM,
- :neethi =>"org.apache.neethi:neethi:jar:2.0.2",
- :xml_schema =>"org.apache.ws.commons.schema:XmlSchema:jar:1.3.2"
-)
-XBEAN = [
- "org.apache.xbean:xbean-kernel:jar:3.3",
- "org.apache.xbean:xbean-server:jar:3.3",
- "org.apache.xbean:xbean-spring:jar:3.4.3",
- "org.apache.xbean:xbean-classloader:jar:3.4.3"
-]
-XMLBEANS = "org.apache.xmlbeans:xmlbeans:jar:2.3.0"
-
-repositories.remote << "http://www.intalio.org/public/maven2"
-repositories.remote <<
"http://people.apache.org/repo/m2-incubating-repository"
-repositories.remote << "http://repo1.maven.org/maven2"
-repositories.remote <<
"http://people.apache.org/repo/m2-snapshot-repository"
-repositories.remote << "http://download.java.net/maven/2"
-repositories.remote << "http://ws.zones.apache.org/repository2"
-repositories.release_to[:url] ||= "sftp://guest@localhost/home/guest"
-
-# Changing releases tag names
-class Release
- class << self
- def tag_with_apache_ode(version)
- tag_without_apache_ode("APACHE_ODE_#{version.upcase}")
- end
- alias_method_chain :tag, :apache_ode
- end
-end
-
-
desc "Apache ODE"
-#define "ode", :group=>"org.apache.ode",
:version=>VERSION_NUMBER do
define "ode" do
project.version = VERSION_NUMBER
project.group = "org.apache.ode"
@@ -190,7 +72,7 @@
"bpel-epr", "bpel-obj", "bpel-ql",
"bpel-runtime", "scheduler-simple",
"bpel-schemas", "bpel-store", "dao-hibernate",
"jacob", "jca-ra", "jca-server",
"utils", "dao-jpa", "agents"),
- AXIS2_ALL, ANNONGEN, BACKPORT, COMMONS.codec, COMMONS.collections,
COMMONS.fileupload, COMMONS.io, COMMONS.httpclient,
+ AXIS2_ALL, ANNONGEN, BACKPORT, COMMONS.codec, COMMONS.collections,
COMMONS.fileupload, COMMONS.io, COMMONS.httpclient, COMMONS.beanutils,
COMMONS.lang, COMMONS.logging, COMMONS.pool, DERBY, DERBY_TOOLS, JAXEN,
JAVAX.activation, JAVAX.ejb, JAVAX.javamail,
JAVAX.connector, JAVAX.jms, JAVAX.persistence, JAVAX.transaction, JAVAX.stream,
JIBX,
GERONIMO.connector, GERONIMO.kernel, GERONIMO.transaction, LOG4J, OPENJPA, SAXON,
TRANQL,
@@ -229,7 +111,8 @@
rm_rf Dir[_(webapp_dir) + "/**/.svn"]
cp_r _("src/test/webapp"), test.compile.target.to_s
rm_rf Dir[_(webapp_dir) + "/**/.svn"]
- cp Dir[_("src/main/webapp/WEB-INF/classes/*")], test.compile.target.to_s
+ cp_r Dir[_("src/main/webapp/WEB-INF/classes/*")],
test.compile.target.to_s
+ rm_rf Dir[_(webapp_dir) + "/**/.svn"]
cp Dir[project("axis2").path_to("src/main/wsdl/*")],
"#{webapp_dir}/WEB-INF"
cp project("bpel-schemas").path_to("src/main/xsd/pmapi.xsd"),
"#{webapp_dir}/WEB-INF"
rm_rf Dir[_(webapp_dir) + "/**/.svn"]
@@ -243,7 +126,8 @@
end
test.setup
unzip("#{webapp_dir}/WEB-INF"=>project("dao-jpa-ojpa-derby").package(:zip))
test.setup
unzip("#{webapp_dir}/WEB-INF"=>project("dao-hibernate-db").package(:zip))
-
+ test.exclude('*') if Buildr.environment == 'hudson'
+
NativeDB.prepare_configs test, _(".")
test.setup
WSSecurity.prepare_secure_services_tests("#{test.resources.target}/TestRampartBasic/secured-services",
"sample*.axis2", AXIS2_MODULES.mods)
@@ -271,6 +155,7 @@
COMMONS.logging, JAVAX.stream, JAXEN, SAXON, WSDL4J, XALAN, XERCES,
COMMONS.collections
test.resources {
filter(project("bpel-scripts").path_to("src/main/resources")).into(test.resources.target).run
}
package :jar
+ test.with SLF4J, LOG4J
end
desc "ODE JCA Connector Implementation"
@@ -288,7 +173,7 @@
desc "ODE Interface Layers Common"
define "bpel-epr" do
compile.with projects("utils", "bpel-dao",
"bpel-api"),
- AXIOM, COMMONS.lang, COMMONS.logging, DERBY, JAVAX.connector, JAVAX.stream,
JAVAX.transaction, GERONIMO.transaction, GERONIMO.connector, TRANQL, XMLBEANS
+ AXIOM, COMMONS.lang, COMMONS.logging, COMMONS.beanutils, DERBY, JAVAX.connector,
JAVAX.stream, JAVAX.transaction, GERONIMO.transaction, GERONIMO.connector, TRANQL,
XMLBEANS
package :jar
end
@@ -318,17 +203,19 @@
test.with projects("scheduler-simple", "dao-jpa",
"dao-hibernate", "bpel-epr"),
BACKPORT, COMMONS.pool, COMMONS.lang, DERBY, JAVAX.connector, JAVAX.transaction,
GERONIMO.transaction, GERONIMO.kernel, GERONIMO.connector, TRANQL, HSQLDB,
JAVAX.ejb,
- LOG4J, XERCES, Buildr::OpenJPA::REQUIRES, XALAN
+ OPENJPA, XERCES, XALAN, LOG4J, SLF4J,
+ DOM4J, HIBERNATE,
+ "tranql:tranql-connector-derby-common:jar:1.1"
package :jar
end
desc "ODE Simple Scheduler"
define "scheduler-simple" do
- compile.with projects("bpel-api", "utils"), COMMONS.collections,
COMMONS.logging, JAVAX.transaction
+ compile.with projects("bpel-api", "utils"), COMMONS.collections,
COMMONS.logging, JAVAX.transaction, LOG4J
test.compile.with HSQLDB, GERONIMO.kernel, GERONIMO.transaction
test.with HSQLDB, JAVAX.transaction, JAVAX.resource, JAVAX.connector, LOG4J,
- GERONIMO.kernel, GERONIMO.transaction, BACKPORT, JAVAX.ejb
+ GERONIMO.kernel, GERONIMO.transaction, GERONIMO.connector, TRANQL, BACKPORT,
JAVAX.ejb
package :jar
end
@@ -360,7 +247,7 @@
define "bpel-test" do
compile.with projects("bpel-api", "bpel-compiler",
"bpel-dao", "bpel-runtime",
"bpel-store", "utils", "bpel-epr",
"dao-jpa", "agents"),
- DERBY, Java::JUnit::JUNIT_REQUIRES, JAVAX.persistence, OPENJPA, WSDL4J,
COMMONS.httpclient,
+ DERBY, JUnit.dependencies, JAVAX.persistence, OPENJPA, WSDL4J, COMMONS.httpclient,
COMMONS.codec
test.with projects("bpel-obj", "jacob",
"bpel-schemas",
@@ -378,16 +265,17 @@
resources hibernate_doclet(:package=>"org.apache.ode.daohib.bpel.hobj",
:excludedtags=>"@version,@author,@todo")
# doclet does not support not-found="ignore"
- build {
+ task "hbm-hack" do |task|
process_instance_hbm_file =
project.path_to("target/classes/org/apache/ode/daohib/bpel/hobj/HProcessInstance.hbm.xml")
process_instance_hbm = File.read(process_instance_hbm_file)
if !process_instance_hbm.include? "not-found=\"ignore\""
process_instance_hbm.insert(process_instance_hbm.index("class=\"org.apache.ode.daohib.bpel.hobj.HProcess\"")
- 1, "not-found=\"ignore\" ")
File.open(process_instance_hbm_file, "w") { |f| f <<
process_instance_hbm }
end
- }
+ end
+ task "compile" => "hbm-hack"
- test.with project("bpel-epr"), BACKPORT, COMMONS.collections, COMMONS.lang,
HSQLDB,
+ test.with project("bpel-epr"), BACKPORT, COMMONS.collections, COMMONS.lang,
DERBY, COMMONS.logging, LOG4J, SLF4J,
GERONIMO.transaction, GERONIMO.kernel, GERONIMO.connector, JAVAX.connector,
JAVAX.ejb, SPRING
package :jar
@@ -402,7 +290,7 @@
bpel_store = project("bpel-store").compile.target
Buildr::Hibernate::REQUIRES[:xdoclet] = Buildr.group("xdoclet",
"xdoclet-xdoclet-module", "xdoclet-hibernate-module",
- :under=>"xdoclet", :version=>"1.2.3") +
["xdoclet:xjavadoc:jar:1.1-j5"]
+ :under=>"xdoclet", :version=>"1.2.3") +
["xdoclet:xjavadoc:jar:1.1-j5"] + projects("dao-hibernate")
export = lambda do |properties, source, target|
file(target=>[properties, source]) do |task|
@@ -487,7 +375,6 @@
desc "ODE Jacob APR Code Generation"
define "jacob-ap" do
- compile.with Java.tools_jar
package :jar
end
@@ -507,7 +394,7 @@
ANT, AXIOM, BACKPORT, COMMONS.codec, COMMONS.collections, COMMONS.dbcp,
COMMONS.lang, COMMONS.pool,
COMMONS.primitives, DERBY, GERONIMO.connector, GERONIMO.transaction, JAXEN,
JAVAX.connector,
JAVAX.ejb, JAVAX.jms, JAVAX.persistence, JAVAX.stream, JAVAX.transaction, LOG4J,
OPENJPA,
- SAXON, TRANQL, XALAN, XERCES, XMLBEANS, XSTREAM, WSDL4J)
+ SAXON, TRANQL, XALAN, XERCES, XMLBEANS, WSDL4J)
jbi.component :type=>:service_engine, :name=>"OdeBpelEngine",
:description=>self.comment
jbi.component :class_name=>"org.apache.ode.jbi.OdeComponent",
:libs=>libs
@@ -517,25 +404,86 @@
jbi.include path_to("src/main/jbi/ode-jbi.properties")
end
- test.using :properties=>{ "java.naming.factory.initial" =>
"org.apache.xbean.spring.jndi.SpringInitialContextFactory"}
+ test.using :properties=>{ "java.naming.factory.initial" =>
"org.apache.xbean.spring.jndi.SpringInitialContextFactory"},
:java_args=>ENV['TEST_JVM_ARGS']
test.with projects("dao-jpa", "dao-hibernate",
"bpel-compiler", "bpel-api-jca", "jca-ra",
"jca-server", "jacob"),
- BACKPORT, COMMONS.lang, COMMONS.collections, DERBY, GERONIMO.connector,
GERONIMO.kernel,
+ BACKPORT, COMMONS.lang, COMMONS.io, COMMONS.collections, DERBY, GERONIMO.connector,
GERONIMO.kernel,
GERONIMO.transaction, JAVAX.connector, JAVAX.ejb, JAVAX.persistence, JAVAX.stream,
JAVAX.transaction, JAXEN, JBI, OPENJPA, SAXON, SERVICEMIX, SPRING, TRANQL,
- XALAN, XBEAN, XMLBEANS, XSTREAM,
- LOG4J
+ XALAN, XBEAN, XMLBEANS,
+ SLF4J,
+ LOG4J,
+ DOM4J,
+ HIBERNATE
test.setup
unzip(_("target/test/smx/ode")=>project("dao-jpa-ojpa-derby").package(:zip))
test.setup
unzip(_("target/test/smx/ode")=>project("dao-hibernate-db").package(:zip))
test.setup task(:prepare_jbi_tests) do |task|
- cp _("src/main/jbi/ode-jbi.properties"),
_("target/test/smx/ode")
+ cp _("src/test/jbi/ode-jbi.properties"),
_("target/test/smx/ode")
cp _("src/main/jbi/hibernate.properties"),
_("target/test/smx/ode")
rm_rf Dir["target/test/resources"]
cp_r _("src/test/resources"), _("target/test/resources")
end
end
+# desc "ODE Commmands for Karaf"
+# define "jbi-karaf-commands" do
+# compile.with projects("bpel-schemas", "jbi"), JBI, KARAF,
XMLBEANS, COMMONS.logging
+# libs = artifacts(projects("bpel-schemas", "jbi"), JBI, KARAF,
XMLBEANS, COMMONS.logging)
+# package(:bundle).tap do |bnd|
+# bnd.bnd_file = _("org.apache.ode.commands.bnd")
+# bnd.sourcepath = _("src/main/java")
+# bnd.classpath = _("target/classes") + File::PATH_SEPARATOR +
libs.join(File::PATH_SEPARATOR)
+# bnd.properties.update(BUNDLE_VERSIONS)
+# end
+# end
+#
+# desc "ODE JBI Packaging for Karaf"
+# define "jbi-karaf" do
+# ode_libs = artifacts(projects("bpel-api", "bpel-api-jca",
"bpel-compiler", "bpel-connector", "bpel-dao",
+# "bpel-epr", "jca-ra",
"jca-server", "bpel-obj", "bpel-ql",
"bpel-runtime",
+# "scheduler-simple",
"bpel-schemas", "bpel-store", "dao-hibernate",
"dao-jpa",
+# "jacob", "jacob-ap",
"utils", "agents"))
+# libs = artifacts(ANT, AXIOM, BACKPORT, COMMONS.codec, COMMONS.collections,
COMMONS.dbcp, COMMONS.lang, COMMONS.pool,
+# COMMONS.primitives, DERBY, GERONIMO.connector,
GERONIMO.transaction, JAXEN, JAVAX.connector,
+# JAVAX.ejb, JAVAX.jms, JAVAX.persistence, JAVAX.stream,
JAVAX.transaction, LOG4J, OPENJPA,
+# SAXON, TRANQL, XALAN, XERCES, XMLBEANS, WSDL4J)
+# package(:bundle).tap do |bnd|
+# bnd.bnd_file = _("bnd.bnd")
+# bnd.classpath = (ode_libs + artifacts(project("jbi").package(:jar)) +
libs).join(File::PATH_SEPARATOR)
+# bnd.properties.update(BUNDLE_VERSIONS)
+#
+# # inline log4j helper classes
+# bnd.properties["log4j.jar"] = artifact(LOG4J).to_s
+#
+# # inline dao zip files
+# zips = artifacts(project("dao-hibernate-db").package(:zip),
project("dao-jpa-ojpa-derby").package(:zip))
+# inlines = zips.map{|item| "@" + item.to_s}
+# bnd.properties["inlines"] = inlines.join(', ')
+#
+# # embed jars
+# bnd_libs = ode_libs + artifacts(AXIOM, BACKPORT, GERONIMO.connector, JAXEN,
+# JAVAX.connector, JAVAX.persistence, JAVAX.ejb,
+# OPENJPA, SAXON, TRANQL,
+# XALAN, XERCES, XMLBEANS, WSDL4J)
+# includes = bnd_libs.map{|item| File.basename(item.to_s)}
+# bnd.properties["includes"] = includes.join(', ')
+# end
+#
+# # Generate features.xml
+# def package_as_feature(file_name)
+# file file_name => [_("src/main/filtered-resources/features.xml")]
do
+#
filter(_("src/main/filtered-resources")).include("features.xml").into(_("target")).using(BUNDLE_VERSIONS).run
+# mv _("target/features.xml"), file_name
+# end
+# end
+# def package_as_feature_spec(spec)
+# spec.merge({ :type=>:xml, :classifier=>'features' })
+# end
+# package(:feature)
+#
+# end
+
desc "ODE JCA Resource Archive"
define "jca-ra" do
compile.with project("utils"), JAVAX.connector
@@ -557,8 +505,8 @@
desc "ODE Utils"
define "utils" do
compile.with AXIOM, AXIS2_ALL, COMMONS.lang, COMMONS.collections, COMMONS.logging,
COMMONS.pool, COMMONS.httpclient, COMMONS.codec, LOG4J, XERCES, JAVAX.stream, WSDL4J,
SAXON
- # env variable requires by HierarchicalPropertiesTest
- ENV['TEST_DUMMY_ENV_VAR'] = "42"
+ # env variable required by HierarchicalPropertiesTest
+ test.using :environment=>{ 'TEST_DUMMY_ENV_VAR'=>42}
test.exclude "*TestResources"
package :jar
end
@@ -566,7 +514,7 @@
desc "ODE Agents"
define "agents" do
compile
- package(:jar, :manifest=>_("target/classes/META-INF/MANIFEST.MF"))
+ package(:jar).with
:manifest=>_("src/main/resources/META-INF/MANIFEST.MF")
end
end
@@ -600,16 +548,22 @@
end
# Tools scripts (like bpelc and sendsoap)
- mkdir_p project.path_to("target/bin")
- mkpath _("target/bin")
- cp Dir[project.path_to("src/bin/*")],
project.path_to("target/bin")
- chmod 0755, FileList[project.path_to("target/bin") + "/*"],
:verbose=>false
- zip.include(project.path_to("target/bin"))
+ bins =
file(project.path_to("target/bin")=>FileList[project.path_to("src/bin/*")])
do |task|
+ mkdir_p project.path_to("target/bin")
+ mkpath task.name
+ cp task.prerequisites, task.name
+ chmod 0755, FileList[task.name + "/*"], :verbose=>false
+ end
+ bins.invoke
+ zip.include bins
yield zip
project.check zip, "should contain mysql.sql" do
it.should contain("sql/mysql.sql")
end
+ project.check zip, "should contain sendsoap.bat" do
+ it.should contain("bin/sendsoap.bat")
+ end
end
end
end
Added: branches/ODE/ODE-1.x/agents/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/agents/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/agents/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,33 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-agents</artifactId>
+ <name>ODE :: Agents</name>
+ <packaging>jar</packaging>
+ <modelVersion>4.0.0</modelVersion>
+
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+</project>
Added: branches/ODE/ODE-1.x/axis2/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/axis2/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/axis2/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,129 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-axis2</artifactId>
+ <name>ODE :: AXIS2</name>
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <properties>
+ <rampart.version>1.4</rampart.version>
+ <servlet.version>2.4</servlet.version>
+ </properties>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-compiler</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-connector</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-dao</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-epr</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-runtime</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-tools</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-scheduler-simple</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-store</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-schemas</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-utils</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>javax.servlet</groupId>
+ <artifactId>servlet-api</artifactId>
+ <version>${servlet.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.rampart</groupId>
+ <artifactId>rampart-core</artifactId>
+ <version>${rampart.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.rampart</groupId>
+ <artifactId>rampart-policy</artifactId>
+ <version>${rampart.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.rampart</groupId>
+ <artifactId>rampart-trust</artifactId>
+ <version>${rampart.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.components</groupId>
+ <artifactId>geronimo-transaction</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+
+
+ <build>
+ <plugins>
+ <plugin>
+ <artifactId>maven-surefire-plugin</artifactId>
+ <configuration>
+ <excludes>
+ <exclude>**/ProcessManagementTest.java</exclude>
+ <exclude>**/ExecutionPathTest.java</exclude>
+ </excludes>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+</project>
Modified:
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/BindingContextImpl.java
===================================================================
---
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/BindingContextImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/BindingContextImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -204,10 +204,10 @@
try {
if (WsdlUtils.useHTTPBinding(def, serviceName, portName)) {
if (__log.isDebugEnabled()) __log.debug("Creating HTTP-bound
external service " + serviceName);
- extService = new HttpExternalService(pconf, serviceName, portName,
_server._executorService, _server._scheduler, _server._bpelServer,
_server.httpConnectionManager);
+ extService = new HttpExternalService(pconf, serviceName, portName,
_server._executorService, _server._scheduler, _server._bpelServer,
_server.httpConnectionManager, _server._clusterUrlTransformer);
} else if (WsdlUtils.useSOAPBinding(def, serviceName, portName)) {
if (__log.isDebugEnabled()) __log.debug("Creating SOAP-bound
external service " + serviceName);
- extService = new SoapExternalService(pconf, serviceName, portName,
_server._executorService, _server._axisConfig, _server._scheduler, _server._bpelServer,
_server.httpConnectionManager);
+ extService = new SoapExternalService(pconf, serviceName, portName,
_server._executorService, _server._axisConfig, _server._scheduler, _server._bpelServer,
_server.httpConnectionManager, _server._clusterUrlTransformer);
}
} catch (Exception ex) {
__log.error("Could not create external service.", ex);
Modified: branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/ODEServer.java
===================================================================
---
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/ODEServer.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/ODEServer.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -23,6 +23,9 @@
import java.io.FileNotFoundException;
import java.io.IOException;
import java.io.InputStream;
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.List;
import java.util.Properties;
import java.util.StringTokenizer;
import java.util.concurrent.ExecutorService;
@@ -46,12 +49,14 @@
import org.apache.axis2.AxisFault;
import org.apache.axis2.engine.AxisConfiguration;
import org.apache.commons.httpclient.MultiThreadedHttpConnectionManager;
+import org.apache.commons.httpclient.util.IdleConnectionTimeoutThread;
import org.apache.commons.httpclient.params.HttpConnectionManagerParams;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.apache.ode.axis2.deploy.DeploymentPoller;
import org.apache.ode.axis2.service.DeploymentWebService;
import org.apache.ode.axis2.service.ManagementService;
+import org.apache.ode.axis2.util.ClusterUrlTransformer;
import org.apache.ode.bpel.connector.BpelServerConnector;
import org.apache.ode.bpel.dao.BpelDAOConnectionFactory;
import org.apache.ode.bpel.engine.BpelServerImpl;
@@ -118,8 +123,11 @@
private BpelServerConnector _connector;
private ManagementService _mgtService;
+
+ protected ClusterUrlTransformer _clusterUrlTransformer;
protected MultiThreadedHttpConnectionManager httpConnectionManager;
+ protected IdleConnectionTimeoutThread idleConnectionTimeoutThread;
public void init(ServletConfig config, AxisConfiguration axisConf) throws
ServletException {
init(config.getServletContext().getRealPath("/WEB-INF"), axisConf);
@@ -361,6 +369,14 @@
__log.error("Unable to shut down HTTP connection manager.",
t);
}
}
+ if(idleConnectionTimeoutThread!=null){
+ __log.debug("shutting down Idle Connection Timeout Thread.");
+ try {
+ idleConnectionTimeoutThread.shutdown();
+ } catch(Throwable t) {
+ __log.error("Unable to shut down Idle Connection Timeout
Thread.", t);
+ }
+ }
try {
__log.debug("cleaning up temporary files.");
TempFileManager.cleanup();
@@ -429,7 +445,10 @@
protected void initProcessStore(EndpointReferenceContext eprContext) {
_store = createProcessStore(eprContext, _db.getDataSource());
_store.registerListener(new ProcessStoreListenerImpl());
- _store.setDeployDir(new File(_workRoot, "processes"));
+ _store.setDeployDir(
+ _odeConfig.getDeployDir() != null ?
+ new File(_odeConfig.getDeployDir()) :
+ new File(_workRoot, "processes"));
_store.setConfigDir(_configRoot);
}
@@ -464,6 +483,11 @@
else
_executorService =
Executors.newFixedThreadPool(_odeConfig.getThreadPoolMaxSize(), threadFactory);
+ {
+ List<String> targets = new ArrayList<String>();
+ Collections.addAll(targets,
_odeConfig.getProperty("cluster.localRoute.targets",
"").split(","));
+ _clusterUrlTransformer = new ClusterUrlTransformer(targets,
_odeConfig.getProperty("cluster.localRoute.base",
"http://localhost:8080/ode/processes/"));
+ }
_bpelServer = new BpelServerImpl();
_scheduler = createScheduler();
_scheduler.setJobProcessor(_bpelServer);
@@ -490,6 +514,7 @@
dehy.setProcessMaxCount(_odeConfig.getDehydrationMaximumCount());
_bpelServer.setDehydrationPolicy(dehy);
}
+
_bpelServer.setMigrationTransactionTimeout(_odeConfig.getMigrationTransactionTimeout());
_bpelServer.setConfigProperties(_odeConfig.getProperties());
_bpelServer.init();
_bpelServer.setInstanceThrottledMaximumCount(_odeConfig.getInstanceThrottledMaximumCount());
@@ -516,6 +541,22 @@
}
httpConnectionManager.getParams().setDefaultMaxConnectionsPerHost(max_per_host);
httpConnectionManager.getParams().setMaxTotalConnections(max_total);
+
+ // Register the connection manager to a idle check thread
+ idleConnectionTimeoutThread = new IdleConnectionTimeoutThread();
+
idleConnectionTimeoutThread.setName("Http_Idle_Connection_Timeout_Thread");
+ long idleConnectionTimeout =
Long.parseLong(_odeConfig.getProperty("http.idle.connection.timeout",
"30000"));
+ long idleConnectionCheckInterval =
Long.parseLong(_odeConfig.getProperty("http.idle.connection.check.interval",
"30000"));
+
+ if(__log.isDebugEnabled()){
+
__log.debug("http.idle.connection.timeout="+idleConnectionTimeout);
+
__log.debug("http.idle.connection.check.interval="+idleConnectionCheckInterval);
+ }
+ idleConnectionTimeoutThread.setConnectionTimeout(idleConnectionTimeout);
+ idleConnectionTimeoutThread.setTimeoutInterval(idleConnectionCheckInterval);
+
+ idleConnectionTimeoutThread.addConnectionManager(httpConnectionManager);
+ idleConnectionTimeoutThread.start();
}
public ProcessStoreImpl getProcessStore() {
Modified: branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/ODEService.java
===================================================================
---
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/ODEService.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/ODEService.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -35,7 +35,6 @@
import org.apache.axiom.soap.SOAPEnvelope;
import org.apache.axiom.soap.SOAPFactory;
import org.apache.axiom.soap.SOAPFault;
-import org.apache.axiom.om.OMElement;
import org.apache.axis2.AxisFault;
import org.apache.axis2.client.Options;
import org.apache.axis2.context.MessageContext;
@@ -61,9 +60,6 @@
import org.w3c.dom.Document;
import org.w3c.dom.Element;
-import javax.xml.transform.dom.DOMSource;
-import java.io.IOException;
-
/**
* A running service, encapsulates the Axis service, its receivers and our
* receivers as well.
@@ -273,19 +269,7 @@
writeHeader(msgContext, mex);
break;
case FAILURE:
- if (__log.isDebugEnabled())
- __log.debug("Failure response message: " +
mex.getFault());
- OdeFault odeFault;
- String beVerbose =
_pconf.getEndpointProperties(_serviceRef).get(Properties.PROP_MEX_FAILURE_VERBOSE);
- // default is true
- if (beVerbose == null || Boolean.valueOf(beVerbose)) {
- odeFault = _converter.createOdeFault(mex.getFaultExplanation(),
mex.getFaultResponse());
- } else {
- odeFault = new OdeFault("Message exchange failure.");
- odeFault.setDetail(null);
- odeFault.setStackTrace(new StackTraceElement[]{});
- }
- throw odeFault;
+ throw new OdeFault("Message exchange failure");
default:
throw new OdeFault("Received ODE message exchange in unexpected
state: " + mex.getStatus());
}
Modified: branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/OdeFault.java
===================================================================
--- branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/OdeFault.java 2010-04-14
15:43:12 UTC (rev 619)
+++ branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/OdeFault.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -22,7 +22,6 @@
import javax.xml.namespace.QName;
import org.apache.axis2.AxisFault;
-import org.apache.axiom.om.OMElement;
/**
* User-friendly version of AxisFault
@@ -47,7 +46,4 @@
super(new QName("java:"+cause.getClass().getPackage(),
cause.getClass().getName(), "java"), message, cause);
}
- public OdeFault(String message, OMElement faultDetail) {
- super(FAULT, message, null, null, faultDetail);
- }
}
Modified:
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/SoapExternalService.java
===================================================================
---
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/SoapExternalService.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/SoapExternalService.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -20,8 +20,6 @@
package org.apache.ode.axis2;
import org.apache.axiom.soap.SOAPEnvelope;
-import org.apache.axiom.soap.SOAPFaultReason;
-import org.apache.axiom.soap.SOAPFault;
import org.apache.axis2.AxisFault;
import org.apache.axis2.addressing.EndpointReference;
import org.apache.axis2.client.OperationClient;
@@ -39,8 +37,10 @@
import org.apache.commons.httpclient.MultiThreadedHttpConnectionManager;
import org.apache.neethi.Policy;
import org.apache.neethi.PolicyEngine;
+import org.apache.ode.axis2.util.ClusterUrlTransformer;
import org.apache.ode.axis2.util.SoapMessageConverter;
import org.apache.ode.axis2.util.AxisUtils;
+import org.apache.ode.bpel.engine.BpelServerImpl;
import org.apache.ode.bpel.epr.EndpointFactory;
import org.apache.ode.bpel.epr.MutableEndpoint;
import org.apache.ode.bpel.epr.WSAEndpoint;
@@ -102,10 +102,11 @@
private Scheduler _sched;
private BpelServer _server;
private ProcessConf _pconf;
+ private ClusterUrlTransformer _clusterUrlTransformer;
private String endpointUrl;
public SoapExternalService(ProcessConf pconf, QName serviceName, String portName,
ExecutorService executorService,
- AxisConfiguration axisConfig, Scheduler sched, BpelServer
server, MultiThreadedHttpConnectionManager connManager) throws AxisFault {
+ AxisConfiguration axisConfig, Scheduler sched, BpelServer
server, MultiThreadedHttpConnectionManager connManager, ClusterUrlTransformer
clusterUrlTransformer) throws AxisFault {
_definition = pconf.getDefinitionForService(serviceName);
_serviceName = serviceName;
_portName = portName;
@@ -115,6 +116,7 @@
_converter = new SoapMessageConverter(_definition, serviceName, portName);
_server = server;
_pconf = pconf;
+ _clusterUrlTransformer = clusterUrlTransformer;
File fileToWatch = new
File(_pconf.getBaseURI().resolve(_serviceName.getLocalPart() + ".axis2"));
_axisServiceWatchDog = WatchDog.watchFile(fileToWatch, new
ServiceFileObserver(fileToWatch));
@@ -165,6 +167,9 @@
}else{
if (__log.isDebugEnabled()) __log.debug("Endpoint URL overridden by
process. "+endpointUrl+" => "+mexEndpointUrl);
}
+
+
+
axisEPR.setAddress(_clusterUrlTransformer.rewriteOutgoingClusterURL(axisEPR.getAddress()));
if (__log.isDebugEnabled()) {
__log.debug("Axis2 sending message to " + axisEPR.getAddress()
+ " using MEX " + odeMex);
@@ -278,7 +283,8 @@
}
if (__log.isDebugEnabled())
__log.debug("Create a new ServiceClient for " +
anonymousService.getName());
- client = new ServiceClient(_configContext, anonymousService);
+ client = new ServiceClient(_configContext, null);
+ client.setAxisService(anonymousService);
}
_cachedClients.set(client);
}
@@ -484,11 +490,8 @@
} else {
if (__log.isWarnEnabled())
__log.warn("Fault response:
faultType=(unkown)\n" + reply.getEnvelope().toString());
- final SOAPFaultReason r =
reply.getEnvelope().getBody().getFault().getReason();
- SOAPFault f = reply.getEnvelope().getBody().getFault();
- String reason = r != null ? r.getText() :
"Unspecified";
- Element details = f != null ? OMUtils.toDOM(f) : null;
- odeMex.replyWithFailure(FailureType.OTHER, reason,
details);
+ odeMex.replyWithFailure(FailureType.OTHER,
reply.getEnvelope().getBody()
+ .getFault().getText(),
OMUtils.toDOM(reply.getEnvelope().getBody()));
}
} else {
Message response =
odeMex.createMessage(odeMex.getOperation().getOutput().getMessage().getQName());
Modified:
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/deploy/DeploymentPoller.java
===================================================================
---
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/deploy/DeploymentPoller.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/deploy/DeploymentPoller.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -82,14 +82,7 @@
/** Filter accepting directories containing a ode dd file. */
private static final FileFilter _fileFilter = new FileFilter() {
public boolean accept(File path) {
- if (path.isDirectory()) {
- return path.listFiles(new FilenameFilter() {
- public boolean accept(File dir, String name) {
- return name.toLowerCase().equals("deploy.xml");
- }
- }).length == 1;
- } else
- return false;
+ return new File(path, "deploy.xml").exists();
}
};
Modified:
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/httpbinding/HttpExternalService.java
===================================================================
---
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/httpbinding/HttpExternalService.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/httpbinding/HttpExternalService.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -30,6 +30,7 @@
import org.apache.ode.axis2.ODEService;
import org.apache.ode.utils.Properties;
import org.apache.ode.axis2.OdeFault;
+import org.apache.ode.axis2.util.ClusterUrlTransformer;
import org.apache.ode.bpel.epr.EndpointFactory;
import org.apache.ode.bpel.epr.WSAEndpoint;
import org.apache.ode.bpel.epr.MutableEndpoint;
@@ -83,9 +84,11 @@
protected Binding portBinding;
private URL endpointUrl;
+ private ClusterUrlTransformer clusterUrlTransformer;
+
public HttpExternalService(ProcessConf pconf, QName serviceName, String portName,
ExecutorService executorService, Scheduler scheduler,
BpelServer server,
- MultiThreadedHttpConnectionManager connManager) throws
OdeFault {
+ MultiThreadedHttpConnectionManager connManager,
ClusterUrlTransformer clusterUrlTransformer) throws OdeFault {
if (log.isDebugEnabled())
log.debug("new HTTP External service, service name=[" + serviceName
+ "]; port name=[" + portName + "]");
this.portName = portName;
@@ -94,6 +97,7 @@
this.scheduler = scheduler;
this.server = server;
this.pconf = pconf;
+ this.clusterUrlTransformer = clusterUrlTransformer;
Definition definition = pconf.getDefinitionForService(serviceName);
Service serviceDef = definition.getService(serviceName);
if (serviceDef == null)
@@ -165,6 +169,8 @@
if (log.isDebugEnabled()) log.debug("Endpoint URL overridden by
process. "+endpointUrl+" => "+mexEndpointUrl);
}
+ baseUrl = clusterUrlTransformer.rewriteOutgoingClusterURL(baseUrl);
+
// build the http method
final HttpMethod method = httpMethodConverter.createHttpRequest(odeMex,
params, baseUrl);
Modified:
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/service/DeploymentBrowser.java
===================================================================
---
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/service/DeploymentBrowser.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/service/DeploymentBrowser.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -46,6 +46,7 @@
private AxisConfiguration _config;
private File _appRoot;
+
public DeploymentBrowser(ProcessStoreImpl store, AxisConfiguration config, File
appRoot) {
_store = store;
_config = config;
@@ -150,7 +151,7 @@
renderHtml(response, "Files in Bundle " + segments[1],
new DocBody() {
public void render(Writer out) throws IOException {
List<QName> processes =
_store.listProcesses(segments[1]);
- if (processes != null) {
+ if (processes != null && processes.size() > 0)
{
List<File> files =
_store.getProcessConfiguration(processes.get(0)).getFiles();
for (File file : files) {
String relativePath =
file.getPath().substring(file.getPath()
@@ -158,16 +159,18 @@
out.write("<p><a href=\""
+ relativePath + "\">" + relativePath +
"</a></p>");
}
} else {
- out.write("<p>Couldn't find bundle
" + segments[2] + "</p>");
+ out.write("<p>Couldn't find bundle
" + segments[1] + "</p>");
}
}
});
} else if (segments.length > 2) {
List<QName> processes = _store.listProcesses(segments[1]);
- if (processes != null) {
+ if (processes != null && processes.size() > 0) {
List<File> files =
_store.getProcessConfiguration(processes.get(0)).getFiles();
for (final File file : files) {
String relativePath = requestURI.substring(deplUri + 12 +
9 + segments[1].length());
+ // replace slashes with the correct file separator so the
match below is not always false
+ relativePath = relativePath.replace('/',
File.separatorChar);
if (file.getPath().endsWith(relativePath)) {
renderXml(response, new DocBody() {
public void render(Writer out) throws IOException
{
Modified:
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/service/DeploymentWebService.java
===================================================================
---
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/service/DeploymentWebService.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/service/DeploymentWebService.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -317,8 +317,13 @@
}
private boolean validBundleName(String bundle) {
- if (StringUtils.isBlank(bundle)) return false;
- return bundle.matches("[\\p{L}0-9_\\-]*");
+ boolean valid;
+ if (StringUtils.isBlank(bundle)) valid = false;
+ else valid = bundle.matches("[\\p{L}0-9_\\-]*");
+ if (__log.isDebugEnabled()) {
+ __log.debug("Validating bundle " + bundle + " valid:
" + valid);
+ }
+ return valid;
}
}
Modified:
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/util/AxisUtils.java
===================================================================
---
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/util/AxisUtils.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/util/AxisUtils.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -90,13 +90,20 @@
}
}
- public static void applySecurityPolicy(AxisService service, String policy_file) {
+ public static void applySecurityPolicy(AxisService service, String policy_file)
throws IllegalArgumentException {
URI policyUri = new File(policy_file).toURI();
if (log.isDebugEnabled()) log.debug("Applying security policy: " +
policyUri);
try {
InputStream policyStream = policyUri.toURL().openStream();
try {
Policy policyDoc = PolicyEngine.getPolicy(policyStream);
+ // Neethi parser is really dumb.
+ // In case of parsing error, the exception is printed out and swallowed.
Null is returned.
+ if(policyDoc == null){
+ String msg = "Failed to parse policy: "+policy_file+".
Due to Neethi limitations the reason can't be provided. See stacktraces in standard
output (not logs)";
+ log.error(msg);
+ throw new IllegalArgumentException(msg);
+ }
service.getPolicyInclude().addPolicyElement(PolicyInclude.AXIS_SERVICE_POLICY,
policyDoc);
// make sure the proper modules are engaged, if they are available
engageModules(service, "rampart", "rahas");
Added:
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/util/ClusterUrlTransformer.java
===================================================================
---
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/util/ClusterUrlTransformer.java
(rev 0)
+++
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/util/ClusterUrlTransformer.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,52 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.ode.axis2.util;
+
+import java.util.List;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+public class ClusterUrlTransformer {
+ private static final Log __log = LogFactory.getLog(ClusterUrlTransformer.class);
+
+ private final List<String> targets;
+ private final String base;
+
+ public ClusterUrlTransformer(List<String> targets, String base) {
+ super();
+ this.targets = targets;
+ this.base = base;
+ }
+
+ public String rewriteOutgoingClusterURL(String url1) {
+ String url = url1;
+ for (String target : targets) {
+ if (target.length() > 0) {
+ url = url.replace(target, base);
+ }
+ }
+ if (__log.isDebugEnabled()) {
+ __log.debug("targets: " + targets + " base: " + base);
+ __log.debug("rewrite: " + url1 + " to " + url);
+ }
+ return url;
+ }
+}
Modified:
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/util/GeronimoFactory.java
===================================================================
---
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/util/GeronimoFactory.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/util/GeronimoFactory.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -19,23 +19,7 @@
package org.apache.ode.axis2.util;
-import org.apache.geronimo.gbean.AbstractName;
-import org.apache.geronimo.gbean.AbstractNameQuery;
-import org.apache.geronimo.kernel.GBeanNotFoundException;
-import org.apache.geronimo.kernel.Kernel;
-import org.apache.geronimo.kernel.KernelRegistry;
-import org.apache.geronimo.kernel.config.MultiParentClassLoader;
-import org.apache.geronimo.kernel.repository.Artifact;
-import org.apache.geronimo.kernel.repository.Repository;
-import org.apache.geronimo.transaction.context.GeronimoTransactionManager;
-import org.apache.geronimo.transaction.context.TransactionContextManager;
-
import javax.transaction.TransactionManager;
-import java.io.File;
-import java.net.MalformedURLException;
-import java.util.Collections;
-import java.util.Iterator;
-import java.util.Set;
public class GeronimoFactory {
@@ -44,36 +28,11 @@
}
public TransactionManager getTransactionManager() {
- Kernel kernel = KernelRegistry.getSingleKernel();
- TransactionContextManager ctxManager = null;
-
try {
- ctxManager = (TransactionContextManager)
kernel.getGBean(TransactionContextManager.class);
- } catch (GBeanNotFoundException except) {
- throw new RuntimeException( "Can't lookup GBean: " +
TransactionContextManager.class, except);
+ return new
org.apache.geronimo.transaction.manager.GeronimoTransactionManager();
+ } catch (Exception e) {
+ throw new RuntimeException("Can't instantiate
GeronimoTransactionManager", e);
}
-
- MultiParentClassLoader loader = (MultiParentClassLoader)
ctxManager.getClass().getClassLoader();
-
- // Add Jencks to Geronimo's root classloader to avoid InvalidAccessError
- AbstractNameQuery abstractNameQuery = new AbstractNameQuery(null,
Collections.EMPTY_MAP, Repository.class.getName());
- Set set = kernel.listGBeans(abstractNameQuery);
- for (Iterator iterator = set.iterator(); iterator.hasNext();) {
- AbstractName abstractName = (AbstractName) iterator.next();
- File f = null;
- try {
- Repository repo = (Repository) kernel.getGBean(abstractName);
- f = repo.getLocation(new Artifact("org.jencks",
"jencks", "1.3", "jar"));
- loader.addURL(f.toURL());
- } catch (GBeanNotFoundException except) {
- throw new RuntimeException("Can't lookup GBean: " +
abstractName, except);
- } catch (MalformedURLException except) {
- throw new RuntimeException("Invalid URL for jencks: " + f,
except);
- }
- }
-
- // Use Jenck to wrap TransactionContextManager back to TransactionManager
- return new GeronimoTransactionManager(ctxManager);
}
}
Modified:
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/util/SoapMessageConverter.java
===================================================================
---
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/util/SoapMessageConverter.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/axis2/src/main/java/org/apache/ode/axis2/util/SoapMessageConverter.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -44,9 +44,7 @@
import javax.wsdl.extensions.soap.SOAPHeader;
import javax.wsdl.extensions.soap.SOAPOperation;
import javax.xml.namespace.QName;
-import javax.xml.transform.dom.DOMSource;
import java.util.*;
-import java.io.IOException;
import org.apache.axiom.om.OMAbstractFactory;
import org.apache.axiom.om.OMElement;
@@ -546,28 +544,4 @@
return WsdlUtils.inferFault(operation, elName);
}
- /**
- *
- * @param faultExplanation
- * @param faultResponse
- * @return an OdeFault
- */
- public OdeFault createOdeFault(String faultExplanation,
org.apache.ode.bpel.iapi.Message faultResponse) {
- String message = new StringBuilder("Message exchange failure due to:
").append(faultExplanation).toString();
- OMElement detail = null;
- if (faultResponse!=null) {
- Element messageElement = faultResponse.getMessage();
- if (messageElement != null) {
- Element detailElement = DOMUtils.getFirstChildElement(messageElement);
- if (detailElement != null) {
- try {
- detail = OMUtils.toOM(new DOMSource(messageElement));
- } catch (IOException ignore) {
- }
- }
- }
- }
- return new OdeFault(message, detail);
- }
-
}
Modified: branches/ODE/ODE-1.x/axis2/src/main/wsdl/pmapi.wsdl
===================================================================
--- branches/ODE/ODE-1.x/axis2/src/main/wsdl/pmapi.wsdl 2010-04-14 15:43:12 UTC (rev 619)
+++ branches/ODE/ODE-1.x/axis2/src/main/wsdl/pmapi.wsdl 2010-04-14 18:25:55 UTC (rev 620)
@@ -122,6 +122,14 @@
<message name="listInstancesOutput">
<part name="instance-info-list"
type="typ:tInstanceInfoList"/>
</message>
+ <message name="listInstancesSummaryInput">
+ <part name="filter" type="xsd:string"/>
+ <part name="order" type="xsd:string"/>
+ <part name="limit" type="xsd:int"/>
+ </message>
+ <message name="listInstancesSummaryOutput">
+ <part name="instance-info-list"
type="typ:tInstanceInfoList"/>
+ </message>
<message name="queryInstancesInput">
<part name="payload" type="xsd:string"/>
</message>
@@ -217,6 +225,18 @@
<message name="recoverActivityOutput">
<part name="instance-info" type="typ:tInstanceInfo"/>
</message>
+ <message name="replayInput">
+ <part name="replay" type="typ:Replay"/>
+ </message>
+ <message name="replayOutput">
+ <part name="replayResponse"
type="typ:ReplayResponse"/>
+ </message>
+ <message name="getCommunicationInput">
+ <part name="getCommunication"
type="typ:GetCommunication"/>
+ </message>
+ <message name="getCommunicationOutput">
+ <part name="getCommunicationResponse"
type="typ:GetCommunicationResponse"/>
+ </message>
<message name="managementFault">
<part name="managementFault"
element="tns:ManagementFault"/>
</message>
@@ -280,6 +300,11 @@
<output message="tns:listInstancesOutput"/>
<fault name="ManagementFault"
message="tns:managementFault"/>
</operation>
+ <operation name="listInstancesSummary">
+ <input message="tns:listInstancesSummaryInput"/>
+ <output message="tns:listInstancesSummaryOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
<operation name="queryInstances">
<input message="tns:queryInstancesInput"/>
<output message="tns:queryInstancesOutput"/>
@@ -355,6 +380,16 @@
<output message="tns:recoverActivityOutput"/>
<fault name="ManagementFault"
message="tns:managementFault"/>
</operation>
+ <operation name="replay">
+ <input message="tns:replayInput"/>
+ <output message="tns:replayOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
+ <operation name="getCommunication">
+ <input message="tns:getCommunicationInput"/>
+ <output message="tns:getCommunicationOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
</portType>
<binding name="ProcessManagementBinding"
type="tns:ProcessManagementPortType">
@@ -495,6 +530,18 @@
<soap:fault name="ManagementFault"
use="literal"/>
</fault>
</operation>
+ <operation name="listInstancesSummary">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
<operation name="queryInstances">
<soap:operation soapAction="" style="rpc"/>
<input>
@@ -675,6 +722,30 @@
<soap:fault name="ManagementFault"
use="literal"/>
</fault>
</operation>
+ <operation name="replay">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
+ <operation name="getCommunication">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
</binding>
<service name="ProcessManagementService">
Added: branches/ODE/ODE-1.x/axis2-war/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/axis2-war/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/axis2-war/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,333 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-axis2-war</artifactId>
+ <name>ODE :: Axis2 Based Web Application</name>
+ <packaging>pom</packaging>
+
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <properties>
+ <rampart.version>1.4</rampart.version>
+ <mex.version>1.41</mex.version>
+ <axis2.version>1.4.1</axis2.version>
+ <jibx.version>1.1.5</jibx.version>
+ <tranql.version>1.1</tranql.version>
+ <opensaml.version>1.1</opensaml.version>
+ <bouncycastle.version>140</bouncycastle.version>
+ <geronimo-spec-jms.version>1.1-rc4</geronimo-spec-jms.version>
+ <jetty.version>6.1.3</jetty.version>
+ <testng.version>5.8</testng.version>
+ </properties>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-compiler</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-connector</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-dao</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-epr</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-runtime</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-scheduler-simple</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-store</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-schemas</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-utils</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-dao-jpa</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-axis2</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-corba</artifactId>
+ <version>${axis2.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-fastinfoset</artifactId>
+ <version>${axis2.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-jaxbri</artifactId>
+ <version>${axis2.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-jaxws</artifactId>
+ <version>${axis2.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-jaxws-api</artifactId>
+ <version>${axis2.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-json</artifactId>
+ <version>${axis2.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-jws-api</artifactId>
+ <version>${axis2.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-metadata</artifactId>
+ <version>${axis2.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-spring</artifactId>
+ <version>${axis2.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>xerces</groupId>
+ <artifactId>xercesImpl</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>woodstox</groupId>
+ <artifactId>wstx-asl</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.derby</groupId>
+ <artifactId>derbytools</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.jibx</groupId>
+ <artifactId>jibx-run</artifactId>
+ <version>${jibx.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>tranql</groupId>
+ <artifactId>tranql-connector</artifactId>
+ <version>${tranql.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.opensaml</groupId>
+ <artifactId>opensaml</artifactId>
+ <version>${opensaml.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>bouncycastle</groupId>
+ <artifactId>bcprov-jdk15</artifactId>
+ <version>${bouncycastle.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>geronimo-spec</groupId>
+ <artifactId>geronimo-spec-jms</artifactId>
+ <version>${geronimo-spec-jms.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.modules</groupId>
+ <artifactId>geronimo-kernel</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>xml-apis</groupId>
+ <artifactId>xml-apis</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.rampart</groupId>
+ <artifactId>rampart</artifactId>
+ <type>mar</type>
+ <version>${rampart.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.rampart</groupId>
+ <artifactId>rahas</artifactId>
+ <type>mar</type>
+ <version>${rampart.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>addressing</artifactId>
+ <type>mar</type>
+ <version>${rampart.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>mex</artifactId>
+ <type>mar</type>
+ <version>${mex.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>mex</artifactId>
+ <classifier>impl</classifier>
+ <version>${mex.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.testng</groupId>
+ <artifactId>testng</artifactId>
+ <version>${testng.version}</version>
+ <classifier>jdk15</classifier>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.mortbay.jetty</groupId>
+ <artifactId>jetty</artifactId>
+ <version>${jetty.version}</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.mortbay.jetty</groupId>
+ <artifactId>jetty-util</artifactId>
+ <version>${jetty.version}</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.mortbay.jetty</groupId>
+ <artifactId>servlet-api-2.5</artifactId>
+ <version>${jetty.version}</version>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-assembly-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>war-package</id>
+ <phase>package</phase>
+ <goals>
+ <goal>single</goal>
+ </goals>
+ <configuration>
+ <finalName>ode-axis2-war-${project.version}</finalName>
+ <appendAssemblyId>false</appendAssemblyId>
+ <descriptors>
+ <descriptor>src/main/assembly/bin.xml</descriptor>
+ </descriptors>
+ <tarLongFileMode>gnu</tarLongFileMode>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ <!--plugin>
+ <groupId>org.mortbay.jetty</groupId>
+ <artifactId>maven-jetty-plugin</artifactId>
+ <version>6.1.10</version>
+ <configuration>
+ <scanIntervalSeconds>10</scanIntervalSeconds>
+ <stopKey>foo</stopKey>
+ <stopPort>9999</stopPort>
+
<webApp>${basedir}/target/ode-axis2-war-${project.version}.war</webApp>
+ </configuration>
+ <executions>
+ <execution>
+ <id>start-jetty</id>
+ <phase>pre-integration-test</phase>
+ <goals>
+ <goal>run-war</goal>
+ </goals>
+ <configuration>
+ <scanIntervalSeconds>0</scanIntervalSeconds>
+ <daemon>true</daemon>
+ </configuration>
+ </execution>
+ <execution>
+ <id>stop-jetty</id>
+ <phase>post-integration-test</phase>
+ <goals>
+ <goal>stop</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>compiler-it</id>
+ <phase>pre-integration-test</phase>
+ <goals>
+ <goal>testCompile</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin-->
+ <!-- FIXME: temporary commented out -->
+ <plugin>
+ <artifactId>maven-surefire-plugin</artifactId>
+ <configuration>
+ <includes>
+ <include>**/*TestCase.java</include>
+ <include>**/Test.java</include>
+ </includes>
+ </configuration>
+ <executions>
+ <execution>
+ <id>test-axis2-web</id>
+ <phase>integration-test</phase>
+ <goals>
+ <goal>test</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+
+</project>
Added: branches/ODE/ODE-1.x/axis2-war/src/main/assembly/bin.xml
===================================================================
--- branches/ODE/ODE-1.x/axis2-war/src/main/assembly/bin.xml (rev
0)
+++ branches/ODE/ODE-1.x/axis2-war/src/main/assembly/bin.xml 2010-04-14 18:25:55 UTC (rev
620)
@@ -0,0 +1,185 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<assembly>
+ <!-- id typically identifies the "type" (src vs bin etc) of the assembly
-->
+ <id></id>
+ <includeBaseDirectory>false</includeBaseDirectory>
+ <formats>
+ <format>war</format>
+ </formats>
+
+ <fileSets>
+
+ <fileSet>
+ <directory>src/main/webapp</directory>
+ <outputDirectory>/</outputDirectory>
+ </fileSet>
+
+ <fileSet>
+ <directory>${basedir}/../dao-jpa-ojpa-derby/target/derby</directory>
+ <outputDirectory>/WEB-INF</outputDirectory>
+ </fileSet>
+
+ <fileSet>
+ <directory>${basedir}/../dao-hibernate-db/target/derby</directory>
+ <outputDirectory>/WEB-INF</outputDirectory>
+ </fileSet>
+
+ <fileSet>
+ <directory>${basedir}/../axis2/src/main/wsdl</directory>
+ <outputDirectory>/WEB-INF</outputDirectory>
+ </fileSet>
+
+ <fileSet>
+ <directory>${basedir}/../bpel-schemas/src/main/xsd</directory>
+ <outputDirectory>/WEB-INF</outputDirectory>
+ <includes>
+ <include>pmapi.xsd</include>
+ </includes>
+ </fileSet>
+
+ </fileSets>
+
+ <dependencySets>
+
+ <dependencySet>
+ <outputDirectory>/WEB-INF/lib</outputDirectory>
+ <includes>
+ <include>org.apache.ode:ode-bpel-api</include>
+ <include>org.apache.ode:ode-bpel-compiler</include>
+ <include>org.apache.ode:ode-bpel-connector</include>
+ <include>org.apache.ode:ode-bpel-dao</include>
+ <include>org.apache.ode:ode-axis2</include>
+ <include>org.apache.ode:ode-bpel-epr</include>
+ <include>org.apache.ode:ode-bpel-runtime</include>
+ <include>org.apache.ode:ode-scheduler-simple</include>
+ <include>org.apache.ode:ode-bpel-schemas</include>
+ <include>org.apache.ode:ode-bpel-store</include>
+ <include>org.apache.ode:ode-dao-hibernate</include>
+ <include>org.apache.ode:ode-jacob</include>
+ <include>org.apache.ode:ode-jca-ra</include>
+ <include>org.apache.ode:ode-jca-server</include>
+ <include>org.apache.ode:ode-utils</include>
+ <include>org.apache.ode:ode-agents</include>
+ <include>org.apache.ode:ode-bpel-obj</include>
+ <include>org.apache.ode:ode-dao-jpa</include>
+ <include>annogen:annogen</include>
+ <include>antlr:antlr</include>
+ <include>javax.activation:activation</include>
+ <include>org.apache.axis2:axis2-adb</include>
+ <include>org.apache.axis2:axis2-adb-codegen</include>
+ <include>org.apache.axis2:axis2-codegen</include>
+ <include>org.apache.axis2:axis2-corba</include>
+ <include>org.apache.axis2:axis2-fastinfoset</include>
+ <include>org.apache.axis2:axis2-java2wsdl</include>
+ <include>org.apache.axis2:axis2-jaxbri</include>
+ <include>org.apache.axis2:axis2-jaxws</include>
+ <include>org.apache.axis2:axis2-jaxws-api</include>
+ <include>org.apache.axis2:axis2-jibx</include>
+ <include>org.apache.axis2:axis2-json</include>
+ <include>org.apache.axis2:axis2-jws-api</include>
+ <include>org.apache.axis2:axis2-kernel</include>
+ <include>org.apache.axis2:axis2-metadata</include>
+ <include>org.apache.axis2:axis2-mtompolicy</include>
+ <include>org.apache.axis2:axis2-saaj</include>
+ <include>org.apache.axis2:axis2-saaj-api</include>
+ <include>org.apache.axis2:axis2-spring</include>
+ <include>org.apache.axis2:axis2-xmlbeans</include>
+ <include>org.apache.ws.commons.axiom:axiom-api</include>
+ <include>org.apache.ws.commons.axiom:axiom-impl</include>
+ <include>org.apache.ws.commons.axiom:axiom-dom</include>
+ <include>backport-util-concurrent:backport-util-concurrent</include>
+ <include>commons-codec:commons-codec</include>
+ <include>commons-collections:commons-collections</include>
+ <include>commons-lang:commons-lang</include>
+ <include>commons-pool:commons-pool</include>
+ <include>commons-io:commons-io</include>
+ <include>commons-httpclient:commons-httpclient</include>
+ <include>commons-logging:commons-logging</include>
+ <include>commons-fileupload:commons-fileupload</include>
+ <include>commons-primitives:commons-primitives</include>
+ <include>org.apache.derby:derby</include>
+ <include>org.apache.derby:derbytools</include>
+ <include>org.apache.geronimo.specs:geronimo-ejb_2.1_spec</include>
+ <include>org.apache.geronimo.specs:geronimo-j2ee-connector_1.5_spec</include>
+ <include>org.apache.geronimo.specs:geronimo-jta_1.1_spec</include>
+ <include>org.apache.geronimo.specs:geronimo-activation_1.1_spec</include>
+ <include>org.apache.geronimo.specs:geronimo-stax-api_1.0_spec</include>
+ <include>org.apache.geronimo.specs:geronimo-javamail_1.4_spec</include>
+ <include>org.apache.geronimo.specs:geronimo-annotation_1.0_spec</include>
+ <include>geronimo-spec:geronimo-spec-jms</include>
+ <include>org.apache.geronimo.modules:geronimo-kernel</include>
+ <include>org.apache.geronimo.components:geronimo-transaction</include>
+ <include>org.apache.geronimo.components:geronimo-connector</include>
+ <include>org.apache.woden:woden-api</include>
+ <include>org.apache.woden:woden-impl-dom</include>
+ <include>woodstox:wstx-asl</include>
+ <include>org.apache.neethi:neethi</include>
+ <include>org.apache.ws.commons.schema:XmlSchema</include>
+ <include>xerces:xercesImpl</include>
+ <include>org.apache.rampart:rampart-core</include>
+ <include>org.apache.rampart:rampart-policy</include>
+ <include>org.apache.rampart:rampart-trust</include>
+ <include>org.apache.ws.security:wss4j</include>
+ <include>org.apache.santuario:xmlsec</include>
+ <include>org.apache.axis2:mex:jar:impl</include>
+ <include>org.opensaml:opensaml</include>
+ <include>bouncycastle:bcprov-jdk15</include>
+ <include>org.jibx:jibx-run</include>
+ <include>org.jibx:jibx-bind</include>
+ <include>org.codehaus.jettison:jettison</include>
+ <include>jaxen:jaxen</include>
+ <include>log4j:log4j</include>
+ <include>org.apache.openjpa:openjpa</include>
+ <include>javax.persistence:persistence-api</include>
+ <include>net.sourceforge.serp:serp</include>
+ <include>net.sf.saxon:saxon</include>
+ <include>net.sf.saxon:saxon-xpath</include>
+ <include>net.sf.saxon:saxon-dom</include>
+ <include>net.sf.saxon:saxon-xqj</include>
+ <include>wsdl4j:wsdl4j</include>
+ <include>tranql:tranql-connector</include>
+ <include>xalan:xalan</include>
+ <include>org.apache.xmlbeans:xmlbeans</include>
+ <include>org.apache.httpcomponents:httpcore</include>
+ <include>org.apache.httpcomponents:httpcore-nio</include>
+ <include>javax.xml.bind:jaxb-api</include>
+ <include>com.sun.xml.bind:jaxb-impl</include>
+ <include>com.sun.xml.bind:jaxb-xjc</include>
+ <include>xml-resolver:xml-resolver</include>
+ <include>xml-apis:xml-apis</include>
+ <include>javax.mail:mail</include>
+ <include>axion:axion</include>
+ </includes>
+ </dependencySet>
+
+ <dependencySet>
+ <outputDirectory>/WEB-INF/modules</outputDirectory>
+ <includes>
+ <include>org.apache.rampart:rampart:mar</include>
+ <include>org.apache.rampart:rahas:mar</include>
+ <include>org.apache.axis2:addressing:mar</include>
+ <include>org.apache.axis2:mex:mar</include>
+ </includes>
+ </dependencySet>
+
+ </dependencySets>
+
+</assembly>
Added:
branches/ODE/ODE-1.x/axis2-war/src/main/webapp/WEB-INF/classes/META-INF/services/org.apache.commons.logging.LogFactory
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/main/webapp/WEB-INF/classes/META-INF/services/org.apache.commons.logging.LogFactory
(rev 0)
+++
branches/ODE/ODE-1.x/axis2-war/src/main/webapp/WEB-INF/classes/META-INF/services/org.apache.commons.logging.LogFactory 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1 @@
+org.apache.commons.logging.impl.Log4JLogger
\ No newline at end of file
Modified: branches/ODE/ODE-1.x/axis2-war/src/main/webapp/WEB-INF/classes/log4j.properties
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/main/webapp/WEB-INF/classes/log4j.properties 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/axis2-war/src/main/webapp/WEB-INF/classes/log4j.properties 2010-04-14
18:25:55 UTC (rev 620)
@@ -25,10 +25,15 @@
log4j.category.org.apache.ode.axis2=DEBUG
log4j.category.org.apache.ode.axis2.hooks.SessionInHandler=INFO
log4j.category.org.apache.ode.bpel.engine=DEBUG
+log4j.category.org.apache.ode.bpel.engine.cron=INFO
log4j.category.org.apache.ode.daohib.bpel.CorrelatorDaoImpl=DEBUG
log4j.category.org.apache.ode.bpel.epr=INFO
+log4j.category.org.apache.ode.sql=DEBUG
# Console appender
log4j.appender.CONSOLE=org.apache.log4j.ConsoleAppender
log4j.appender.CONSOLE.layout=org.apache.log4j.PatternLayout
-log4j.appender.CONSOLE.layout.ConversionPattern=%p - %C{1}.%M(%L) | %m%n
+log4j.appender.CONSOLE.layout.ConversionPattern=%d{ABSOLUTE} %-5p [%c{1}] %m%n
+
+# uncomment for more information in debug logs (will be slower).
+#log4j.appender.CONSOLE.layout.ConversionPattern=%p - %t - %C{1}.%M(%L) | %m%n
Modified: branches/ODE/ODE-1.x/axis2-war/src/main/webapp/js/ODE.js
===================================================================
--- branches/ODE/ODE-1.x/axis2-war/src/main/webapp/js/ODE.js 2010-04-14 15:43:12 UTC (rev
619)
+++ branches/ODE/ODE-1.x/axis2-war/src/main/webapp/js/ODE.js 2010-04-14 18:25:55 UTC (rev
620)
@@ -616,7 +616,7 @@
}
function handleNo(){
- org.apache.ode.Widgets..alert('Retiring cancelled!',
YAHOO.widget.SimpleDialog.ICON_INFO);
+ org.apache.ode.Widgets.alert('Retiring cancelled!',
YAHOO.widget.SimpleDialog.ICON_INFO);
}
var msg = 'Do you want to retire the process '+ processName +
'?';
org.apache.ode.Widgets.operationConfirm(msg, handleYes, handleNo);
@@ -764,7 +764,7 @@
var callbackIn = {
success: handleSuccessIn,
- failure: handleFailureIn,
+ failure: handleFailureIn
}
var requestIn = YAHOO.util.Connect.asyncRequest('GET',
proDefURL, callbackIn);
@@ -777,7 +777,7 @@
var callback = {
success: handleSuccess,
- failure: handleFailure,
+ failure: handleFailure
}
var request = YAHOO.util.Connect.asyncRequest('GET', urlRequestURL,
callback);
Modified:
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/Axis2TestBase.java
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/Axis2TestBase.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/Axis2TestBase.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -166,6 +166,7 @@
@BeforeMethod
protected void setUp() throws Exception {
+ log.debug("##### Running "+getClass().getName());
/**
* 1. If no settings are given from buildr, the test runs with the default config
directory.
* 2. If no settings are given from buildr and if the test implements
ODEConfigDirAware, the test runs with
Modified:
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/BpelActivityTest.java
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/BpelActivityTest.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/BpelActivityTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -32,10 +32,10 @@
if (server.isDeployed(bundleName)) server.undeployProcess(bundleName);
server.deployProcess(bundleName);
- new Thread() {
+ new Thread("SECOND CLIENT") {
public void run() {
try {
- Thread.sleep(2000);
+ Thread.sleep(3000);
String response =
server.sendRequestFile("http://localhost:8888/ode/processes/OnEventCorrelation/",
bundleName, "testRequest.soap");
} catch( Exception e ) {
@@ -44,30 +44,35 @@
}
}.start();
- new Thread() {
+ new Thread("THIRD CLIENT") {
public void run() {
try {
- Thread.sleep(4000);
+ Thread.sleep(6000);
server.sendRequestFile("http://localhost:8888/ode/processes/OnEventCorrelation/",
bundleName, "testRequest.soap");
} catch( Exception e ) {
fail(e.getMessage());
} finally {
+ try {
+ Thread.sleep(1000);
+ } catch( Exception e2 ) {
+ }
server.undeployProcess(bundleName);
}
}
}.start();
try {
-
server.sendRequestFile("http://localhost:8888/ode/processes/OnEventCorrelation/",
+ Thread.currentThread().setName("FIRST CLIENT");
+
server.sendRequestFile("http://localhost:8888/ode/processes/OnEventCorrelation/",
bundleName, "testRequest.soap");
- Thread.sleep(6000);
+ Thread.sleep(9000);
} catch( Exception e ) {
fail(e.getMessage());
}
}
- public String getODEConfigDir() {
+ public String getODEConfigDir() {
return HIB_DERBY_CONF_DIR;
- }
+ }
}
Added:
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/ClusteredOutgoingTrafficTest.java
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/ClusteredOutgoingTrafficTest.java
(rev 0)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/ClusteredOutgoingTrafficTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,53 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.ode.axis2;
+
+import org.testng.annotations.Test;
+import static org.testng.AssertJUnit.assertTrue;
+
+/**
+ * Tests that timeouts set in the *.endpoint files are applied.
+ * The test is designed so a fault must be received.
+ *
+ * Actually, the process invokes a 3-sec long operation (see the process request).
+ * The specified timeouts are lesser than 3-sec, so if properly applied, a fault should
be trown.
+ * If not applied, the default 120-sec timeouts will be used. 5sec < 120sec, so the
request will succeed.
+ *
+ */
+public class ClusteredOutgoingTrafficTest extends Axis2TestBase implements
ODEConfigDirAware {
+ @Test(dataProvider="configs")
+ public void test() throws Exception {
+ String bundleName = "TestClusteredOutgoingTraffic";
+ if (server.isDeployed(bundleName)) server.undeployProcess(bundleName);
+ server.deployProcess(bundleName);
+ try {
+ String response =
server.sendRequestFile("http://localhost:8888/ode/processes/PingPongService/",
+ bundleName, "testRequest.soap");
+ System.out.println(response);
+ assertTrue(response.contains("clusterOutput"));
+ } finally {
+ server.undeployProcess(bundleName);
+ }
+ }
+
+ public String getODEConfigDir() {
+ return HIB_DERBY_CONF_DIR;
+ }
+}
Added: branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/NoP2PTest.java
===================================================================
--- branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/NoP2PTest.java
(rev 0)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/NoP2PTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,49 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.ode.axis2;
+
+import org.testng.annotations.Test;
+import static org.testng.AssertJUnit.assertTrue;
+
+/**
+ * Tests that timeouts set in the *.endpoint files are applied.
+ * The test is designed so a fault must be received.
+ *
+ * Actually, the process invokes a 3-sec long operation (see the process request).
+ * The specified timeouts are lesser than 3-sec, so if properly applied, a fault should
be trown.
+ * If not applied, the default 120-sec timeouts will be used. 5sec < 120sec, so the
request will succeed.
+ *
+ */
+public class NoP2PTest extends Axis2TestBase {
+ @Test(dataProvider="configs")
+ public void testNoP2P() throws Exception {
+ String bundleName = "TestNoP2P";
+ if (server.isDeployed(bundleName)) server.undeployProcess(bundleName);
+ server.deployProcess(bundleName);
+ try {
+ String response =
server.sendRequestFile("http://localhost:8888/ode/processes/PingPongService/",
+ bundleName, "testRequest.soap");
+ System.out.println(response);
+ assertTrue(response.contains("magic"));
+ } finally {
+ server.undeployProcess(bundleName);
+ }
+ }
+}
\ No newline at end of file
Added:
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/correlation/CorrelationUnicityTest.java
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/correlation/CorrelationUnicityTest.java
(rev 0)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/correlation/CorrelationUnicityTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,62 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.ode.axis2;
+
+import org.testng.annotations.Test;
+import static org.testng.AssertJUnit.assertTrue;
+
+/**
+ * Tests that timeouts set in the *.endpoint files are applied.
+ * The test is designed so a fault must be received.
+ *
+ * Actually, the process invokes a 3-sec long operation (see the process request).
+ * The specified timeouts are lesser than 3-sec, so if properly applied, a fault should
be trown.
+ * If not applied, the default 120-sec timeouts will be used. 5sec < 120sec, so the
request will succeed.
+ *
+ */
+public class CorrelationUnicityTest extends Axis2TestBase implements ODEConfigDirAware {
+ @Test(dataProvider="configs")
+ public void test() throws Exception {
+ String bundleName = "TestCorrelationUnicity";
+ if (server.isDeployed(bundleName)) server.undeployProcess(bundleName);
+ server.deployProcess(bundleName);
+ try {
+ {
+ String response =
server.sendRequestFile("http://localhost:8888/processes/correlationMultiTest",
+ bundleName, "testRequest.soap");
+ System.out.println(response);
+ assertTrue(response.contains("correlationUnicity1"));
+ }
+
+ {
+ String response =
server.sendRequestFile("http://localhost:8888/processes/correlationMultiTest",
+ bundleName, "testRequest.soap");
+ System.out.println(response);
+ assertTrue(response.contains("correlationUnicity1"));
+ }
+ } finally {
+ server.undeployProcess(bundleName);
+ }
+ }
+
+ public String getODEConfigDir() {
+ return HIB_DERBY_CONF_DIR;
+ }
+}
Modified:
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanFailureHibTest.java
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanFailureHibTest.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanFailureHibTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -21,7 +21,6 @@
import org.apache.ode.bpel.dao.ProcessDAO;
import org.apache.ode.bpel.dao.ProcessInstanceDAO;
-import org.hibernate.Query;
public class CleanFailureHibTest extends CleanFailureTest {
@Override
@@ -39,11 +38,4 @@
return HibDaoConnectionFactoryImpl.getProcess();
}
- @Override
- protected int getLargeDataCount(int echoCount) throws Exception {
- initTM();
- Query query = HibDaoConnectionFactoryImpl.getSession().createQuery("select
count(id) from HLargeData as l");
-
- return ((Long)query.uniqueResult()).intValue();
- }
}
\ No newline at end of file
Modified:
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanFaultHibTest.java
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanFaultHibTest.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanFaultHibTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -20,7 +20,6 @@
package org.apache.ode.axis2.instancecleanup;
import org.apache.ode.bpel.dao.ProcessInstanceDAO;
-import org.hibernate.Query;
public class CleanFaultHibTest extends CleanFaultTest {
@Override
@@ -33,11 +32,4 @@
return HibDaoConnectionFactoryImpl.getInstance();
}
- @Override
- protected int getLargeDataCount(int echoCount) throws Exception {
- initTM();
- Query query = HibDaoConnectionFactoryImpl.getSession().createQuery("select
count(id) from HLargeData as l");
-
- return ((Long)query.uniqueResult()).intValue();
- }
}
\ No newline at end of file
Modified:
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanFaultTest.java
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanFaultTest.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanFaultTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -25,6 +25,7 @@
import org.apache.ode.bpel.dao.ProcessDAO;
import org.apache.ode.bpel.dao.ProcessInstanceDAO;
import org.apache.ode.bpel.iapi.ContextException;
+
import org.testng.annotations.Test;
public class CleanFaultTest extends CleanTestBase {
@@ -79,8 +80,9 @@
ProcessDAO process = null;
try {
initialLargeDataCount = getLargeDataCount(0);
-
-
server.sendRequestFile("http://localhost:8888/processes/helloWorld", bundleName,
"testRequest.soap");
+
+ String response =
server.sendRequestFile("http://localhost:8888/processes/helloWorld", bundleName,
"testRequest.soap");
+ System.out.println(response);
assertInstanceCleanup(instances, activityRecoveries, correlationSets, faults,
exchanges, routes, messsages, partnerLinks, scopes, variables, events, largeData);
process = assertInstanceCleanup(instances, activityRecoveries,
correlationSets, faults, exchanges, routes, messsages, partnerLinks, scopes, variables,
events, largeData);
} finally {
Modified:
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanSuccessHibTest.java
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanSuccessHibTest.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanSuccessHibTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -20,7 +20,6 @@
package org.apache.ode.axis2.instancecleanup;
import org.apache.ode.bpel.dao.ProcessInstanceDAO;
-import org.hibernate.Query;
public class CleanSuccessHibTest extends CleanSuccessTest {
@Override
@@ -33,11 +32,4 @@
return HibDaoConnectionFactoryImpl.getInstance();
}
- @Override
- protected int getLargeDataCount(int echoCount) throws Exception {
- initTM();
- Query query = HibDaoConnectionFactoryImpl.getSession().createQuery("select
count(id) from HLargeData as l");
-
- return ((Long)query.uniqueResult()).intValue();
- }
}
\ No newline at end of file
Modified:
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanSuccessTest.java
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanSuccessTest.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanSuccessTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -80,6 +80,10 @@
server.sendRequestFile("http://localhost:8888/processes/FirstProcess/FirstProcess/FirstProcess/Client",
bundleName, "testRequest.soap");
process = assertInstanceCleanup(instances, activityRecoveries,
correlationSets, faults, exchanges, routes, messsages, partnerLinks, scopes, variables,
events, largeData);
} finally {
+ try {
+ Thread.sleep(1000);
+ } catch(Exception e) {
+ }
server.undeployProcess(bundleName);
assertProcessCleanup(process);
}
Modified:
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanTestBase.java
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanTestBase.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanTestBase.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -142,5 +142,8 @@
protected abstract ProcessInstanceDAO getInstance();
- protected abstract int getLargeDataCount(int echoCount) throws Exception;
+ protected int getLargeDataCount(int echoCount) throws Exception {
+ return echoCount;
+ }
+
}
\ No newline at end of file
Modified:
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/ProcessCronCleanupTest.java
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/ProcessCronCleanupTest.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/ProcessCronCleanupTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -2,12 +2,11 @@
import org.apache.ode.bpel.dao.ProcessDAO;
import org.apache.ode.bpel.dao.ProcessInstanceDAO;
-import org.hibernate.Query;
import org.testng.annotations.Test;
public class ProcessCronCleanupTest extends CleanTestBase {
- @Test(dataProvider="configs")
- public void testCleanAll() throws Exception {
+// @Test(dataProvider="configs")
+ public void _testCleanAll() throws Exception {
go("TestProcessCronCleanup", 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
}
@@ -35,12 +34,4 @@
protected ProcessInstanceDAO getInstance() {
return HibDaoConnectionFactoryImpl.getInstance();
}
-
- @Override
- protected int getLargeDataCount(int echoCount) throws Exception {
- initTM();
- Query query = HibDaoConnectionFactoryImpl.getSession().createQuery("select
count(id) from HLargeData as l");
-
- return ((Long)query.uniqueResult()).intValue();
- }
}
Modified:
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/SystemCronCleanupTest.java
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/SystemCronCleanupTest.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/SystemCronCleanupTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -4,7 +4,7 @@
import org.apache.ode.bpel.dao.ProcessDAO;
import org.apache.ode.bpel.dao.ProcessInstanceDAO;
import org.apache.ode.bpel.engine.cron.SystemSchedulesConfig;
-import org.hibernate.Query;
+
import org.testng.annotations.AfterClass;
import org.testng.annotations.BeforeClass;
import org.testng.annotations.Test;
@@ -15,13 +15,13 @@
System.setProperty(SystemSchedulesConfig.SCHEDULE_CONFIG_FILE_PROP_KEY,
customSchedulesFilePath);
}
- @Test(dataProvider="configs")
- public void testCleanAll() throws Exception {
+// @Test(dataProvider="configs")
+ public void _testCleanAll() throws Exception {
go("TestSystemCronCleanup", 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
}
- @Test(dataProvider="configs")
- public void testCleanExclude() throws Exception {
+// @Test(dataProvider="configs")
+ public void _testCleanExclude() throws Exception {
go("TestSystemCronCleanup_exclude", 1, 0, 0, 0, 3, 0, 6, 2, 3, 6, 59,
76);
}
@@ -61,12 +61,5 @@
protected ProcessInstanceDAO getInstance() {
return HibDaoConnectionFactoryImpl.getInstance();
}
-
- @Override
- protected int getLargeDataCount(int echoCount) throws Exception {
- initTM();
- Query query = HibDaoConnectionFactoryImpl.getSession().createQuery("select
count(id) from HLargeData as l");
-
- return ((Long)query.uniqueResult()).intValue();
- }
+
}
Modified:
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/management/DeploymentTest.java
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/management/DeploymentTest.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/management/DeploymentTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -33,6 +33,8 @@
import org.testng.annotations.AfterMethod;
import org.testng.annotations.BeforeMethod;
import org.testng.annotations.Test;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
import javax.xml.namespace.QName;
import java.io.ByteArrayOutputStream;
@@ -41,6 +43,7 @@
import java.util.Iterator;
public class DeploymentTest extends Axis2TestBase {
+ private static final Log __log = LogFactory.getLog(DeploymentTest.class);
private OMFactory _factory;
private ServiceClientUtil _client;
@@ -148,7 +151,8 @@
undeploy(null);
fail("Undeploying a null or empty package must fail");
} catch (Exception e) {
- String expectedMsg = "Empty package name received!";
+ __log.debug("got exception from deployment" + e.getMessage());
+ String expectedMsg = "Invalid bundle name";
assertTrue("Unexpected exception received",
e.getMessage().contains("operation undeploy") &&
e.getMessage().contains(expectedMsg));
}
}
Modified:
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/management/InstanceManagementTest.java
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/management/InstanceManagementTest.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/management/InstanceManagementTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -31,6 +31,7 @@
import org.apache.ode.tools.sendsoap.cline.HttpSoapSender;
import org.apache.ode.utils.Namespaces;
import org.apache.ode.il.OMUtils;
+import org.apache.ode.axis2.ODEConfigDirAware;
import org.apache.commons.collections.CollectionUtils;
import org.apache.commons.collections.IteratorUtils;
import org.testng.annotations.AfterMethod;
@@ -47,7 +48,7 @@
import static org.testng.AssertJUnit.assertTrue;
-public class InstanceManagementTest extends Axis2TestBase {
+public class InstanceManagementTest extends Axis2TestBase implements ODEConfigDirAware {
private OMFactory _factory;
private DateFormat xsdDF = new
SimpleDateFormat("yyyy-MM-dd'T'HH:mm");
@@ -98,7 +99,7 @@
result.toString().indexOf("DynPartnerResponder") >= 0);
}
- @Test
+ @Test(dataProvider="configs")
public void testInstanceSummaryListProcess() throws Exception {
OMElement listRoot = _client.buildMessage("listProcesses", new String[]
{"filter", "orderKeys"},
new String[] {"name=DynPartnerMain", ""});
@@ -268,4 +269,7 @@
return _client.send(msg,
"http://localhost:"+getTestPort(0)+"/processes/DeploymentService");
}
+ public String getODEConfigDir() {
+ return HIB_DERBY_CONF_DIR;
+ }
}
Added:
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/management/Retire2Test.java
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/management/Retire2Test.java
(rev 0)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/java/org/apache/ode/axis2/management/Retire2Test.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,57 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.ode.axis2.management;
+
+import org.apache.ode.axis2.Axis2TestBase;
+import static org.testng.AssertJUnit.assertTrue;
+import org.testng.annotations.Test;
+
+import javax.xml.namespace.QName;
+
+/**
+ * @author Matthieu Riou <mriou(a)apache.org>
+ */
+public class Retire2Test extends Axis2TestBase {
+
+ @Test(dataProvider="configs")
+ public void testRetiredInstance() throws Exception {
+ String bundleName = "TestInstanceRetire2";
+ System.out.println("=> " +
server.getODEServer().getProcessStore().getPackages());
+ if (server.isDeployed("1")) server.undeployProcess(bundleName +
"/1");
+ if (server.isDeployed("2")) server.undeployProcess(bundleName +
"/2");
+
+ QName deployedQName = server.deployProcess(bundleName +
"/1").iterator().next();
+
+ String response =
server.sendRequestFile("http://localhost:8888/processes/testretire",
+ bundleName + "/1", "testRequest1.soap");
+ assertTrue(response.indexOf("TEST1") > 0);
+
+ server.getODEServer().getProcessManagement().setRetired(deployedQName, true);
+ server.deployProcess(bundleName + "/2");
+
+ response =
server.sendRequestFile("http://localhost:8888/processes/testretire",
+ bundleName + "/1", "testRequest2.soap");
+
+ System.out.println("###############################################");
+ System.out.println(response);
+ System.out.println("###############################################");
+ assertTrue(response.indexOf("TEST2") > 0);
+ }
+}
Added:
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/Ping.bpel
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/Ping.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/Ping.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,96 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<process
+ name="Ping"
+
xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
+ targetNamespace="urn:/PingPong"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:tns="urn:/PingPong"
+
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+
+ <import location="Ping.wsdl"
+
namespace="http://www.example.org/common/"
+
importType="http://schemas.xmlsoap.org/wsdl/" />
+
+ <partnerLinks>
+ <partnerLink name="PingPartnerLink"
+ partnerLinkType="tns:PingPongPLT"
+ myRole="Provider" />
+ <partnerLink name="PongPartnerLink"
+ partnerLinkType="tns:PingPongPLT"
+ partnerRole="Provider"
+ initializePartnerRole="yes" />
+ </partnerLinks>
+
+ <variables>
+ <variable messageType="tns:PingRequest"
name="pingRequest"/>
+ <variable messageType="tns:PingResponse"
name="pingResponse"/>
+ <variable messageType="tns:PongRequest"
name="pongRequest"/>
+ <variable messageType="tns:PongResponse"
name="pongResponse"/>
+ </variables>
+
+ <sequence name="Main">
+ <receive name="pingReceive"
+ createInstance="yes"
+ operation="Ping"
+ partnerLink="PingPartnerLink"
+ portType="tns:PingPongPortType"
+ variable="pingRequest"/>
+
+ <assign>
+ <copy>
+ <from>
+ <literal>
+ <tns:PongRequest>
+ <tns:in>test0</tns:in>
+ </tns:PongRequest>
+ </literal>
+ </from>
+ <to>$pongRequest.parameters</to>
+ </copy>
+ </assign>
+
+ <invoke name="invokePong"
+ operation="Pong"
+ inputVariable="pongRequest"
+ outputVariable="pongResponse"
+ partnerLink="PongPartnerLink"
+ portType="tns:PingPongPortType"/>
+
+ <assign name="assignPingResponse">
+ <copy>
+ <from>
+ <literal>
+ <tns:PingResponse>
+ <tns:out>clusterOutput</tns:out>
+ </tns:PingResponse>
+ </literal>
+ </from>
+ <to>$pingResponse.parameters</to>
+ </copy>
+ </assign>
+
+ <reply name="pingReply"
+ partnerLink="PingPartnerLink"
+ portType="tns:PingPongPortType"
+ operation="Ping"
+ variable="pingResponse"/>
+ </sequence>
+</process>
Added:
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/Ping.wsdl
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/Ping.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/Ping.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,57 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions name="Ping"
+ targetNamespace="urn:/PingPong"
+ xmlns:tns="urn:/PingPong"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns="http://schemas.xmlsoap.org/wsdl/"
xmlns:p="http://www.w3.org/2001/XMLSchema">
+
+ <import location="PingPong.wsdl"
namespace="urn:/PingPong"></import>
+ <binding name="PingPongBinding"
type="tns:PingPongPortType">
+ <soap:binding style="document"
transport="http://schemas.xmlsoap.org/soap/http" />
+ <operation name="Ping">
+ <soap:operation soapAction="urn:/Ping" />
+ <input>
+ <soap:body use="literal" />
+ </input>
+ <output>
+ <soap:body use="literal" />
+ </output>
+ </operation>
+ <operation name="Pong">
+ <soap:operation soapAction="urn:/Pong" />
+ <input>
+ <soap:body use="literal" />
+ </input>
+ <output>
+ <soap:body use="literal" />
+ </output>
+ </operation>
+ </binding>
+ <service name="PingPongService">
+ <port name="Port1" binding="tns:PingPongBinding">
+ <soap:address
location="http://localhost:8888/ode/processes/PingPongService/" />
+ </port>
+ <port name="Port2" binding="tns:PingPongBinding">
+ <soap:address
location="http://doesntexist:8080/ode/processes/PingPongService2/" />
+ </port>
+ </service>
+</definitions>
Added:
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/PingPong.wsdl
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/PingPong.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/PingPong.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,85 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions name="PingPong"
+ targetNamespace="urn:/PingPong"
+ xmlns:tns="urn:/PingPong"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns="http://schemas.xmlsoap.org/wsdl/"
xmlns:p="http://www.w3.org/2001/XMLSchema">
+
+ <types>
+ <xsd:schema
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
targetNamespace="urn:/PingPong">
+ <xsd:element name="Pong">
+ <xsd:complexType>
+ <xsd:sequence>
+ <xsd:element name="in"
type="xsd:string"></xsd:element>
+ </xsd:sequence>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="PongResponse">
+ <xsd:complexType>
+ <xsd:sequence>
+ <xsd:element name="out"
type="xsd:string"></xsd:element>
+ </xsd:sequence>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="Ping">
+ <xsd:complexType>
+ <xsd:sequence>
+ <xsd:element name="in"
type="xsd:string"></xsd:element>
+ </xsd:sequence>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="PingResponse">
+ <xsd:complexType>
+ <xsd:sequence>
+ <xsd:element name="out"
type="xsd:string"></xsd:element>
+ </xsd:sequence>
+ </xsd:complexType>
+ </xsd:element></xsd:schema>
+ </types>
+
+ <message name="PongRequest">
+ <part name="parameters" element="tns:Pong"></part>
+ </message>
+ <message name="PongResponse">
+ <part name="parameters"
element="tns:PongResponse"></part>
+ </message>
+ <message name="PingRequest">
+ <part name="parameters" element="tns:Ping"></part>
+ </message>
+ <message name="PingResponse">
+ <part name="parameters"
element="tns:PingResponse"></part>
+ </message>
+ <portType name="PingPongPortType">
+ <operation name="Pong">
+ <input message="tns:PongRequest"></input>
+ <output message="tns:PongResponse"></output>
+ </operation>
+ <operation name="Ping">
+ <input message="tns:PingRequest"></input>
+ <output message="tns:PingResponse"></output>
+ </operation>
+ </portType>
+
+ <plnk:partnerLinkType name="PingPongPLT">
+ <plnk:role name="Provider"
portType="tns:PingPongPortType"/>
+ </plnk:partnerLinkType>
+</definitions>
Added:
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/Pong.bpel
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/Pong.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/Pong.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,70 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<process
+ name="Pong"
+
xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
+ targetNamespace="urn:/PingPong"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:tns="urn:/PingPong"
+
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+
+ <import location="Pong.wsdl"
+
namespace="http://www.example.org/common/"
+
importType="http://schemas.xmlsoap.org/wsdl/" />
+
+ <partnerLinks>
+ <partnerLink name="PongPartnerLink"
+ partnerLinkType="tns:PingPongPLT"
+ myRole="Provider" />
+ </partnerLinks>
+
+ <variables>
+ <variable messageType="tns:PongRequest"
name="pongRequest"/>
+ <variable messageType="tns:PongResponse"
name="pongResponse"/>
+ </variables>
+
+ <sequence name="Main">
+ <receive name="pongReceive"
+ createInstance="yes"
+ operation="Pong"
+ partnerLink="PongPartnerLink"
+ portType="tns:PingPongPortType"
+ variable="pongRequest"/>
+
+ <assign name="assignPongResponse">
+ <copy>
+ <from>
+ <literal>
+ <tns:PongResponse>
+ <tns:out>test</tns:out>
+ </tns:PongResponse>
+ </literal>
+ </from>
+ <to>$pongResponse.parameters</to>
+ </copy>
+ </assign>
+
+ <reply name="pongReply"
+ partnerLink="PongPartnerLink"
+ portType="tns:PingPongPortType"
+ operation="Pong"
+ variable="pongResponse"/>
+ </sequence>
+</process>
Added:
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/Pong.wsdl
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/Pong.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/Pong.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,54 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions name="Pong"
+ targetNamespace="urn:/PingPong"
+ xmlns:tns="urn:/PingPong"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns="http://schemas.xmlsoap.org/wsdl/"
xmlns:p="http://www.w3.org/2001/XMLSchema">
+
+ <import location="PingPong.wsdl"
namespace="urn:/PingPong"></import>
+ <binding name="PingPongBinding2"
type="tns:PingPongPortType">
+ <soap:binding style="document"
transport="http://schemas.xmlsoap.org/soap/http" />
+ <operation name="Ping">
+ <soap:operation soapAction="urn:/Ping" />
+ <input>
+ <soap:body use="literal" />
+ </input>
+ <output>
+ <soap:body use="literal" />
+ </output>
+ </operation>
+ <operation name="Pong">
+ <soap:operation soapAction="urn:/Pong" />
+ <input>
+ <soap:body use="literal" />
+ </input>
+ <output>
+ <soap:body use="literal" />
+ </output>
+ </operation>
+ </binding>
+ <service name="PingPongService2">
+ <port name="Port2" binding="tns:PingPongBinding2">
+ <soap:address
location="http://localhost:8888/ode/processes/PingPongService2/" />
+ </port>
+ </service>
+</definitions>
Added:
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/deploy.xml
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/deploy.xml
(rev 0)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/deploy.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,38 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<deploy
xmlns="http://www.apache.org/ode/schemas/dd/2007/03"
+ xmlns:p="urn:/PingPong">
+
+ <process name="p:Ping">
+ <active>true</active>
+ <provide partnerLink="PingPartnerLink">
+ <service name="p:PingPongService" port="Port1"/>
+ </provide>
+ <invoke partnerLink="PongPartnerLink" usePeer2Peer="false">
+ <service name="p:PingPongService" port="Port2"/>
+ </invoke>
+ </process>
+ <process name="p:Pong">
+ <active>true</active>
+ <provide partnerLink="PongPartnerLink">
+ <service name="p:PingPongService2" port="Port2"/>
+ </provide>
+ </process>
+</deploy>
Added:
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/testRequest.soap
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/testRequest.soap
(rev 0)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestClusteredOutgoingTraffic/testRequest.soap 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:pin="urn:/PingPong">
+ <soapenv:Header/>
+ <soapenv:Body>
+ <pin:Ping>
+ <in>test</in>
+ </pin:Ping>
+ </soapenv:Body>
+</soapenv:Envelope>
Added:
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestCorrelationUnicity/CorrelationMultiTest.bpel
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestCorrelationUnicity/CorrelationMultiTest.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestCorrelationUnicity/CorrelationMultiTest.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,86 @@
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<process name="HeaderTest"
+ targetNamespace="http://ode/bpel/unit-test"
+
xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
+ xmlns:tns="http://ode/bpel/unit-test"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:test="http://ode/bpel/unit-test.wsdl"
+ xmlns:dummy="http://axis2.ode.apache.org"
+ queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
+ expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+
+ <import location="CorrelationMultiTest.wsdl"
+ namespace="http://ode/bpel/unit-test.wsdl"
+
importType="http://schemas.xmlsoap.org/wsdl/" />
+
+ <partnerLinks>
+ <partnerLink name="helloPartnerLink"
+ partnerLinkType="test:HeaderTestPartnerLinkType" myRole="me"
/>
+ <partnerLink name="dummyPartnerLink"
+ partnerLinkType="test:DummyPartnerLinkType"
partnerRole="you" />
+ </partnerLinks>
+
+ <variables>
+ <variable name="myInVar"
messageType="test:HeaderTestMessage"/>
+ <variable name="myOutVar"
messageType="test:HeaderTestMessage"/>
+ <variable name="input"
messageType="dummy:longOperationRequest"/>
+ <variable name="output"
messageType="dummy:longOperationResponse"/>
+ </variables>
+ <correlationSets>
+ <correlationSet name="testCorr1"
properties="test:testCorrelationID1"/>
+ <correlationSet name="testCorr2"
properties="test:testCorrelationID2"/>
+ <correlationSet name="testCorr3"
properties="test:testCorrelationID3"/>
+ <correlationSet name="testCorr4"
properties="test:testCorrelationID4"/>
+ </correlationSets>
+ <sequence>
+ <receive name="start" partnerLink="helloPartnerLink"
portType="test:HeaderTestPortType"
+ operation="hello" variable="myInVar"
createInstance="yes">
+ <correlations>
+ <correlation set="testCorr1" initiate="yes"/>
+ </correlations>
+ </receive>
+
+ <assign>
+ <copy>
+ <from>'correlationUnicity1'</from>
+ <to>$myOutVar.TestPart</to>
+ </copy>
+ </assign>
+
+ <reply name="end" partnerLink="helloPartnerLink"
portType="test:HeaderTestPortType"
+ operation="hello" variable="myOutVar"/>
+
+ <receive name="receive2" partnerLink="helloPartnerLink"
portType="test:HeaderTestPortType"
+ operation="continue" variable="myInVar">
+ <correlations>
+ <correlation set="testCorr1" initiate="no"/>
+ </correlations>
+ </receive>
+ <assign>
+ <copy>
+ <from>
+ concat($myOutVar.TestPart, $myInVar.TestPart/requestText)
+ </from>
+ <to>$myOutVar.TestPart</to>
+ </copy>
+ </assign>
+
+ </sequence>
+</process>
Added:
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestCorrelationUnicity/CorrelationMultiTest.wsdl
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestCorrelationUnicity/CorrelationMultiTest.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestCorrelationUnicity/CorrelationMultiTest.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,125 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<wsdl:definitions
+ targetNamespace="http://ode/bpel/unit-test.wsdl"
+
xmlns="http://schemas.xmlsoap.org/wsdl/"
+ xmlns:tns="http://ode/bpel/unit-test.wsdl"
+ xmlns:typens="http://ode/bpel/unit-test/testCorrelation.wsdl.types"
+
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+ xmlns:dummy="http://axis2.ode.apache.org"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns:prop="http://docs.oasis-open.org/wsbpel/2.0/varprop">
+
+ <wsdl:import namespace="http://axis2.ode.apache.org"
location="dummy-service.wsdl"/>
+
+ <wsdl:types>
+ <xsd:schema
+
targetNamespace="http://ode/bpel/unit-test/testCorrelation.wsdl.types"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
+
+ <xsd:complexType name="testMessage">
+ <xsd:sequence>
+ <xsd:element name="correlationID1"
type="xsd:string"/>
+ <xsd:element name="correlationID2"
type="xsd:string"/>
+ <xsd:element name="correlationID3"
type="xsd:string"/>
+ <xsd:element name="correlationID4"
type="xsd:string"/>
+ <xsd:element name="requestText"
type="xsd:string"/>
+ </xsd:sequence>
+ </xsd:complexType>
+ </xsd:schema>
+ </wsdl:types>
+
+ <wsdl:message name="HeaderTestMessage">
+ <wsdl:part name="TestPart" type="typens:testMessage"/>
+ </wsdl:message>
+
+ <wsdl:portType name="HeaderTestPortType">
+ <wsdl:operation name="hello">
+ <wsdl:input message="tns:HeaderTestMessage"
name="TestIn"/>
+ <wsdl:output message="tns:HeaderTestMessage"
name="TestOut"/>
+ </wsdl:operation>
+ <wsdl:operation name="continue">
+ <wsdl:input message="tns:HeaderTestMessage"
name="TestIn"/>
+ </wsdl:operation>
+ </wsdl:portType>
+
+ <wsdl:binding name="HeaderTestSoapBinding"
type="tns:HeaderTestPortType">
+ <soap:binding style="rpc"
transport="http://schemas.xmlsoap.org/soap/http"/>
+ <wsdl:operation name="hello">
+ <soap:operation soapAction="" style="rpc"/>
+ <wsdl:input>
+ <soap:body namespace="http://ode/bpel/unit-test.wsdl"
use="literal"/>
+ </wsdl:input>
+ <wsdl:output>
+ <soap:body namespace="http://ode/bpel/unit-test.wsdl"
use="literal"/>
+ </wsdl:output>
+ </wsdl:operation>
+ <wsdl:operation name="continue">
+ <soap:operation soapAction="" style="rpc"/>
+ <wsdl:input>
+ <soap:body namespace="http://ode/bpel/unit-test.wsdl"
use="literal"/>
+ </wsdl:input>
+ </wsdl:operation>
+ </wsdl:binding>
+ <wsdl:service name="HeaderTestService">
+ <wsdl:port name="HeaderTestPort"
binding="tns:HeaderTestSoapBinding">
+ <soap:address
location="http://localhost:8888/ode/processes/correlationMultiTest"/>
+ </wsdl:port>
+ </wsdl:service>
+
+ <plnk:partnerLinkType name="HeaderTestPartnerLinkType">
+ <plnk:role name="me"
portType="tns:HeaderTestPortType"/>
+ <plnk:role name="you"
portType="tns:HeaderTestPortType"/>
+ </plnk:partnerLinkType>
+ <plnk:partnerLinkType name="DummyPartnerLinkType">
+ <plnk:role name="you"
portType="dummy:DummyServicePortType"/>
+ </plnk:partnerLinkType>
+
+ <prop:property name="testCorrelationID1"
type="xsd:string"/>
+ <prop:propertyAlias propertyName="tns:testCorrelationID1"
messageType="tns:HeaderTestMessage" part="TestPart">
+ <prop:query
queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ correlationID1
+ </prop:query>
+ </prop:propertyAlias>
+
+ <prop:property name="testCorrelationID2"
type="xsd:string"/>
+ <prop:propertyAlias propertyName="tns:testCorrelationID2"
messageType="tns:HeaderTestMessage" part="TestPart">
+ <prop:query
queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ correlationID2
+ </prop:query>
+ </prop:propertyAlias>
+
+ <prop:property name="testCorrelationID3"
type="xsd:string"/>
+ <prop:propertyAlias propertyName="tns:testCorrelationID3"
messageType="tns:HeaderTestMessage" part="TestPart">
+ <prop:query
queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ correlationID3
+ </prop:query>
+ </prop:propertyAlias>
+
+ <prop:property name="testCorrelationID4"
type="xsd:string"/>
+ <prop:propertyAlias propertyName="tns:testCorrelationID4"
messageType="tns:HeaderTestMessage" part="TestPart">
+ <prop:query
queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ correlationID4
+ </prop:query>
+ </prop:propertyAlias>
+</wsdl:definitions>
\ No newline at end of file
Added:
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestCorrelationUnicity/deploy.xml
===================================================================
--- branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestCorrelationUnicity/deploy.xml
(rev 0)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestCorrelationUnicity/deploy.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,33 @@
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<deploy
xmlns="http://www.apache.org/ode/schemas/dd/2007/03"
+ xmlns:pns="http://ode/bpel/unit-test"
+ xmlns:wns="http://ode/bpel/unit-test.wsdl"
xmlns:dns="http://axis2.ode.apache.org">
+
+
+ <process name="pns:HeaderTest">
+ <active>true</active>
+ <provide partnerLink="helloPartnerLink">
+ <service name="wns:HeaderTestService"
port="HeaderTestPort"/>
+ </provide>
+ <invoke partnerLink="dummyPartnerLink">
+ <service name="dns:DummyService"
port="DummyServiceSOAP11port_http"/>
+ </invoke>
+ </process>
+</deploy>
Added:
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestCorrelationUnicity/dummy-service.wsdl
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestCorrelationUnicity/dummy-service.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestCorrelationUnicity/dummy-service.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,229 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<wsdl:definitions
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
+
xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"
+
xmlns:ns0="http://axis2.ode.apache.org/xsd"
+
xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/"
+
xmlns:http="http://schemas.xmlsoap.org/wsdl/http/"
+ xmlns:ns1="http://axis2.ode.apache.org"
+
xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl"
+
xmlns:xs="http://www.w3.org/2001/XMLSchema"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+ targetNamespace="http://axis2.ode.apache.org">
+ <wsdl:types>
+ <xs:schema xmlns:ns="http://axis2.ode.apache.org"
attributeFormDefault="qualified"
+ elementFormDefault="unqualified"
targetNamespace="http://axis2.ode.apache.org">
+
+ <xs:element name="DummyException">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element minOccurs="0" name="reason"
nillable="true" type="xs:string"/>
+ </xs:sequence>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="faultTest">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element minOccurs="0" name="in"
nillable="true" type="xs:string"/>
+ </xs:sequence>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="faultTestResponse">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element minOccurs="0" name="return"
nillable="true" type="xs:string"/>
+ </xs:sequence>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="hello">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element minOccurs="0" name="in"
nillable="true" type="xs:string"/>
+ </xs:sequence>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="helloResponse">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element minOccurs="0" name="return"
nillable="true" type="xs:string"/>
+ </xs:sequence>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="longOperation">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element minOccurs="0" name="in"
nillable="true" type="xs:string"/>
+ </xs:sequence>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="longOperationResponse">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element minOccurs="0" name="return"
nillable="true" type="xs:string"/>
+ </xs:sequence>
+ </xs:complexType>
+ </xs:element>
+ </xs:schema>
+ </wsdl:types>
+ <wsdl:message name="faultTestRequest">
+ <wsdl:part name="parameters" element="ns1:faultTest"/>
+ </wsdl:message>
+ <wsdl:message name="faultTestResponse">
+ <wsdl:part name="parameters"
element="ns1:faultTestResponse"/>
+ </wsdl:message>
+ <wsdl:message name="DummyExceptionType">
+ <wsdl:part name="parameters"
element="ns1:DummyException"/>
+ </wsdl:message>
+ <wsdl:message name="helloRequest">
+ <wsdl:part name="parameters" element="ns1:hello"/>
+ </wsdl:message>
+ <wsdl:message name="helloResponse">
+ <wsdl:part name="parameters"
element="ns1:helloResponse"/>
+ </wsdl:message>
+ <wsdl:message name="longOperationRequest">
+ <wsdl:part name="parameters"
element="ns1:longOperation"/>
+ </wsdl:message>
+ <wsdl:message name="longOperationResponse">
+ <wsdl:part name="parameters"
element="ns1:longOperationResponse"/>
+ </wsdl:message>
+ <wsdl:portType name="DummyServicePortType">
+ <wsdl:operation name="faultTest">
+ <wsdl:input message="ns1:faultTestRequest"
wsaw:Action="urn:faultTest"/>
+ <wsdl:output message="ns1:faultTestResponse"
wsaw:Action="urn:faultTestResponse"/>
+ <wsdl:fault message="ns1:DummyExceptionType"
name="DummyException"
+ wsaw:Action="urn:faultTestDummyException"/>
+ </wsdl:operation>
+ <wsdl:operation name="hello">
+ <wsdl:input message="ns1:helloRequest"
wsaw:Action="urn:hello"/>
+ <wsdl:output message="ns1:helloResponse"
wsaw:Action="urn:helloResponse"/>
+ </wsdl:operation>
+ <wsdl:operation name="longOperation">
+ <wsdl:input message="ns1:longOperationRequest"
wsaw:Action="urn:longOperation"/>
+ <wsdl:output message="ns1:longOperationResponse"
wsaw:Action="urn:longOperationResponse"/>
+ </wsdl:operation>
+ </wsdl:portType>
+ <wsdl:binding name="DummyServiceSOAP11Binding"
type="ns1:DummyServicePortType">
+ <soap:binding
transport="http://schemas.xmlsoap.org/soap/http"
style="document"/>
+ <wsdl:operation name="faultTest">
+ <soap:operation soapAction="urn:faultTest"
style="document"/>
+ <wsdl:input>
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output>
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="DummyException">
+ <soap:fault use="literal" name="DummyException"/>
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="hello">
+ <soap:operation soapAction="urn:hello"
style="document"/>
+ <wsdl:input>
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output>
+ <soap:body use="literal"/>
+ </wsdl:output>
+ </wsdl:operation>
+ <wsdl:operation name="longOperation">
+ <soap:operation soapAction="urn:longOperation"
style="document"/>
+ <wsdl:input>
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output>
+ <soap:body use="literal"/>
+ </wsdl:output>
+ </wsdl:operation>
+ </wsdl:binding>
+ <wsdl:binding name="DummyServiceSOAP12Binding"
type="ns1:DummyServicePortType">
+ <soap12:binding
transport="http://schemas.xmlsoap.org/soap/http"
style="document"/>
+ <wsdl:operation name="faultTest">
+ <soap12:operation soapAction="urn:faultTest"
style="document"/>
+ <wsdl:input>
+ <soap12:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output>
+ <soap12:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="DummyException">
+ <soap12:fault use="literal"
name="DummyException"/>
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="hello">
+ <soap12:operation soapAction="urn:hello"
style="document"/>
+ <wsdl:input>
+ <soap12:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output>
+ <soap12:body use="literal"/>
+ </wsdl:output>
+ </wsdl:operation>
+ <wsdl:operation name="longOperation">
+ <soap12:operation soapAction="urn:hello"
style="document"/>
+ <wsdl:input>
+ <soap12:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output>
+ <soap12:body use="literal"/>
+ </wsdl:output>
+ </wsdl:operation>
+ </wsdl:binding>
+ <wsdl:binding name="DummyServiceHttpBinding"
type="ns1:DummyServicePortType">
+ <http:binding verb="POST"/>
+ <wsdl:operation name="faultTest">
+ <http:operation location="DummyService/faultTest"/>
+ <wsdl:input>
+ <mime:content type="text/xml" part="faultTest"/>
+ </wsdl:input>
+ <wsdl:output>
+ <mime:content type="text/xml" part="faultTest"/>
+ </wsdl:output>
+ </wsdl:operation>
+ <wsdl:operation name="hello">
+ <http:operation location="DummyService/hello"/>
+ <wsdl:input>
+ <mime:content type="text/xml" part="hello"/>
+ </wsdl:input>
+ <wsdl:output>
+ <mime:content type="text/xml" part="hello"/>
+ </wsdl:output>
+ </wsdl:operation>
+ <wsdl:operation name="longOperation">
+ <http:operation location="DummyService/hello"/>
+ <wsdl:input>
+ <mime:content type="text/xml" part="hello"/>
+ </wsdl:input>
+ <wsdl:output>
+ <mime:content type="text/xml" part="hello"/>
+ </wsdl:output>
+ </wsdl:operation>
+ </wsdl:binding>
+ <wsdl:service name="DummyService">
+ <wsdl:port name="DummyServiceSOAP11port_http"
binding="ns1:DummyServiceSOAP11Binding">
+ <soap:address
location="http://localhost:8888/processes/DummyService"/>
+ </wsdl:port>
+ <wsdl:port name="DummyServiceSOAP12port_http"
binding="ns1:DummyServiceSOAP12Binding">
+ <soap12:address
location="http://localhost:8888/processes/DummyService"/>
+ </wsdl:port>
+ <wsdl:port name="DummyServiceHttpport"
binding="ns1:DummyServiceHttpBinding">
+ <http:address
location="http://localhost:8888/processes/DummyService"/>
+ </wsdl:port>
+ </wsdl:service>
+</wsdl:definitions>
\ No newline at end of file
Added:
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestCorrelationUnicity/testRequest.soap
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestCorrelationUnicity/testRequest.soap
(rev 0)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestCorrelationUnicity/testRequest.soap 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<SOAP-ENV:Envelope
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
+ <SOAP-ENV:Header>
+ <myns:ConversationId
xmlns:myns="http://my.company/super/protocol">ZZZXYZ</myns:ConversationId>
+ </SOAP-ENV:Header>
+ <!-- test soap message -->
+ <SOAP-ENV:Body>
+ <ns1:hello xmlns:ns1="http://ode/bpel/unit-test.wsdl">
+ <TestPart
xmlns=""><correlationID1>CORR1</correlationID1><correlationID2>CORR2</correlationID2><correlationID3>CORR3</correlationID3><correlationID4>CORR4</correlationID4><requestText>1;</requestText></TestPart>
+ </ns1:hello>
+ </SOAP-ENV:Body>
+</SOAP-ENV:Envelope>
Added:
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestCorrelationUnicity/testRequest2.soap
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestCorrelationUnicity/testRequest2.soap
(rev 0)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestCorrelationUnicity/testRequest2.soap 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<SOAP-ENV:Envelope
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
+ <SOAP-ENV:Header>
+ <myns:ConversationId
xmlns:myns="http://my.company/super/protocol">ZZZXYZ</myns:ConversationId>
+ </SOAP-ENV:Header>
+ <!-- test soap message -->
+ <SOAP-ENV:Body>
+ <ns1:continue xmlns:ns1="http://ode/bpel/unit-test.wsdl">
+ <TestPart
xmlns=""><correlationID1>CORR1</correlationID1><correlationID2>CORR2</correlationID2><correlationID3>CORR3</correlationID3><correlationID4>CORR4</correlationID4><requestText>2;</requestText></TestPart>
+ </ns1:continue>
+ </SOAP-ENV:Body>
+</SOAP-ENV:Envelope>
Added:
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/1/TestRetire.bpel
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/1/TestRetire.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/1/TestRetire.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,66 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<process name="TestRetire1"
+ targetNamespace="http://ode/bpel/test/retire"
+
xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
+ xmlns:tns="http://ode/bpel/responder"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:resp="http://ode/bpel/test/retire/responder.wsdl">
+
+ <import location="TestRetire.wsdl"
namespace="http://ode/bpel/test/retire.wsdl"
+
importType="http://schemas.xmlsoap.org/wsdl/" />
+
+ <partnerLinks>
+ <partnerLink name="testRetirePartnerLink"
partnerLinkType="resp:TestRetirePartnerLinkType"
myRole="responder"/>
+ </partnerLinks>
+
+ <variables>
+ <variable name="dummy"
messageType="resp:TestRetireMessage"/>
+ </variables>
+
+ <correlationSets>
+ <correlationSet name="dummyCorr"
properties="resp:dummyProp" />
+ </correlationSets>
+
+ <sequence>
+ <receive name="start" partnerLink="testRetirePartnerLink"
variable="dummy" operation="first" createInstance="yes">
+ <correlations>
+ <correlation set="dummyCorr" initiate="yes"/>
+ </correlations>
+ </receive>
+ <reply name="reply-endpoint"
partnerLink="testRetirePartnerLink" operation="first"
variable="dummy"/>
+
+
+ <receive name="second" partnerLink="testRetirePartnerLink"
variable="dummy" operation="second">
+ <correlations>
+ <correlation set="dummyCorr" initiate="no"/>
+ </correlations>
+ </receive>
+ <assign>
+ <copy>
+ <from><literal>DONE</literal></from>
+ <to>$dummy.TestPart</to>
+ </copy>
+ </assign>
+ <reply name="reply-ack"
partnerLink="testRetirePartnerLink" operation="second"
variable="dummy"/>
+
+ </sequence>
+</process>
Added:
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/1/TestRetire.wsdl
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/1/TestRetire.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/1/TestRetire.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,74 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<wsdl:definitions
+ targetNamespace="http://ode/bpel/test/retire/responder.wsdl"
+
xmlns="http://schemas.xmlsoap.org/wsdl/"
+ xmlns:tns="http://ode/bpel/test/retire/responder.wsdl"
+
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+ xmlns:dummy="http://axis2.ode.apache.org"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns:prop="http://docs.oasis-open.org/wsbpel/2.0/varprop">
+
+ <wsdl:message name="TestRetireMessage">
+ <wsdl:part name="TestPart" type="xsd:string"/>
+ </wsdl:message>
+
+ <wsdl:portType name="TestRetirePortType">
+ <wsdl:operation name="first">
+ <wsdl:input message="tns:TestRetireMessage"
name="TestIn"/>
+ <wsdl:output message="tns:TestRetireMessage"
name="TestOut"/>
+ </wsdl:operation>
+ <wsdl:operation name="second">
+ <wsdl:input message="tns:TestRetireMessage"
name="TestIn"/>
+ <wsdl:output message="tns:TestRetireMessage"
name="TestOut"/>
+ </wsdl:operation>
+ </wsdl:portType>
+
+ <wsdl:binding name="TestRetireSoapBinding"
type="tns:TestRetirePortType">
+ <soap:binding style="rpc"
transport="http://schemas.xmlsoap.org/soap/http"/>
+ <wsdl:operation name="first">
+ <soap:operation soapAction="" style="rpc"/>
+ <wsdl:input><soap:body
namespace="http://ode/bpel/test/retire/responder.wsdl"
use="literal"/></wsdl:input>
+ <wsdl:output><soap:body
namespace="http://ode/bpel/unit-test.wsdl"
use="literal"/></wsdl:output>
+ </wsdl:operation>
+ <wsdl:operation name="second">
+ <soap:operation soapAction="" style="rpc"/>
+ <wsdl:input><soap:body
namespace="http://ode/bpel/test/retire/responder.wsdl"
use="literal"/></wsdl:input>
+ <wsdl:output><soap:body
namespace="http://ode/bpel/unit-test.wsdl"
use="literal"/></wsdl:output>
+ </wsdl:operation>
+ </wsdl:binding>
+ <wsdl:service name="TestRetireService">
+ <wsdl:port name="TestRetirePort"
binding="tns:TestRetireSoapBinding">
+ <soap:address
location="http://localhost:8888/ode/processes/testretire"/>
+ </wsdl:port>
+ </wsdl:service>
+
+ <plnk:partnerLinkType name="TestRetirePartnerLinkType">
+ <plnk:role name="responder"
portType="tns:TestRetirePortType"/>
+ </plnk:partnerLinkType>
+
+ <prop:property name="dummyProp" type="xsd:string"/>
+ <prop:propertyAlias propertyName="tns:dummyProp"
messageType="tns:TestRetireMessage" part="TestPart"/>
+
+</wsdl:definitions>
+
Added: branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/1/deploy.xml
===================================================================
--- branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/1/deploy.xml
(rev 0)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/1/deploy.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,29 @@
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<deploy
xmlns="http://www.apache.org/ode/schemas/dd/2007/03"
+ xmlns:pns="http://ode/bpel/test/retire"
+ xmlns:wns="http://ode/bpel/test/retire/responder.wsdl">
+
+ <process name="pns:TestRetire1">
+ <active>true</active>
+ <provide partnerLink="testRetirePartnerLink">
+ <service name="wns:TestRetireService"
port="TestRetirePort"/>
+ </provide>
+ </process>
+</deploy>
Added:
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/1/testRequest1.soap
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/1/testRequest1.soap
(rev 0)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/1/testRequest1.soap 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<SOAP-ENV:Envelope
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
+ <SOAP-ENV:Body>
+ <tns:first
xmlns:tns="http://ode/bpel/test/retire/responder.wsdl"><TestPart>TEST1</TestPart></tns:first>
+ </SOAP-ENV:Body>
+</SOAP-ENV:Envelope>
Added:
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/1/testRequest2.soap
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/1/testRequest2.soap
(rev 0)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/1/testRequest2.soap 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<SOAP-ENV:Envelope
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
+ <SOAP-ENV:Body>
+ <tns:first
xmlns:tns="http://ode/bpel/test/retire/responder.wsdl"><TestPart>TEST2</TestPart></tns:first>
+ </SOAP-ENV:Body>
+</SOAP-ENV:Envelope>
Added:
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/2/TestRetire.bpel
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/2/TestRetire.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/2/TestRetire.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,59 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<process name="TestRetire2"
+ targetNamespace="http://ode/bpel/test/retire"
+
xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
+ xmlns:tns="http://ode/bpel/responder"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:resp="http://ode/bpel/test/retire/responder.wsdl">
+
+ <import location="TestRetire.wsdl"
namespace="http://ode/bpel/test/retire.wsdl"
+
importType="http://schemas.xmlsoap.org/wsdl/" />
+
+ <partnerLinks>
+ <partnerLink name="testRetirePartnerLink"
partnerLinkType="resp:TestRetirePartnerLinkType"
myRole="responder"/>
+ </partnerLinks>
+
+ <variables>
+ <variable name="dummy"
messageType="resp:TestRetireMessage"/>
+ </variables>
+
+ <correlationSets>
+ <correlationSet name="dummyCorr" properties="resp:dummyProp"
/>
+ </correlationSets>
+
+ <sequence>
+ <receive name="start" partnerLink="testRetirePartnerLink"
variable="dummy" operation="first" createInstance="yes">
+ <correlations>
+ <correlation set="dummyCorr" initiate="yes"/>
+ </correlations>
+ </receive>
+ <reply name="reply-endpoint"
partnerLink="testRetirePartnerLink" operation="first"
variable="dummy"/>
+
+ <receive name="second" partnerLink="testRetirePartnerLink"
variable="dummy" operation="second">
+ <correlations>
+ <correlation set="dummyCorr" initiate="no"/>
+ </correlations>
+ </receive>
+ <reply name="reply-ack" partnerLink="testRetirePartnerLink"
operation="second" variable="dummy"/>
+
+ </sequence>
+</process>
Added:
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/2/TestRetire.wsdl
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/2/TestRetire.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/2/TestRetire.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,74 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<wsdl:definitions
+ targetNamespace="http://ode/bpel/test/retire/responder.wsdl"
+
xmlns="http://schemas.xmlsoap.org/wsdl/"
+ xmlns:tns="http://ode/bpel/test/retire/responder.wsdl"
+
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+ xmlns:dummy="http://axis2.ode.apache.org"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns:prop="http://docs.oasis-open.org/wsbpel/2.0/varprop">
+
+ <wsdl:message name="TestRetireMessage">
+ <wsdl:part name="TestPart" type="xsd:string"/>
+ </wsdl:message>
+
+ <wsdl:portType name="TestRetirePortType">
+ <wsdl:operation name="first">
+ <wsdl:input message="tns:TestRetireMessage"
name="TestIn"/>
+ <wsdl:output message="tns:TestRetireMessage"
name="TestOut"/>
+ </wsdl:operation>
+ <wsdl:operation name="second">
+ <wsdl:input message="tns:TestRetireMessage"
name="TestIn"/>
+ <wsdl:output message="tns:TestRetireMessage"
name="TestOut"/>
+ </wsdl:operation>
+ </wsdl:portType>
+
+ <wsdl:binding name="TestRetireSoapBinding"
type="tns:TestRetirePortType">
+ <soap:binding style="rpc"
transport="http://schemas.xmlsoap.org/soap/http"/>
+ <wsdl:operation name="first">
+ <soap:operation soapAction="" style="rpc"/>
+ <wsdl:input><soap:body
namespace="http://ode/bpel/test/retire/responder.wsdl"
use="literal"/></wsdl:input>
+ <wsdl:output><soap:body
namespace="http://ode/bpel/unit-test.wsdl"
use="literal"/></wsdl:output>
+ </wsdl:operation>
+ <wsdl:operation name="second">
+ <soap:operation soapAction="" style="rpc"/>
+ <wsdl:input><soap:body
namespace="http://ode/bpel/test/retire/responder.wsdl"
use="literal"/></wsdl:input>
+ <wsdl:output><soap:body
namespace="http://ode/bpel/unit-test.wsdl"
use="literal"/></wsdl:output>
+ </wsdl:operation>
+ </wsdl:binding>
+ <wsdl:service name="TestRetireService">
+ <wsdl:port name="TestRetirePort"
binding="tns:TestRetireSoapBinding">
+ <soap:address
location="http://localhost:8888/ode/processes/testretire"/>
+ </wsdl:port>
+ </wsdl:service>
+
+ <plnk:partnerLinkType name="TestRetirePartnerLinkType">
+ <plnk:role name="responder"
portType="tns:TestRetirePortType"/>
+ </plnk:partnerLinkType>
+
+ <prop:property name="dummyProp" type="xsd:string"/>
+ <prop:propertyAlias propertyName="tns:dummyProp"
messageType="tns:TestRetireMessage" part="TestPart"/>
+
+</wsdl:definitions>
+
Added: branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/2/deploy.xml
===================================================================
--- branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/2/deploy.xml
(rev 0)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestInstanceRetire2/2/deploy.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,29 @@
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<deploy
xmlns="http://www.apache.org/ode/schemas/dd/2007/03"
+ xmlns:pns="http://ode/bpel/test/retire"
+ xmlns:wns="http://ode/bpel/test/retire/responder.wsdl">
+
+ <process name="pns:TestRetire2">
+ <active>true</active>
+ <provide partnerLink="testRetirePartnerLink">
+ <service name="wns:TestRetireService"
port="TestRetirePort"/>
+ </provide>
+ </process>
+</deploy>
Added: branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/Ping.bpel
===================================================================
--- branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/Ping.bpel
(rev 0)
+++ branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/Ping.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,96 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<process
+ name="Ping"
+
xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
+ targetNamespace="urn:/PingPong"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:tns="urn:/PingPong"
+
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+
+ <import location="Ping.wsdl"
+
namespace="http://www.example.org/common/"
+
importType="http://schemas.xmlsoap.org/wsdl/" />
+
+ <partnerLinks>
+ <partnerLink name="PingPartnerLink"
+ partnerLinkType="tns:PingPongPLT"
+ myRole="Provider" />
+ <partnerLink name="PongPartnerLink"
+ partnerLinkType="tns:PingPongPLT"
+ partnerRole="Provider"
+ initializePartnerRole="yes" />
+ </partnerLinks>
+
+ <variables>
+ <variable messageType="tns:PingRequest"
name="pingRequest"/>
+ <variable messageType="tns:PingResponse"
name="pingResponse"/>
+ <variable messageType="tns:PongRequest"
name="pongRequest"/>
+ <variable messageType="tns:PongResponse"
name="pongResponse"/>
+ </variables>
+
+ <sequence name="Main">
+ <receive name="pingReceive"
+ createInstance="yes"
+ operation="Ping"
+ partnerLink="PingPartnerLink"
+ portType="tns:PingPongPortType"
+ variable="pingRequest"/>
+
+ <assign>
+ <copy>
+ <from>
+ <literal>
+ <tns:PongRequest>
+ <tns:in>test0</tns:in>
+ </tns:PongRequest>
+ </literal>
+ </from>
+ <to>$pongRequest.parameters</to>
+ </copy>
+ </assign>
+
+ <invoke name="invokePong"
+ operation="Pong"
+ inputVariable="pongRequest"
+ outputVariable="pongResponse"
+ partnerLink="PongPartnerLink"
+ portType="tns:PingPongPortType"/>
+
+ <assign name="assignPingResponse">
+ <copy>
+ <from>
+ <literal>
+ <tns:PingResponse>
+ <tns:out>magic</tns:out>
+ </tns:PingResponse>
+ </literal>
+ </from>
+ <to>$pingResponse.parameters</to>
+ </copy>
+ </assign>
+
+ <reply name="pingReply"
+ partnerLink="PingPartnerLink"
+ portType="tns:PingPongPortType"
+ operation="Ping"
+ variable="pingResponse"/>
+ </sequence>
+</process>
Added: branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/Ping.wsdl
===================================================================
--- branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/Ping.wsdl
(rev 0)
+++ branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/Ping.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,57 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions name="Ping"
+ targetNamespace="urn:/PingPong"
+ xmlns:tns="urn:/PingPong"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns="http://schemas.xmlsoap.org/wsdl/"
xmlns:p="http://www.w3.org/2001/XMLSchema">
+
+ <import location="PingPong.wsdl"
namespace="urn:/PingPong"></import>
+ <binding name="PingPongBinding"
type="tns:PingPongPortType">
+ <soap:binding style="document"
transport="http://schemas.xmlsoap.org/soap/http" />
+ <operation name="Ping">
+ <soap:operation soapAction="urn:/Ping" />
+ <input>
+ <soap:body use="literal" />
+ </input>
+ <output>
+ <soap:body use="literal" />
+ </output>
+ </operation>
+ <operation name="Pong">
+ <soap:operation soapAction="urn:/Pong" />
+ <input>
+ <soap:body use="literal" />
+ </input>
+ <output>
+ <soap:body use="literal" />
+ </output>
+ </operation>
+ </binding>
+ <service name="PingPongService">
+ <port name="Port1" binding="tns:PingPongBinding">
+ <soap:address
location="http://localhost:8888/ode/processes/PingPongService/" />
+ </port>
+ <port name="Port2" binding="tns:PingPongBinding">
+ <soap:address
location="http://localhost:8888/ode/processes/PingPongService2/" />
+ </port>
+ </service>
+</definitions>
Added: branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/PingPong.wsdl
===================================================================
--- branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/PingPong.wsdl
(rev 0)
+++ branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/PingPong.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,85 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions name="PingPong"
+ targetNamespace="urn:/PingPong"
+ xmlns:tns="urn:/PingPong"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns="http://schemas.xmlsoap.org/wsdl/"
xmlns:p="http://www.w3.org/2001/XMLSchema">
+
+ <types>
+ <xsd:schema
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
targetNamespace="urn:/PingPong">
+ <xsd:element name="Pong">
+ <xsd:complexType>
+ <xsd:sequence>
+ <xsd:element name="in"
type="xsd:string"></xsd:element>
+ </xsd:sequence>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="PongResponse">
+ <xsd:complexType>
+ <xsd:sequence>
+ <xsd:element name="out"
type="xsd:string"></xsd:element>
+ </xsd:sequence>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="Ping">
+ <xsd:complexType>
+ <xsd:sequence>
+ <xsd:element name="in"
type="xsd:string"></xsd:element>
+ </xsd:sequence>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="PingResponse">
+ <xsd:complexType>
+ <xsd:sequence>
+ <xsd:element name="out"
type="xsd:string"></xsd:element>
+ </xsd:sequence>
+ </xsd:complexType>
+ </xsd:element></xsd:schema>
+ </types>
+
+ <message name="PongRequest">
+ <part name="parameters" element="tns:Pong"></part>
+ </message>
+ <message name="PongResponse">
+ <part name="parameters"
element="tns:PongResponse"></part>
+ </message>
+ <message name="PingRequest">
+ <part name="parameters" element="tns:Ping"></part>
+ </message>
+ <message name="PingResponse">
+ <part name="parameters"
element="tns:PingResponse"></part>
+ </message>
+ <portType name="PingPongPortType">
+ <operation name="Pong">
+ <input message="tns:PongRequest"></input>
+ <output message="tns:PongResponse"></output>
+ </operation>
+ <operation name="Ping">
+ <input message="tns:PingRequest"></input>
+ <output message="tns:PingResponse"></output>
+ </operation>
+ </portType>
+
+ <plnk:partnerLinkType name="PingPongPLT">
+ <plnk:role name="Provider"
portType="tns:PingPongPortType"/>
+ </plnk:partnerLinkType>
+</definitions>
Added: branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/Pong.bpel
===================================================================
--- branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/Pong.bpel
(rev 0)
+++ branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/Pong.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,70 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<process
+ name="Pong"
+
xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
+ targetNamespace="urn:/PingPong"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:tns="urn:/PingPong"
+
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+
+ <import location="Pong.wsdl"
+
namespace="http://www.example.org/common/"
+
importType="http://schemas.xmlsoap.org/wsdl/" />
+
+ <partnerLinks>
+ <partnerLink name="PongPartnerLink"
+ partnerLinkType="tns:PingPongPLT"
+ myRole="Provider" />
+ </partnerLinks>
+
+ <variables>
+ <variable messageType="tns:PongRequest"
name="pongRequest"/>
+ <variable messageType="tns:PongResponse"
name="pongResponse"/>
+ </variables>
+
+ <sequence name="Main">
+ <receive name="pongReceive"
+ createInstance="yes"
+ operation="Pong"
+ partnerLink="PongPartnerLink"
+ portType="tns:PingPongPortType"
+ variable="pongRequest"/>
+
+ <assign name="assignPongResponse">
+ <copy>
+ <from>
+ <literal>
+ <tns:PongResponse>
+ <tns:out>test</tns:out>
+ </tns:PongResponse>
+ </literal>
+ </from>
+ <to>$pongResponse.parameters</to>
+ </copy>
+ </assign>
+
+ <reply name="pongReply"
+ partnerLink="PongPartnerLink"
+ portType="tns:PingPongPortType"
+ operation="Pong"
+ variable="pongResponse"/>
+ </sequence>
+</process>
Added: branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/Pong.wsdl
===================================================================
--- branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/Pong.wsdl
(rev 0)
+++ branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/Pong.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,54 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions name="Pong"
+ targetNamespace="urn:/PingPong"
+ xmlns:tns="urn:/PingPong"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns="http://schemas.xmlsoap.org/wsdl/"
xmlns:p="http://www.w3.org/2001/XMLSchema">
+
+ <import location="PingPong.wsdl"
namespace="urn:/PingPong"></import>
+ <binding name="PingPongBinding2"
type="tns:PingPongPortType">
+ <soap:binding style="document"
transport="http://schemas.xmlsoap.org/soap/http" />
+ <operation name="Ping">
+ <soap:operation soapAction="urn:/Ping" />
+ <input>
+ <soap:body use="literal" />
+ </input>
+ <output>
+ <soap:body use="literal" />
+ </output>
+ </operation>
+ <operation name="Pong">
+ <soap:operation soapAction="urn:/Pong" />
+ <input>
+ <soap:body use="literal" />
+ </input>
+ <output>
+ <soap:body use="literal" />
+ </output>
+ </operation>
+ </binding>
+ <service name="PingPongService2">
+ <port name="Port2" binding="tns:PingPongBinding2">
+ <soap:address
location="http://localhost:8888/ode/processes/PingPongService2/" />
+ </port>
+ </service>
+</definitions>
Added: branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/deploy.xml
===================================================================
--- branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/deploy.xml
(rev 0)
+++ branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/deploy.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,38 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<deploy
xmlns="http://www.apache.org/ode/schemas/dd/2007/03"
+ xmlns:p="urn:/PingPong">
+
+ <process name="p:Ping">
+ <active>true</active>
+ <provide partnerLink="PingPartnerLink">
+ <service name="p:PingPongService" port="Port1"/>
+ </provide>
+ <invoke partnerLink="PongPartnerLink" usePeer2Peer="false">
+ <service name="p:PingPongService" port="Port2"/>
+ </invoke>
+ </process>
+ <process name="p:Pong">
+ <active>true</active>
+ <provide partnerLink="PongPartnerLink">
+ <service name="p:PingPongService2" port="Port2"/>
+ </provide>
+ </process>
+</deploy>
Added: branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/testRequest.soap
===================================================================
--- branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/testRequest.soap
(rev 0)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestNoP2P/testRequest.soap 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:pin="urn:/PingPong">
+ <soapenv:Header/>
+ <soapenv:Body>
+ <pin:Ping>
+ <in>test</in>
+ </pin:Ping>
+ </soapenv:Body>
+</soapenv:Envelope>
Modified: branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestSoapHeader2/hello.xsd
===================================================================
--- branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestSoapHeader2/hello.xsd 2010-04-14
15:43:12 UTC (rev 619)
+++ branches/ODE/ODE-1.x/axis2-war/src/test/resources/TestSoapHeader2/hello.xsd 2010-04-14
18:25:55 UTC (rev 620)
@@ -1,30 +1,30 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<xsd:schema targetNamespace="http://ode/bpel/unit-test.wsdl"
-
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
- attributeFormDefault="qualified"
elementFormDefault="qualified">
-
- <xsd:element name="header1">
- <xsd:complexType>
- <xsd:sequence>
- <xsd:element name="header1-field1"
type="xsd:string" />
- </xsd:sequence>
- </xsd:complexType>
- </xsd:element>
-
- <xsd:element name="header2">
- <xsd:complexType>
- <xsd:sequence>
- <xsd:element name="header2-field1"
type="xsd:string" />
- </xsd:sequence>
- </xsd:complexType>
- </xsd:element>
-
- <xsd:element name="body">
- <xsd:complexType>
- <xsd:sequence>
- <xsd:element name="message" type="xsd:string"
/>
- </xsd:sequence>
- </xsd:complexType>
- </xsd:element>
-
-</xsd:schema>
+<?xml version="1.0" encoding="UTF-8"?>
+<xsd:schema targetNamespace="http://ode/bpel/unit-test.wsdl"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ attributeFormDefault="qualified"
elementFormDefault="qualified">
+
+ <xsd:element name="header1">
+ <xsd:complexType>
+ <xsd:sequence>
+ <xsd:element name="header1-field1"
type="xsd:string" />
+ </xsd:sequence>
+ </xsd:complexType>
+ </xsd:element>
+
+ <xsd:element name="header2">
+ <xsd:complexType>
+ <xsd:sequence>
+ <xsd:element name="header2-field1"
type="xsd:string" />
+ </xsd:sequence>
+ </xsd:complexType>
+ </xsd:element>
+
+ <xsd:element name="body">
+ <xsd:complexType>
+ <xsd:sequence>
+ <xsd:element name="message" type="xsd:string"
/>
+ </xsd:sequence>
+ </xsd:complexType>
+ </xsd:element>
+
+</xsd:schema>
Modified:
branches/ODE/ODE-1.x/axis2-war/src/test/webapp/WEB-INF/conf.hib-derby/ode-axis2.properties
===================================================================
---
branches/ODE/ODE-1.x/axis2-war/src/test/webapp/WEB-INF/conf.hib-derby/ode-axis2.properties 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/axis2-war/src/test/webapp/WEB-INF/conf.hib-derby/ode-axis2.properties 2010-04-14
18:25:55 UTC (rev 620)
@@ -17,4 +17,7 @@
ode-axis2.dao.factory=org.apache.ode.axis2.instancecleanup.HibDaoConnectionFactoryImpl
ode-axis2.db.emb.name=hibdb
-ode-axis2.db.mode=EMBEDDED
\ No newline at end of file
+ode-axis2.db.mode=EMBEDDED
+ode-axis2.cluster.localRoute.targets=http://doesntexist:8080/ode/processes/
+ode-axis2.cluster.localRoute.base=http://localhost:8888/ode/processes/
+ode-axis2.event.listeners=org.apache.ode.bpel.common.evt.DebugBpelEventListener
Added: branches/ODE/ODE-1.x/bpel-api/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/bpel-api/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/bpel-api/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,56 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-api</artifactId>
+ <name>ODE :: APIs</name>
+ <packaging>jar</packaging>
+ <modelVersion>4.0.0</modelVersion>
+
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-utils</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-schemas</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-obj</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>wsdl4j</groupId>
+ <artifactId>wsdl4j</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-logging</groupId>
+ <artifactId>commons-logging</artifactId>
+ </dependency>
+ </dependencies>
+</project>
Modified:
branches/ODE/ODE-1.x/bpel-api/src/main/java/org/apache/ode/bpel/explang/EvaluationContext.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-api/src/main/java/org/apache/ode/bpel/explang/EvaluationContext.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-api/src/main/java/org/apache/ode/bpel/explang/EvaluationContext.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -19,6 +19,7 @@
package org.apache.ode.bpel.explang;
import java.net.URI;
+import java.util.Date;
import javax.xml.namespace.QName;
@@ -122,4 +123,5 @@
*/
Node getPropertyValue(QName propertyName);
+ Date getCurrentEventDateTime();
}
Modified:
branches/ODE/ODE-1.x/bpel-api/src/main/java/org/apache/ode/bpel/iapi/ProcessConf.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-api/src/main/java/org/apache/ode/bpel/iapi/ProcessConf.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-api/src/main/java/org/apache/ode/bpel/iapi/ProcessConf.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -32,6 +32,7 @@
import javax.xml.namespace.QName;
import org.apache.ode.bpel.evt.BpelEvent;
+import org.apache.ode.bpel.o.OFailureHandling;
import org.apache.ode.utils.CronExpression;
import org.w3c.dom.Element;
import org.w3c.dom.Node;
@@ -44,6 +45,17 @@
*/
public interface ProcessConf {
+ public static class PartnerRoleConfig {
+ public final OFailureHandling failureHandling;
+ public final boolean usePeer2Peer;
+
+ public PartnerRoleConfig(OFailureHandling failureHandling, boolean usePeer2Peer)
{
+ super();
+ this.failureHandling = failureHandling;
+ this.usePeer2Peer = usePeer2Peer;
+ }
+ }
+
/**
* Get the process id, generally the same as the type.
* @return process id.
@@ -156,6 +168,12 @@
* @return map of partner link names and associated enpoints
*/
Map<String, Endpoint> getInvokeEndpoints();
+
+ /**
+ * Returns failure handling info for invokes.
+ * @return
+ */
+ public Map<String, PartnerRoleConfig> getPartnerRoleConfig();
/**
* Tells if the service is shareable
Modified:
branches/ODE/ODE-1.x/bpel-api/src/main/java/org/apache/ode/bpel/iapi/Scheduler.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-api/src/main/java/org/apache/ode/bpel/iapi/Scheduler.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-api/src/main/java/org/apache/ode/bpel/iapi/Scheduler.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -61,9 +61,17 @@
* jobs scheduled from a transactional context should be scheduled
* regardless of whether the transaction commits.
*
+ * @param transacted should the job be executed in a transaction?
* @param jobDetail information about the job
+ * @param when does the job should be executed?
* @return unique (as far as the scheduler is concerned) job identifier
*/
+ String scheduleVolatileJob(boolean transacted, Map<String,Object> jobDetail,
Date when) throws ContextException;
+
+ /**
+ * Schedule a volatile job for right now
+ * @see #scheduleVolatileJob(boolean, java.util.Map, java.util.Date)
+ */
String scheduleVolatileJob(boolean transacted, Map<String,Object> jobDetail)
throws ContextException;
/**
@@ -86,6 +94,21 @@
<T> T execTransaction(Callable<T> transaction)
throws Exception, ContextException;
+ /**
+ * Execute a {@link Callable} in a transactional context. If the callable
+ * throws an exception, then the transaction will be rolled back, otherwise
+ * the transaction will commit. Also, modify the value of the timeout value
+ * that is associated with the transactions started by the current thread.
+ *
+ * @param <T> return type
+ * @param transaction transaction to execute
+ * @param timeout, The value of the timeout in seconds. If the value is zero, the
transaction service uses the default value.
+ * @return result
+ * @throws Exception
+ */
+ <T> T execTransaction(Callable<T> transaction, int timeout)
+ throws Exception, ContextException;
+
void setRollbackOnly() throws Exception;
/**
Modified:
branches/ODE/ODE-1.x/bpel-api/src/main/java/org/apache/ode/bpel/pmapi/ProcessInfoCustomizer.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-api/src/main/java/org/apache/ode/bpel/pmapi/ProcessInfoCustomizer.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-api/src/main/java/org/apache/ode/bpel/pmapi/ProcessInfoCustomizer.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -19,6 +19,7 @@
package org.apache.ode.bpel.pmapi;
+import java.util.EnumSet;
import java.util.HashSet;
import java.util.StringTokenizer;
@@ -28,7 +29,8 @@
*/
public class ProcessInfoCustomizer {
- public static final ProcessInfoCustomizer ALL = new
ProcessInfoCustomizer(Item.ENDPOINTS,Item.PROPERTIES,Item.SUMMARY);
+ public static final ProcessInfoCustomizer ALL = new
ProcessInfoCustomizer(Item.ENDPOINTS,Item.PROPERTIES,Item.DOCUMENTS,Item.SUMMARY);
+ public static final ProcessInfoCustomizer SUMMARYONLY = new
ProcessInfoCustomizer(Item.SUMMARY);
public static final ProcessInfoCustomizer NONE = new ProcessInfoCustomizer();
private HashSet<Item> _includes = new HashSet<Item>();
@@ -64,6 +66,10 @@
return _includes.contains(Item.SUMMARY);
}
+ public boolean includeDocumentLists() {
+ return _includes.contains(Item.DOCUMENTS);
+ }
+
public boolean includeProcessProperties() {
return _includes.contains(Item.PROPERTIES);
}
@@ -71,9 +77,10 @@
public boolean includeEndpoints() {
return _includes.contains(Item.ENDPOINTS);
}
-
+
public enum Item {
SUMMARY,
+ DOCUMENTS,
PROPERTIES,
ENDPOINTS
}
Modified:
branches/ODE/ODE-1.x/bpel-api/src/main/java/org/apache/ode/bpel/pmapi/ProcessManagement.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-api/src/main/java/org/apache/ode/bpel/pmapi/ProcessManagement.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-api/src/main/java/org/apache/ode/bpel/pmapi/ProcessManagement.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -51,6 +51,12 @@
ProcessInfoListDocument listAllProcesses();
/**
+ * List the processes known to the engine, excluding the document list, properties and
end point configs.
+ * @return list of {@link ProcessInfoDocument}s (including instance summaries)
+ */
+ ProcessInfoListDocument listProcessesSummaryOnly();
+
+ /**
* Get the process info for a process.
* @param pid name of the process
* @param custom used to customize the quantity of information returned
Added: branches/ODE/ODE-1.x/bpel-api-jca/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/bpel-api-jca/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/bpel-api-jca/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,44 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-api-jca</artifactId>
+ <name>ODE :: JCA Connector</name>
+ <packaging>jar</packaging>
+ <modelVersion>4.0.0</modelVersion>
+
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-j2ee-connector_1.5_spec</artifactId>
+ </dependency>
+ </dependencies>
+</project>
Added: branches/ODE/ODE-1.x/bpel-compiler/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/bpel-compiler/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/bpel-compiler/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,138 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-compiler</artifactId>
+ <name>ODE :: BPEL Compiler</name>
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-utils</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-schemas</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-collections</groupId>
+ <artifactId>commons-collections</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-logging</groupId>
+ <artifactId>commons-logging</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-lang</groupId>
+ <artifactId>commons-lang</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>jaxen</groupId>
+ <artifactId>jaxen</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-jta_1.1_spec</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-stax-api_1.0_spec</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>javax.persistence</groupId>
+ <artifactId>persistence-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>wsdl4j</groupId>
+ <artifactId>wsdl4j</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.xmlbeans</groupId>
+ <artifactId>xmlbeans</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon-xpath</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon-dom</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon-xqj</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>xerces</groupId>
+ <artifactId>xercesImpl</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>xalan</groupId>
+ <artifactId>xalan</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <artifactId>maven-dependency-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>copy-bpel-scripts-for-tests</id>
+ <phase>process-test-resources</phase>
+ <goals>
+ <goal>unpack</goal>
+ </goals>
+ <configuration>
+ <artifactItems>
+ <artifactItem>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-scripts</artifactId>
+
<outputDirectory>${project.build.testOutputDirectory}</outputDirectory>
+ </artifactItem>
+ </artifactItems>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+
+</project>
Modified:
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/AssignGenerator.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/AssignGenerator.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/AssignGenerator.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -34,6 +34,7 @@
import org.apache.ode.bpel.o.DebugInfo;
import org.apache.ode.bpel.o.OActivity;
import org.apache.ode.bpel.o.OAssign;
+import org.apache.ode.bpel.o.OVarType;
import org.apache.ode.bpel.o.OAssign.RValue;
import org.apache.ode.bpel.o.OMessageVarType;
import org.apache.ode.utils.DOMUtils;
@@ -71,13 +72,15 @@
ocopy.debugInfo = new DebugInfo(_context.getSourceLocation(),
scopy.getLineNo(),
source.getExtensibilityElements());
try {
- if (scopy.getFrom() == null)
- throw new
CompilationException(__cmsgs.errMissingFromSpec().setSource(scopy));
- ocopy.from = compileFrom(scopy.getFrom());
if (scopy.getTo() == null)
throw new
CompilationException(__cmsgs.errMissingToSpec().setSource(scopy));
- ocopy.to = compileTo(scopy.getTo());
+ Object[] toResultType = new Object[1];
+ ocopy.to = compileTo(scopy.getTo(), toResultType);
+ if (scopy.getFrom() == null)
+ throw new
CompilationException(__cmsgs.errMissingFromSpec().setSource(scopy));
+ ocopy.from = compileFrom(scopy.getFrom(), toResultType[0]);
+
verifyCopy(ocopy);
oassign.copy.add(ocopy);
@@ -150,7 +153,7 @@
__log.debug("Copy verified OK: " + ocopy);
}
- private OAssign.RValue compileFrom(From from) {
+ private OAssign.RValue compileFrom(From from, Object requestedResultType) {
assert from != null;
try {
if (from.isExtensionVal()) {
@@ -167,16 +170,19 @@
VariableVal vv = from.getAsVariableVal();
OAssign.VariableRef vref = new
OAssign.VariableRef(_context.getOProcess());
vref.variable = _context.resolveVariable(vv.getVariable());
+ OVarType rootNodeType = vref.variable.type;
if (vv.getPart() != null) {
vref.part = _context.resolvePart(vref.variable, vv.getPart());
+ rootNodeType = vref.part.type;
}
if (vv.getHeader() != null) {
vref.headerPart = _context.resolveHeaderPart(vref.variable,
vv.getHeader());
if (vref.headerPart == null)
vref.headerPart = new
OMessageVarType.Part(_context.getOProcess(), vv.getHeader(), null);
+ rootNodeType = vref.headerPart.type;
}
if (vv.getLocation() != null && vv.getLocation().getExpression()
!= null)
- vref.location = _context.compileExpr(vv.getLocation());
+ vref.location = _context.compileExpr(vv.getLocation(), rootNodeType,
requestedResultType, new Object[1]);
return vref;
} else if (from.isPartnerLinkVal()) {
PartnerLinkVal plv = from.getAsPartnerLinkVal();
@@ -185,7 +191,7 @@
plref.isMyEndpointReference = (plv.getEndpointReference() ==
PartnerLinkVal.EndpointReference.MYROLE);
return plref;
} else if (from.getAsExpression() != null) {
- return new OAssign.Expression(_context.getOProcess(),
_context.compileExpr(from.getAsExpression()));
+ return new OAssign.Expression(_context.getOProcess(),
_context.compileExpr(from.getAsExpression(), null, requestedResultType, new Object[1]));
}
throw new CompilationException(__cmsgs.errUnkownFromSpec().setSource(from));
@@ -219,7 +225,7 @@
return new OAssign.Literal(_context.getOProcess(), newDoc);
}
- private OAssign.LValue compileTo(To to) {
+ private OAssign.LValue compileTo(To to, Object[] resultType) {
assert to != null;
try {
@@ -232,16 +238,20 @@
VariableVal vv = to.getAsVariableVal();
OAssign.VariableRef vref = new
OAssign.VariableRef(_context.getOProcess());
vref.variable = _context.resolveVariable(vv.getVariable());
+ OVarType rootNodeType = vref.variable.type;
if (to.getAsVariableVal().getPart() != null) {
vref.part = _context.resolvePart(vref.variable, vv.getPart());
+ rootNodeType = vref.part.type;
}
if (to.getAsVariableVal().getHeader() != null) {
vref.headerPart = _context.resolveHeaderPart(vref.variable,
vv.getHeader());
if (vref.headerPart == null)
vref.headerPart = new
OMessageVarType.Part(_context.getOProcess(), to.getAsVariableVal().getHeader(), null);
+ rootNodeType = vref.headerPart.type;
}
+ resultType[0] = rootNodeType;
if (vv.getLocation() != null && vv.getLocation().getExpression()
!= null)
- vref.location = _context.compileExpr(vv.getLocation());
+ vref.location = _context.compileExpr(vv.getLocation(), rootNodeType,
null, resultType);
return vref;
} else if (to.isPartnerLinkVal()) {
OAssign.PartnerLinkRef plref = new
OAssign.PartnerLinkRef(_context.getOProcess());
@@ -249,7 +259,7 @@
return plref;
} else if (to.getAsExpression() != null){
return new OAssign.LValueExpression(_context.getOProcess(), _context
- .compileLValueExpr(to.getAsExpression()));
+ .compileLValueExpr(to.getAsExpression(), null, null,
resultType));
}
throw new CompilationException(__cmsgs.errUnknownToSpec().setSource(to));
Modified:
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/BpelC.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/BpelC.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/BpelC.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -181,7 +181,7 @@
* @throws CompilationException
* if one occurs while compiling.
*/
- public void compile(final Process process, String outputPath) throws
CompilationException, IOException {
+ public void compile(final Process process, String outputPath, long version) throws
CompilationException, IOException {
if (process == null)
throw new NullPointerException("Attempt to compile NULL
process.");
@@ -260,7 +260,7 @@
OProcess oprocess;
try {
- oprocess = compiler.compile(process,wf);
+ oprocess = compiler.compile(process,wf,version);
}
catch (CompilationException cex) {
this.invalidate();
@@ -301,7 +301,7 @@
* output.
* @throws CompilationException if one occurs while compiling the process.
*/
- public void compile(File bpelFile) throws CompilationException, IOException {
+ public void compile(File bpelFile, long version) throws CompilationException,
IOException {
if (__log.isDebugEnabled()) {
__log.debug("compile(URL)");
}
@@ -330,7 +330,7 @@
String bpelPath = bpelFile.getAbsolutePath();
String cbpPath = bpelPath.substring(0, bpelPath.lastIndexOf(".")) +
".cbp";
- compile(process, cbpPath);
+ compile(process, cbpPath, version);
this.invalidate();
}
Modified:
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/BpelCompiler.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/BpelCompiler.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/BpelCompiler.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -52,6 +52,7 @@
import org.apache.ode.bpel.compiler.api.CompileListener;
import org.apache.ode.bpel.compiler.api.CompilerContext;
import org.apache.ode.bpel.compiler.api.ExpressionCompiler;
+import org.apache.ode.bpel.compiler.api.ExpressionValidator;
import org.apache.ode.bpel.compiler.api.SourceLocation;
import org.apache.ode.bpel.compiler.bom.Activity;
import org.apache.ode.bpel.compiler.bom.Bpel11QNames;
@@ -131,7 +132,7 @@
* and XSD documents) into compiled representations suitable for execution by
* the ODE BPEL Service Provider. TODO: Move process validation into this class.
*/
-abstract class BpelCompiler implements CompilerContext {
+public abstract class BpelCompiler implements CompilerContext {
/** Class-severity logger. */
protected static final Log __log = LogFactory.getLog(BpelCompiler.class);
@@ -171,6 +172,8 @@
private final HashMap<String, ExpressionCompiler> _expLanguageCompilers = new
HashMap<String, ExpressionCompiler>();
private final HashMap<String, OExpressionLanguage> _expLanguages = new
HashMap<String, OExpressionLanguage>();
+
+ private ExpressionValidatorFactory _expressionValidatorFactory = new
ExpressionValidatorFactory(System.getProperties());
private WSDLFactory4BPEL _wsdlFactory;
@@ -189,7 +192,7 @@
Definition4BPEL def;
try {
WSDLReader r = _wsdlFactory.newWSDLReader();
- WSDLLocatorImpl locator = new WSDLLocatorImpl(_resourceFinder,
from.resolve(wsdlImport));
+ WSDLLocatorImpl locator = new WSDLLocatorImpl(_resourceFinder,
_resourceFinder.resolve(from, wsdlImport));
def = (Definition4BPEL) r.readWSDL(locator);
} catch (WSDLException e) {
recoveredFromError(sloc, new
CompilationException(__cmsgs.errWsdlParseError(e
@@ -199,7 +202,7 @@
}
try {
- _wsdlRegistry.addDefinition(def, _resourceFinder, from.resolve(wsdlImport));
+ _wsdlRegistry.addDefinition(def, _resourceFinder,
_resourceFinder.resolve(from, wsdlImport));
if (__log.isDebugEnabled())
__log.debug("Added WSDL Definition: " + wsdlImport);
} catch (CompilationException ce) {
@@ -208,13 +211,12 @@
}
public void addXsdImport(URI from, URI location, SourceLocation sloc) {
- URI resFrom = from.resolve(location);
+ URI resFrom = _resourceFinder.resolve(from, location);
if (__log.isDebugEnabled())
__log.debug("Adding XSD import from " + resFrom + " location
" + location);
XMLEntityResolver resolver = new WsdlFinderXMLEntityResolver(_resourceFinder,
- location, new HashMap<URI,String>(), true);
+ location, new HashMap<URI,byte[]>(), true);
try {
- Map<URI, byte[]> schemas = XSUtils.captureSchema(resFrom.toString(),
resolver);
InputStream xsdStream = _resourceFinder.openResource(resFrom);
byte[] data;
try {
@@ -222,7 +224,8 @@
} finally {
xsdStream.close();
}
- schemas.put(resFrom, data);
+
+ Map<URI, byte[]> schemas = XSUtils.captureSchema(resFrom, data,
resolver);
_wsdlRegistry.addSchemas(schemas);
} catch (XsdException e) {
CompilationException ce = new
CompilationException(__cmsgs.errInvalidImport(location.toString()));
@@ -532,30 +535,45 @@
}
public OLValueExpression compileLValueExpr(Expression expression) throws
CompilationException {
- return (OLValueExpression) compileExpr(expression, false, true);
+ return compileLValueExpr(expression, null, null, new Object[1]);
}
+ public OLValueExpression compileLValueExpr(Expression expression, OVarType
rootNodeType, Object requestedResultType, Object[] resultType) throws CompilationException
{
+ return (OLValueExpression) compileExpr(expression, false, true, rootNodeType,
requestedResultType, resultType);
+ }
+
public OExpression compileJoinCondition(Expression expression) throws
CompilationException {
- return compileExpr(expression, true, false);
+ return compileExpr(expression, true, false, null, null, new Object[1]);
}
public OExpression compileExpr(Expression expression) throws CompilationException {
- return compileExpr(expression, false, false);
+ return compileExpr(expression, null, null, new Object[1]);
}
+
+ public OExpression compileExpr(Expression expression, OVarType rootNodeType, Object
requestedResultType, Object[] resultType) throws CompilationException {
+ return compileExpr(expression, false, false, rootNodeType, requestedResultType,
resultType);
+ }
public OExpression compileExpr(String expr, NSContext nc) {
// Does this really work?
BpelObject cur = _structureStack.topSource();
- return compileExpr(new
Expression11(cur.getElement(),cur.getElement().getOwnerDocument().createTextNode(expr)),false,false);
+ return compileExpr(new
Expression11(cur.getElement(),cur.getElement().getOwnerDocument().createTextNode(expr)),
false, false, null, null, new Object[1]);
}
- private OExpression compileExpr(Expression expression, boolean isJoinCondition,
boolean isLValue) {
+ private OExpression compileExpr(Expression expression, boolean isJoinCondition,
boolean isLValue, OVarType rootNodeType, Object requestedResultType, Object[] resultType)
{
String expLang = getExpressionLanguage(expression);
ExpressionCompiler ec = findExpLangCompiler(expLang);
ec.setCompilerContext(this);
+ ExpressionValidator ev = _expressionValidatorFactory.getValidator();
try {
- OExpression oexpr = (isJoinCondition) ? ec.compileJoinCondition(expression) :
ec.compile(expression);
+ OExpression oexpr;
+ if (isJoinCondition) {
+ oexpr = ec.compileJoinCondition(expression);
+ } else {
+ oexpr = ec.compile(expression);
+ resultType[0] = ev.validate(expression, rootNodeType,
requestedResultType);
+ }
oexpr.debugInfo = createDebugInfo(expression, expression.toString());
@@ -615,10 +633,18 @@
_errors.add(bce.getCompilationMessage());
}
+ public static long getVersion(String dirName) {
+ try {
+ return Integer.parseInt(dirName.substring(dirName.lastIndexOf("-")
+ 1));
+ } catch (Throwable t) {
+ return 0;
+ }
+ }
+
/**
* Compile a process.
*/
- public OProcess compile(final Process process, ResourceFinder rf) throws
CompilationException {
+ public OProcess compile(final Process process, ResourceFinder rf, long version)
throws CompilationException {
if (process == null)
throw new NullPointerException("Null process parameter");
@@ -644,7 +670,7 @@
}
_oprocess = new OProcess(bpelVersionUri);
- _oprocess.guid = new GUID().toString();
+ _oprocess.guid = null;
_oprocess.constants = makeConstants();
_oprocess.debugInfo = createDebugInfo(process, "process");
@@ -683,6 +709,8 @@
}
}
+ _expressionValidatorFactory.getValidator().bpelImportsLoaded(_processDef, this);
+
switch (_processDef.getSuppressJoinFailure()) {
case NO:
case NOTSET:
@@ -748,15 +776,26 @@
XslTransformHandler.getInstance().clearXSLSheets(_oprocess.getQName());
+
_expressionValidatorFactory.getValidator().bpelCompilationCompleted(_processDef);
+
if (hasErrors) {
throw new CompilationException(__cmsgs.errCompilationErrors(_errors.size(),
sb.toString()));
}
+
+ {
+ String digest = "version:" + version + ";" +
_oprocess.digest();
+ _oprocess.guid = GUID.makeGUID(digest);
+ if (__log.isDebugEnabled()) {
+ __log.debug("Compiled process digest: " + digest +
"\nguid: " + _oprocess.guid);
+ }
+ }
return _oprocess;
}
private OConstants makeConstants() {
OConstants constants = new OConstants(_oprocess);
constants.qnConflictingReceive = new QName(getBpwsNamespace(),
"conflictingReceive");
+ constants.qnConflictingRequest = new QName(getBpwsNamespace(),
"conflictingRequest");
constants.qnCorrelationViolation = new QName(getBpwsNamespace(),
"correlationViolation");
constants.qnForcedTermination = new QName(getBpwsNamespace(),
"forcedTermination");
constants.qnJoinFailure = new QName(getBpwsNamespace(),
"joinFailure");
@@ -781,7 +820,7 @@
}
private String getOdeNamespace() {
- return Namespaces.ODE_EXTENSION_NS;
+ return Namespaces.ODE_EXTENSION_NS;
}
// TODO unused?
@@ -975,6 +1014,7 @@
}
OMessageVarType messageType = resolveMessageType(src.getMessageType());
+ OVarType rootNodeType = messageType;
alias.varType = messageType;
// bpel 2.0 excludes declaration of part;
// bpel 1.1 requires it
@@ -983,9 +1023,10 @@
if (alias.part == null)
throw new
CompilationException(__cmsgs.errUnknownPartInAlias(src.getPart(),
messageType.messageType.toString()));
+ rootNodeType = alias.part.type;
}
if (src.getQuery() != null)
- alias.location = compileExpr(src.getQuery());
+ alias.location = compileExpr(src.getQuery(), rootNodeType, null, new
Object[1]);
property.aliases.add(alias);
alias.debugInfo = createDebugInfo(_processDef, src.getMessageType() + "
--> " + src.getPropertyName());
return alias;
@@ -1298,12 +1339,12 @@
Set<String> csetNames = new HashSet<String>(); // prevents
duplicate cset in on one set of correlations
for (Correlation correlation : onEvent.getCorrelations()) {
- if( csetNames.contains(correlation.getCorrelationSet() ) ) {
+ if( csetNames.contains(correlation.getCorrelationSet() ) ) {
throw new
CompilationException(__cmsgs.errDuplicateUseCorrelationSet(correlation
.getCorrelationSet()));
- }
+ }
- OScope.CorrelationSet cset =
resolveCorrelationSet(correlation.getCorrelationSet());
+ OScope.CorrelationSet cset =
resolveCorrelationSet(correlation.getCorrelationSet());
switch (correlation.getInitiate()) {
case UNSET:
@@ -1315,7 +1356,7 @@
oevent.initCorrelations.add(cset);
break;
case JOIN:
- cset.hasJoinUseCases = true;
+ cset.hasJoinUseCases = true;
oevent.joinCorrelations.add(cset);
oevent.partnerLink.addCorrelationSetForOperation(oevent.operation, cset, true);
}
@@ -1678,26 +1719,20 @@
return rval;
}
- public Map<URI, Source> getSchemaSources() {
- Map<URI, Document> schemaBytes = _wsdlRegistry.getSchemaDocuments();
- Map<URI, Source> schemaSources = new HashMap<URI, Source>();
- for (URI uri : schemaBytes.keySet()) {
- Document document = schemaBytes.get(uri);
- schemaSources.put(uri, new DOMSource(document));
- }
- return schemaSources;
+ public Map<URI, Source> getSchemaSources() {
+ return _wsdlRegistry.getSchemaSources();
}
- /**
- * Retrieves the base URI that the BPEL Process execution contextis running relative
to.
- *
- * @return URI - the URI representing the absolute physical file path location that this
process is defined within.
- * @throws IOException
- * @throws MalformedURLException
- */
- public URI getBaseResourceURI() {
- return _resourceFinder.getBaseResourceURI();
- }
+ /**
+ * Retrieves the base URI that the BPEL Process execution contextis running relative
to.
+ *
+ * @return URI - the URI representing the absolute physical file path location that
this process is defined within.
+ * @throws IOException
+ * @throws MalformedURLException
+ */
+ public URI getBaseResourceURI() {
+ return _resourceFinder.getBaseResourceURI();
+ }
/**
@@ -1714,10 +1749,10 @@
oextvar.debugInfo = createDebugInfo(src, null);
if (src.getExternalId() == null)
- throw new
CompilationException(__cmsgs.errMustSpecifyExternalVariableId(src.getName()));
-
+ throw new
CompilationException(__cmsgs.errMustSpecifyExternalVariableId(src.getName()));
+
if (src.getRelated() == null)
- throw new
CompilationException(__cmsgs.errMustSpecifyRelatedVariable(src.getName()));
+ throw new
CompilationException(__cmsgs.errMustSpecifyRelatedVariable(src.getName()));
oextvar.related = resolveVariable(src.getRelated());
return oextvar;
Modified:
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/DefaultResourceFinder.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/DefaultResourceFinder.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/DefaultResourceFinder.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -59,7 +59,7 @@
checkDir("absoluteDir", absoluteDir);
_relativeDir = relativeDir;
_absoluteDir = absoluteDir;
- }
+ }
private void checkDir(String arg, File dir) {
if (dir == null) {
@@ -71,6 +71,30 @@
}
public InputStream openResource(URI uri) throws MalformedURLException, IOException {
+ uri = relativize(uri);
+
+ InputStream r = openFileResource(uri);
+ if (r != null) {
+ return r;
+ }
+
+ if (__log.isDebugEnabled()) {
+ __log.debug("trying classpath resource for " + uri);
+ }
+
+ r =
Thread.currentThread().getContextClassLoader().getResourceAsStream(uri.getPath());
+ if (r != null) {
+ return r;
+ } else {
+ if (__log.isDebugEnabled()) {
+ __log.debug("classpath resource not found " + uri);
+ }
+ return null;
+ }
+
+ }
+
+ private InputStream openFileResource(URI uri) throws MalformedURLException,
IOException {
URI absolute = _absoluteDir.toURI();
if (__log.isDebugEnabled()) {
__log.debug("openResource: uri="+uri+"
relativeDir="+_relativeDir+" absoluteDir="+_absoluteDir);
@@ -80,7 +104,7 @@
try {
return uri.toURL().openStream();
} catch (Exception except) {
- __log.fatal("openResource: unable to open file URL " + uri +
"; " + except.toString());
+ __log.debug("openResource: unable to open file URL " + uri +
"; " + except.toString());
return null;
}
}
@@ -88,22 +112,42 @@
// Note that if we get an absolute URI, the relativize operation will simply
// return the absolute URI.
URI relative = _relativeDir.toURI().relativize(uri);
- if (relative.isAbsolute() &&
!relative.getScheme().equals("urn")) {
+ if (relative.isAbsolute() &&
!(relative.getScheme().equals("urn"))) {
__log.fatal("openResource: invalid scheme (should be urn:) " +
uri);
return null;
}
File f = new File(absolute.getPath(), relative.getPath());
- if (!f.exists()) {
- __log.debug("fileNotFound: " + f);
+ if (f.exists()) {
+ return new FileInputStream(f);
+ } else {
+ if (__log.isDebugEnabled()) {
+ __log.debug("fileNotFound: " + f);
+ }
return null;
}
-
- return new FileInputStream(f);
}
public URI getBaseResourceURI() {
return _absoluteDir.toURI();
}
+ private URI relativize(URI u) {
+ if (u.isAbsolute()) {
+ return _absoluteDir.toURI().relativize(u);
+ } else return u;
+ }
+
+ public URI resolve(URI parent, URI child) {
+ parent = relativize(parent);
+ child = relativize(child);
+ URI result = parent.resolve(child);
+ URI result2 = _absoluteDir.toURI().resolve(result);
+ if (__log.isDebugEnabled()) {
+ __log.debug("resolving URI: parent " + parent + " child "
+ child + " result " + result + " resultAbsolute:" + result2);
+ }
+
+ return result2;
+ }
+
}
Added:
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/ExpressionValidatorFactory.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/ExpressionValidatorFactory.java
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/ExpressionValidatorFactory.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,58 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.ode.bpel.compiler;
+
+import java.util.Properties;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+import org.apache.ode.bpel.compiler.api.CompilationException;
+import org.apache.ode.bpel.compiler.api.CompilerContext;
+import org.apache.ode.bpel.compiler.api.ExpressionValidator;
+import org.apache.ode.bpel.compiler.bom.Process;
+import org.apache.ode.bpel.compiler.bom.Expression;
+import org.apache.ode.bpel.o.OVarType;
+
+public class ExpressionValidatorFactory {
+ private static final Log __log =
LogFactory.getLog(ExpressionValidatorFactory.class);
+ private ExpressionValidator _validator = new EmptyValidator();
+
+ public ExpressionValidatorFactory(Properties config) {
+ String propertyName = "org.apache.ode.validator";
+ String validatorClass = (String) config.getProperty(propertyName, "");
+ __log.debug("Trying property " + propertyName + " got value: " +
validatorClass);
+ if (!validatorClass.equals("")) {
+ try {
+ _validator = (ExpressionValidator) getClass().forName(validatorClass).newInstance();
+ } catch (Exception e) {
+ __log.warn("Cannot instantiate expression validator of class " +
validatorClass);
+ }
+ }
+ }
+
+ public ExpressionValidator getValidator() {
+ return _validator;
+ }
+
+ private static class EmptyValidator implements ExpressionValidator {
+ public void bpelImportsLoaded(Process source, CompilerContext compilerContext)
throws CompilationException {}
+ public void bpelCompilationCompleted(Process source) throws CompilationException
{}
+ public Object validate(Expression source, OVarType rootNodeType, Object
requestedResultType) throws CompilationException { return null; }
+ }
+}
Modified:
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/ResourceFinder.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/ResourceFinder.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/ResourceFinder.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -40,5 +40,7 @@
InputStream openResource(URI uri) throws MalformedURLException, IOException;
URI getBaseResourceURI();
+
+ URI resolve(URI parent, URI child);
}
Modified:
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/WSDLRegistry.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/WSDLRegistry.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/WSDLRegistry.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -41,7 +41,10 @@
import javax.wsdl.extensions.ExtensibilityElement;
import javax.xml.namespace.QName;
import javax.xml.transform.Source;
+import javax.xml.transform.dom.DOMSource;
+import javax.xml.transform.stream.StreamSource;
+import java.io.ByteArrayInputStream;
import java.io.StringReader;
import java.io.IOException;
import java.net.URI;
@@ -60,7 +63,7 @@
private final HashMap<String, ArrayList<Definition4BPEL>> _definitions =
new HashMap<String, ArrayList<Definition4BPEL>>();
private final Map<URI, byte[]> _schemas = new HashMap<URI,byte[]>();
- private final Map<URI, String> _internalSchemas = new HashMap<URI,
String>();
+ private final Map<URI, byte[]> _internalSchemas = new HashMap<URI,
byte[]>();
private final Map<URI, Document> _documentSchemas = new HashMap<URI,
Document>();
private SchemaModel _model;
@@ -131,6 +134,20 @@
__log.info("WSDL at " + defuri + " is a duplicate import,
your documents " +
"should all be in different namespaces (its's not nice
but will still work).");
}
+ boolean alreadyProcessed = false;
+ for (Definition4BPEL aDef : _definitions.get(def.getTargetNamespace())) {
+ if (aDef.getDocumentBaseURI().equals(def.getDocumentBaseURI())) {
+ alreadyProcessed = true;
+ break;
+ }
+ }
+ if (alreadyProcessed) {
+ if (__log.isInfoEnabled()) {
+ __log.info("WSDL at " + defuri + " is already imported,
this denotes a circular reference.");
+ // no need to keep going: either return or throw an error
+ }
+ return;
+ }
}
ArrayList<Definition4BPEL> defs = null;
@@ -202,14 +219,14 @@
ExtensibilityElement ee = iter.next();
if (ee instanceof XMLSchemaType) {
- String schema = ((XMLSchemaType)ee).getXMLSchema();
+ byte[] schema = ((XMLSchemaType)ee).getXMLSchema();
WsdlFinderXMLEntityResolver resolver = new
WsdlFinderXMLEntityResolver(rf, defuri, _internalSchemas, false);
try {
Map<URI, byte[]> capture = XSUtils.captureSchema(defuri,
schema, resolver);
_schemas.putAll(capture);
try {
- Document doc = DOMUtils.parse(new InputSource(new
StringReader(schema)));
+ Document doc = DOMUtils.parse(new InputSource(new
ByteArrayInputStream(schema)));
String schemaTargetNS =
doc.getDocumentElement().getAttribute("targetNamespace");
if (schemaTargetNS != null && schemaTargetNS.length()
> 0) {
_internalSchemas.put(new URI(schemaTargetNS), schema);
@@ -296,8 +313,27 @@
return null;
}
+ /**
+ * @return All parsed schemas. This doesn't include schemas from bpel imports.
+ */
Map<URI, Document> getSchemaDocuments() {
return _documentSchemas;
}
+ /**
+ * @return All captured schema sources including those from bpel imports.
+ */
+ Map<URI, Source> getSchemaSources() {
+ Map<URI, Source> schemaSources = new HashMap<URI, Source>();
+ for (URI uri : _documentSchemas.keySet()) {
+ Document document = _documentSchemas.get(uri);
+ schemaSources.put(uri, new DOMSource(document));
+ }
+
+ for (URI uri : _schemas.keySet()) {
+ schemaSources.put(uri, new StreamSource(new
ByteArrayInputStream(_schemas.get(uri))));
+ }
+
+ return schemaSources;
+ }
}
Modified:
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/WsdlFinderXMLEntityResolver.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/WsdlFinderXMLEntityResolver.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/WsdlFinderXMLEntityResolver.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -55,7 +55,7 @@
private boolean _failIfNotFound = true;
private ResourceFinder _wsdlFinder;
- private Map<URI, String> _internalSchemas = new HashMap<URI, String>();
+ private Map<URI, byte[]> _internalSchemas = new HashMap<URI, byte[]>();
private URI _baseURI;
/**
@@ -65,7 +65,7 @@
* typically this is the system URI of the WSDL containing an
* embedded schema
*/
- public WsdlFinderXMLEntityResolver(ResourceFinder finder, URI baseURI, Map<URI,
String> internalSchemas,
+ public WsdlFinderXMLEntityResolver(ResourceFinder finder, URI baseURI, Map<URI,
byte[]> internalSchemas,
boolean failIfNotFound) {
_wsdlFinder = finder;
_baseURI = baseURI;
@@ -87,18 +87,15 @@
if (__log.isDebugEnabled()) __log.debug("resolveEntity: no schema
location for "+resourceIdentifier.getNamespace());
try {
if (_internalSchemas.get(new URI(resourceIdentifier.getNamespace())) !=
null) {
- src.setByteStream(new ByteArrayInputStream(_internalSchemas.get(new
URI(resourceIdentifier.getNamespace())).getBytes()));
+ src.setByteStream(new ByteArrayInputStream(_internalSchemas.get(new
URI(resourceIdentifier.getNamespace()))));
return src;
}
} catch (URISyntaxException e) {
__log.debug("resolveEntity: no schema location an no known namespace
for: " + resourceIdentifier.getNamespace());
}
return null;
- } else if (resourceIdentifier.getExpandedSystemId() != null) {
- // schema imported by other schema
- location = _baseURI.resolve(resourceIdentifier.getExpandedSystemId());
} else {
- location = _baseURI.resolve(resourceIdentifier.getLiteralSystemId());
+ location =
_wsdlFinder.resolve(URI.create(resourceIdentifier.getBaseSystemId()),
URI.create(resourceIdentifier.getLiteralSystemId()));
}
if (__log.isDebugEnabled())
@@ -106,7 +103,7 @@
+ " at " + location);
if (_internalSchemas.get(location) != null) {
- src.setByteStream(new
ByteArrayInputStream(_internalSchemas.get(location).getBytes()));
+ src.setByteStream(new ByteArrayInputStream(_internalSchemas.get(location)));
return src;
}
Modified:
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/api/CompilerContext.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/api/CompilerContext.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/api/CompilerContext.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -37,6 +37,7 @@
import org.apache.ode.bpel.o.OPartnerLink;
import org.apache.ode.bpel.o.OProcess;
import org.apache.ode.bpel.o.OScope;
+import org.apache.ode.bpel.o.OVarType;
import org.apache.ode.bpel.o.OXsdTypeVarType;
import org.apache.ode.bpel.o.OXslSheet;
import org.apache.ode.bpel.o.OScope.Variable;
@@ -56,9 +57,15 @@
throws CompilationException;
OExpression compileExpr(Expression expr)
+ throws CompilationException;
+
+ OExpression compileExpr(Expression expr, OVarType rootNodeType, Object
requestedResultType, Object[] resultType)
throws CompilationException;
OLValueExpression compileLValueExpr(Expression expr)
+ throws CompilationException;
+
+ OLValueExpression compileLValueExpr(Expression expr, OVarType rootNodeType, Object
requestedResultType, Object[] resultType)
throws CompilationException;
/**
Modified:
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/api/ExpressionCompiler.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/api/ExpressionCompiler.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/api/ExpressionCompiler.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -20,6 +20,7 @@
import org.apache.ode.bpel.o.OExpression;
import org.apache.ode.bpel.o.OLValueExpression;
+import org.apache.ode.bpel.o.OVarType;
import java.util.Map;
Added:
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/api/ExpressionValidator.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/api/ExpressionValidator.java
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/api/ExpressionValidator.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,50 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.ode.bpel.compiler.api;
+
+import org.apache.ode.bpel.o.OVarType;
+import org.apache.ode.bpel.compiler.bom.Process;
+import org.apache.ode.bpel.compiler.bom.Expression;
+
+public interface ExpressionValidator {
+ /**
+ * Notifies process compilation began
+ *
+ * @param compilerContext
+ */
+ void bpelImportsLoaded(Process source, CompilerContext compilerContext) throws
CompilationException;
+
+ /**
+ * Notifies process compilation completed.
+ * Mainly for cleaning up resources.
+ *
+ * @param compilerContext
+ */
+ void bpelCompilationCompleted(Process source) throws CompilationException;
+
+ /**
+ * Validate given expression.
+ * @param source It's a Query or Expression
+ * @param requestedResultType It's OVarType or underlying Expression
Validator's type.
+ * It may be null if there are no constrains for result type
+ * @return Evaluated expression's type
+ */
+ Object validate(Expression source, OVarType rootNodeType, Object requestedResultType)
throws CompilationException;
+
+}
Modified:
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/wsdl/XMLSchemaType.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/wsdl/XMLSchemaType.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/wsdl/XMLSchemaType.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -38,9 +38,9 @@
/** For compatibility with some older classes. */
public static final QName qname = QNAME;
- private String _xmlSchema;
+ private byte[] _xmlSchema;
- public XMLSchemaType(String xmlSchema) {
+ public XMLSchemaType(byte[] xmlSchema) {
super();
_xmlSchema = xmlSchema;
}
@@ -71,12 +71,7 @@
return Boolean.FALSE;
}
- /**
- * Returns the schema content as string.
- *
- * @return
- */
- public String getXMLSchema() {
+ public byte[] getXMLSchema() {
return _xmlSchema;
}
}
Modified:
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/wsdl/XMLSchemaTypeSerializer.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/wsdl/XMLSchemaTypeSerializer.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/compiler/wsdl/XMLSchemaTypeSerializer.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -76,6 +76,6 @@
ExtensionRegistry extensionRegistry)
throws WSDLException {
DOMUtils.pancakeNamespaces(element);
- return new XMLSchemaType(DOMUtils.domToString(element));
+ return new XMLSchemaType(DOMUtils.domToString(element).getBytes());
}
}
Modified:
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/elang/xpath10/compiler/JaxenBpelHandler.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/elang/xpath10/compiler/JaxenBpelHandler.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/elang/xpath10/compiler/JaxenBpelHandler.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -118,22 +118,18 @@
throw new CompilationException(
__msgs.errUndeclaredFunctionPrefix(prefix,c.getFunctionName()));
} else if (isBpelNamespace(ns)) {
- try {
if (Constants.EXT_FUNCTION_GETVARIABLEDATA.equals(c.getFunctionName())) {
- compileGetVariableData(c);
+ compileGetVariableData(c);
} else if (Constants.EXT_FUNCTION_GETVARIABLEPROPRTY.equals(c
.getFunctionName())) {
- compileGetVariableProperty(c);
+ compileGetVariableProperty(c);
} else if (Constants.EXT_FUNCTION_GETLINKSTATUS.equals(c.getFunctionName())) {
- compileGetLinkStatus(c);
+ compileGetLinkStatus(c);
} else if (Constants.EXT_FUNCTION_DOXSLTRANSFORM.equals(c.getFunctionName())) {
- compileDoXslTransform(c);
+ compileDoXslTransform(c);
} else {
- throw new
CompilationException(__msgs.errUnknownBpelFunction(c.getFunctionName()));
+ throw new
CompilationException(__msgs.errUnknownBpelFunction(c.getFunctionName()));
}
- } catch (CompilationException ce) {
- throw new RuntimeException(ce);
- }
}
}
Modified:
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/elang/xpath10/compiler/XPathMessages.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/elang/xpath10/compiler/XPathMessages.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/elang/xpath10/compiler/XPathMessages.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -87,6 +87,12 @@
"The string \"{0}\" is not a valid XPath 2.0 expression:
{1}", xPathString, message);
}
+ /** The string "{0}" is not a valid XQuery 1.0 expression. */
+ public CompilationMessage errXQuery10Syntax(String xQueryString, String message) {
+ return super.formatCompilationMessage(
+ "The string \"{0}\" is not a valid XQuery 1.0 expression:
{1}", xQueryString, message);
+ }
+
/** The XPath node with value "{0}" was not a text node. */
public CompilationMessage errUnexpectedNodeTypeForXPath(String string) {
return super.formatCompilationMessage(
Modified:
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/elang/xpath20/compiler/JaxpVariableResolver.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/elang/xpath20/compiler/JaxpVariableResolver.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/elang/xpath20/compiler/JaxpVariableResolver.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -19,6 +19,8 @@
package org.apache.ode.bpel.elang.xpath20.compiler;
+import java.util.Date;
+
import org.apache.ode.bpel.compiler.api.CompilationException;
import org.apache.ode.bpel.compiler.api.CompilerContext;
import org.apache.ode.bpel.elang.xpath10.compiler.XPathMessages;
@@ -62,6 +64,8 @@
|| Namespaces.ODE_EXTENSION_NS.equals(variableName.getNamespaceURI())) {
if ("pid".equals(variableName.getLocalPart()) ||
"processQName".equals(variableName.getLocalPart()))
return "";
+ if ("currentEventDateTime".equals(variableName.getLocalPart()))
+ return new Date(1L);
}
try {
Modified:
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/elang/xpath20/compiler/XPath20ExpressionCompilerImpl.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/elang/xpath20/compiler/XPath20ExpressionCompilerImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/elang/xpath20/compiler/XPath20ExpressionCompilerImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -140,10 +140,7 @@
out.xpath = xpathStr;
try {
__log.debug("Compiling expression " + xpathStr);
- System.setProperty(
- "javax.xml.xpath.XPathFactory:" +
NamespaceConstant.OBJECT_MODEL_SAXON,
- "net.sf.saxon.xpath.XPathFactoryImpl");
- XPathFactory xpf =
XPathFactory.newInstance(NamespaceConstant.OBJECT_MODEL_SAXON);
+ XPathFactory xpf = new XPathFactoryImpl();
JaxpFunctionResolver funcResolver = new JaxpFunctionResolver(
_compilerContext, out, source.getNamespaceContext(), _bpelNS);
JaxpVariableResolver varResolver = new JaxpVariableResolver(_compilerContext,
out);
@@ -166,9 +163,14 @@
// swallow errors caused by uninitialized variable
}
}
- } catch (XPathFactoryConfigurationException xpfce) {
- __log.debug(xpfce);
- __log.info("Couldn't validate properly expression " +
xpathStr);
+ for (String functionExpr : extractFunctionExprs(xpathStr)) {
+ expr = xpe.compile(functionExpr);
+ try {
+ expr.evaluate(node);
+ } catch (XPathExpressionException xpee) {
+ // swallow errors caused by uninitialized variable
+ }
+ }
} catch (XPathExpressionException e) {
__log.debug(e);
__log.info("Couldn't validate properly expression " +
xpathStr);
@@ -194,11 +196,11 @@
int firstVariable = xpathStr.indexOf("$"),
lastVariable = xpathStr.lastIndexOf("$"),
firstFunction = xpathStr.indexOf("(");
+ StringBuffer variableExpr = new StringBuffer();
if ((firstVariable > 0 && // the xpath references a variable
firstFunction > 0) || // the xpath contains a function
(firstVariable < lastVariable)) { // the xpath references multiple variables
// most likely, the variable reference has not been resolved, so make that happen
- StringBuffer variableExpr = new StringBuffer();
boolean quoted = false, doubleQuoted = false, variable = false;
Name11Checker nameChecker = Name11Checker.getInstance();
for (int index = 0; index < xpathStr.length(); index++) {
@@ -228,14 +230,85 @@
variable = false;
variableExpr.setLength(variableExpr.length() - 1);
variableExprs.add(variableExpr.toString());
+ variableExpr.setLength(0);
}
}
}
}
+ if (variableExpr.length() > 0) {
+ variableExprs.add(variableExpr.toString());
+ }
}
return variableExprs;
}
+ /**
+ * Returns the list of function references in the given XPath expression
+ * that may not have been resolved properly, which is the case especially
+ * if the expression contains a preceding function, which short circuited the
evaluation.
+ *
+ * @param xpathStr
+ * @return list of function expressions that may not have been resolved properly
+ */
+ private List<String> extractFunctionExprs(String xpathStr) {
+ ArrayList<String> functionExprs = new ArrayList<String>();
+ int firstFunction = xpathStr.indexOf("("),
+ lastFunction = xpathStr.lastIndexOf("(");
+ StringBuffer functionExpr = new StringBuffer();
+ if ((firstFunction > 0 && // the xpath contains a function
+ firstFunction < lastFunction)) { // the xpath references multiple variables
+ // most likely, the variable reference has not been resolved, so make that happen
+ boolean quoted = false, doubleQuoted = false, function = false, arguments = false;
+ Name11Checker nameChecker = Name11Checker.getInstance();
+ for (int index = firstFunction; index < xpathStr.length(); index++) {
+ if (!function) {
+ int colonIndex = xpathStr.indexOf(':', index);
+ if (colonIndex == -1) {
+ break;
+ }
+ while (colonIndex >= 0 &&
nameChecker.isNCNameChar(xpathStr.charAt(--colonIndex)));
+ if (xpathStr.charAt(colonIndex) == '$') {
+ index = xpathStr.indexOf(':', index) + 1;
+ continue;
+ }
+ function = true;
+ arguments = false;
+ functionExpr.setLength(0);
+ index = colonIndex;
+ continue;
+ }
+ char ch = xpathStr.charAt(index);
+ if (function) {
+ functionExpr.append(ch);
+ // in the name is qualified, don't check if its a qname when we're at the
":" character
+ if (ch == ':') {
+ continue;
+ } else if (ch == '(') {
+ if (nameChecker.isQName(functionExpr.substring(0, functionExpr.length() - 1))) {
+ arguments = true;
+ } else {
+ function = false;
+ continue;
+ }
+ } else if (ch == ')') {
+ if (arguments) {
+ function = false;
+ functionExprs.add(functionExpr.toString());
+ functionExpr.setLength(0);
+ }
+ } else {
+ if (!arguments) {
+ if (!nameChecker.isQName(functionExpr.substring(0, functionExpr.length()))) {
+ function = false;
+ }
+ }
+ }
+ }
+ }
+ }
+ return functionExprs;
+ }
+
public Map<String, String> getProperties() {
return _properties;
}
Modified:
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/elang/xquery10/compiler/XQuery10ExpressionCompilerImpl.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/elang/xquery10/compiler/XQuery10ExpressionCompilerImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-compiler/src/main/java/org/apache/ode/bpel/elang/xquery10/compiler/XQuery10ExpressionCompilerImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -21,7 +21,9 @@
import java.net.URI;
import java.util.ArrayList;
+import java.util.Collection;
import java.util.HashMap;
+import java.util.LinkedHashSet;
import java.util.List;
import java.util.Map;
import java.util.Set;
@@ -160,7 +162,7 @@
}
try {
- XQDataSource xqds = new SaxonXQDataSource();
+ XQDataSource xqds = new SaxonXQDataSource(new Configuration());
XQConnection xqconn = xqds.getConnection();
__log.debug("Compiling expression " + xqueryStr);
@@ -194,12 +196,12 @@
declarations.declareVariable(
getQName(nsContext, Namespaces.ODE_EXTENSION_NS, "pid"),
getQName(nsContext, Namespaces.XML_SCHEMA, "integer"));
- Map<URI, Source> schemaDocuments =
_compilerContext.getSchemaSources();
- for (URI schemaUri : schemaDocuments.keySet()) {
- Source schemaSource = schemaDocuments.get(schemaUri);
- // Don't add schema sources, since our Saxon library is not
schema-aware.
- // configuration.addSchemaSource(schemaSource);
- }
+// Map<URI, Source> schemaDocuments =
_compilerContext.getSchemaSources();
+// for (URI schemaUri : schemaDocuments.keySet()) {
+// Source schemaSource = schemaDocuments.get(schemaUri);
+// // Don't add schema sources, since our Saxon library is not
schema-aware.
+// // configuration.addSchemaSource(schemaSource);
+// }
configuration.setSchemaValidationMode(Validation.SKIP);
List<OScope.Variable> variables =
_compilerContext.getAccessibleVariables();
Map<QName, QName> variableTypes = new HashMap<QName, QName>();
@@ -269,6 +271,7 @@
} catch (XQException xqe) {
__log.debug(xqe);
__log.info("Couldn't validate properly expression " +
xqueryStr);
+ throw new CompilationException(__msgs.errXQuery10Syntax(xqueryStr,
"Couldn't validate XQuery expression"));
} catch (WrappedResolverException wre) {
if (wre._compilationMsg != null)
throw new CompilationException(wre._compilationMsg, wre);
@@ -298,14 +301,13 @@
return null;
}
- private List<String> getVariableNames(String xquery) {
- List<String> variableNames = new ArrayList<String>();
+ protected static Collection<String> getVariableNames(String xquery) {
+ Collection<String> variableNames = new LinkedHashSet<String>();
for (int index = xquery.indexOf("$"); index != -1; index =
xquery.indexOf("$")) {
- StringBuffer variableName = new StringBuffer();
- for (char ch = xquery.charAt(++index);
- XMLChar.isNCName(ch);
- ch = xquery.charAt(++index)) {
- variableName.append(ch);
+ StringBuilder variableName = new StringBuilder();
+ index++;
+ while(index < xquery.length() && XMLChar.isNCName(xquery.charAt(index)))
{
+ variableName.append(xquery.charAt(index++));
}
variableNames.add(variableName.toString());
xquery = xquery.substring(index);
Modified:
branches/ODE/ODE-1.x/bpel-compiler/src/test/java/org/apache/ode/bpel/compiler/StaticCheckSuite.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-compiler/src/test/java/org/apache/ode/bpel/compiler/StaticCheckSuite.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-compiler/src/test/java/org/apache/ode/bpel/compiler/StaticCheckSuite.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -19,29 +19,34 @@
package org.apache.ode.bpel.compiler;
import junit.framework.Test;
+import junit.framework.TestCase;
import junit.framework.TestSuite;
/**
* JUnit {@link TestSuite} for running a series of {@link StaticCheckTCase}s.
*/
-public class StaticCheckSuite extends TestSuite {
+public class StaticCheckSuite extends TestCase {
- public static Test suite() throws Exception {
- TestSuite suite = new StaticCheckSuite();
- suite.addTest(new StaticCheckTCase("NoRootActivity"));
- suite.addTest(new StaticCheckTCase("PortTypeMismatch"));
- suite.addTest(new StaticCheckTCase("UndeclaredPropertyAlias"));
- suite.addTest(new StaticCheckTCase("UnknownBpelFunction"));
- suite.addTest(new StaticCheckTCase("UndeclaredVariable"));
- suite.addTest(new StaticCheckTCase("DuplicateLinkTarget"));
- suite.addTest(new StaticCheckTCase("DuplicateLinkSource"));
- suite.addTest(new StaticCheckTCase("DuplicateLinkDecl"));
- suite.addTest(new StaticCheckTCase("LinkMissingSourceActivity"));
- suite.addTest(new StaticCheckTCase("LinkMissingTargetActivity"));
- suite.addTest(new StaticCheckTCase("DuplicateVariableDecl"));
- // We simply can't test the next one without using the BOM; both the parser
- // and schema validation would rule it out.
- //suite.addTest(new StaticCheckTest("CompensateNAtoContext"));
- return suite;
- }
+ /**
+ * @return a test suite of tests that show compilation failures.
+ * @throws Exception
+ */
+ public static Test suite() throws Exception {
+ TestSuite suite = new TestSuite();
+ suite.addTest(new StaticCheckTCase("NoRootActivity"));
+ suite.addTest(new StaticCheckTCase("PortTypeMismatch"));
+ suite.addTest(new StaticCheckTCase("UndeclaredPropertyAlias"));
+ suite.addTest(new StaticCheckTCase("UnknownBpelFunction"));
+ suite.addTest(new StaticCheckTCase("UndeclaredVariable"));
+ suite.addTest(new StaticCheckTCase("DuplicateLinkTarget"));
+ suite.addTest(new StaticCheckTCase("DuplicateLinkSource"));
+ suite.addTest(new StaticCheckTCase("DuplicateLinkDecl"));
+ suite.addTest(new StaticCheckTCase("LinkMissingSourceActivity"));
+ suite.addTest(new StaticCheckTCase("LinkMissingTargetActivity"));
+ suite.addTest(new StaticCheckTCase("DuplicateVariableDecl"));
+ // We simply can't test the next one without using the BOM; both the parser
+ // and schema validation would rule it out.
+ //suite.addTest(new StaticCheckTest("CompensateNAtoContext"));
+ return suite;
+ }
}
Modified:
branches/ODE/ODE-1.x/bpel-compiler/src/test/java/org/apache/ode/bpel/compiler/StaticCheckTCase.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-compiler/src/test/java/org/apache/ode/bpel/compiler/StaticCheckTCase.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-compiler/src/test/java/org/apache/ode/bpel/compiler/StaticCheckTCase.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -28,11 +28,14 @@
import java.util.List;
import java.util.Set;
+import javax.xml.transform.TransformerFactory;
+
import junit.framework.TestCase;
import org.apache.ode.bpel.compiler.api.CompilationException;
import org.apache.ode.bpel.compiler.api.CompilationMessage;
import org.apache.ode.bpel.compiler.api.CompileListener;
+import org.apache.ode.utils.xsl.XslTransformHandler;
/**
@@ -63,6 +66,8 @@
protected void setUp() throws Exception {
super.setUp();
+ TransformerFactory trsf = new net.sf.saxon.TransformerFactoryImpl();
+ XslTransformHandler.getInstance().setTransformerFactory(trsf);
_compiler = BpelC.newBpelCompiler();
_compiler.setCompileListener(this);
_errors.clear();
@@ -86,7 +91,7 @@
public void runTest() throws Exception {
try {
- _compiler.compile(new File(_bpelURL.toURI()));
+ _compiler.compile(new File(_bpelURL.toURI()), 1L);
fail("Expected compilation exception.");
} catch (CompilationException ce) {
_errors.add(ce.getCompilationMessage());
Modified:
branches/ODE/ODE-1.x/bpel-compiler/src/test/java/org/apache/ode/bpel/compiler/XPathTest.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-compiler/src/test/java/org/apache/ode/bpel/compiler/XPathTest.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-compiler/src/test/java/org/apache/ode/bpel/compiler/XPathTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -53,6 +53,7 @@
import org.apache.ode.bpel.o.OPartnerLink;
import org.apache.ode.bpel.o.OProcess;
import org.apache.ode.bpel.o.OScope;
+import org.apache.ode.bpel.o.OVarType;
import org.apache.ode.bpel.o.OXsdTypeVarType;
import org.apache.ode.bpel.o.OXslSheet;
import org.apache.ode.bpel.o.OMessageVarType.Part;
@@ -282,4 +283,18 @@
// TODO Auto-generated method stub
return null;
}
+
+ public OExpression compileExpr(Expression expr, OVarType rootNodeType,
+ Object requestedResultType, Object[] resultType)
+ throws CompilationException {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ public OLValueExpression compileLValueExpr(Expression expr,
+ OVarType rootNodeType, Object requestedResultType,
+ Object[] resultType) throws CompilationException {
+ // TODO Auto-generated method stub
+ return null;
+ }
}
Modified:
branches/ODE/ODE-1.x/bpel-compiler/src/test/java/org/apache/ode/bpel/compiler_2_0/GoodCompileTCase.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-compiler/src/test/java/org/apache/ode/bpel/compiler_2_0/GoodCompileTCase.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-compiler/src/test/java/org/apache/ode/bpel/compiler_2_0/GoodCompileTCase.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -61,7 +61,7 @@
public void runTest() throws Exception {
try {
File bpelFile = new File(getClass().getResource(_bpel).toURI().getPath());
- _compiler.compile(bpelFile);
+ _compiler.compile(bpelFile, 0);
} catch (Exception ex) {
ex.printStackTrace();
fail("Compilation did not succeed.");
Added:
branches/ODE/ODE-1.x/bpel-compiler/src/test/java/org/apache/ode/bpel/elang/xquery10/compiler/XQuery10ExpressionCompilerImplTest.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-compiler/src/test/java/org/apache/ode/bpel/elang/xquery10/compiler/XQuery10ExpressionCompilerImplTest.java
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-compiler/src/test/java/org/apache/ode/bpel/elang/xquery10/compiler/XQuery10ExpressionCompilerImplTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,39 @@
+package org.apache.ode.bpel.elang.xquery10.compiler;
+
+import java.util.Arrays;
+import java.util.Collection;
+import java.util.LinkedHashSet;
+
+import junit.framework.TestCase;
+
+public class XQuery10ExpressionCompilerImplTest extends TestCase {
+
+ public void testGetVariableNames() throws Exception {
+ String xq = "let $status := string($SomeVariable/ns:somePath)\n" +
+ " return\n" +
+ " if ($status = 'ABC' ) then\n" +
+ " '123'\n" +
+ " else $status (: workaround :)";
+
+ assertMatches(xq);
+ }
+
+ public void testGetVariableNames_endsWithVariableName() throws Exception {
+ String xq = "let $status := string($SomeVariable/ns:somePath)\n" +
+ " return\n" +
+ " if ($status = 'ABC' ) then\n" +
+ " '123'\n" +
+ " else $status";
+
+ assertMatches(xq);
+ }
+
+ private void assertMatches(String xq) {
+ Collection<String> varNames =
XQuery10ExpressionCompilerImpl.getVariableNames(xq);
+ Collection<String> expected = new
LinkedHashSet(Arrays.asList("status", "SomeVariable"));
+
+ assertEquals(2, varNames.size());
+ assertEquals(expected, varNames);
+ }
+
+}
Modified: branches/ODE/ODE-1.x/bpel-compiler/src/test/resources/log4j.properties
===================================================================
--- branches/ODE/ODE-1.x/bpel-compiler/src/test/resources/log4j.properties 2010-04-14
15:43:12 UTC (rev 619)
+++ branches/ODE/ODE-1.x/bpel-compiler/src/test/resources/log4j.properties 2010-04-14
18:25:55 UTC (rev 620)
@@ -1,30 +1,36 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+#
http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+# implied.
+#
+# See the License for the specific language governing permissions and
+# limitations under the License.
#
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements. See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
#
-#
http://www.apache.org/licenses/LICENSE-2.0
+
#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
+# The logging properties used during tests..
#
+log4j.rootLogger=INFO, file
-# Set root logger level to WARN and its only appender to CONSOLE
-log4j.rootLogger=WARN, CONSOLE
+log4j.appender.file=org.apache.log4j.FileAppender
+log4j.appender.file.File=target/test/test.log
+log4j.appender.file.layout=org.apache.log4j.PatternLayout
+log4j.appender.file.layout.ConversionPattern=%d{MM-dd@HH:mm:ss} %-5p (%13F:%L) %3x - %m%n
-# log4j properties to work with commandline tools.
-log4j.category.org.mortbay=ERROR
-log4j.category.org.hibernate.type=WARN
-log4j.category.org.objectweb=ERROR
-#log4j.category.org.apache.ode.bpel.compiler=DEBUG
+log4j.appender.stdout=org.apache.log4j.ConsoleAppender
+log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
+log4j.appender.stdout.layout.ConversionPattern=%d{MM-dd@HH:mm:ss} %-5p (%13F:%L) %3x -
%m%n
-# Console appender
-log4j.appender.CONSOLE=org.apache.log4j.ConsoleAppender
-log4j.appender.CONSOLE.layout=org.apache.log4j.PatternLayout
-log4j.appender.CONSOLE.layout.ConversionPattern=%p - %C{1}.%M(%L) | %m%n
+log4j.category.org.apache.ode=DEBUG
+
Added: branches/ODE/ODE-1.x/bpel-connector/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/bpel-connector/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/bpel-connector/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,54 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-connector</artifactId>
+ <name>ODE :: JCA Connector Implementation</name>
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-api-jca</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-runtime</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jca-ra</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jca-server</artifactId>
+ </dependency>
+ </dependencies>
+</project>
Added: branches/ODE/ODE-1.x/bpel-dao/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/bpel-dao/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/bpel-dao/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,40 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-dao</artifactId>
+ <name>ODE :: DAO Interfaces</name>
+ <packaging>jar</packaging>
+ <modelVersion>4.0.0</modelVersion>
+
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-api</artifactId>
+ </dependency>
+ </dependencies>
+</project>
Modified:
branches/ODE/ODE-1.x/bpel-dao/src/main/java/org/apache/ode/bpel/dao/CorrelatorDAO.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-dao/src/main/java/org/apache/ode/bpel/dao/CorrelatorDAO.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-dao/src/main/java/org/apache/ode/bpel/dao/CorrelatorDAO.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -20,6 +20,7 @@
import java.util.List;
+import org.apache.ode.bpel.common.CorrelationKey;
import org.apache.ode.bpel.common.CorrelationKeySet;
import java.util.Collection;
@@ -89,6 +90,13 @@
List<MessageRouteDAO> findRoute(CorrelationKeySet correlationKeySet);
/**
+ * Check if corresponding key set is free to register (see ODE-804)
+ * @param correlationKeySet
+ * @return true - available, false - not available
+ */
+ boolean checkRoute(CorrelationKeySet correlationKeySet);
+
+ /**
* Add a route from the given correlation key to the given process instance.
* @param routeGroupId identifier of the group of routes to which this route belongs
* @param target target process instance
Modified:
branches/ODE/ODE-1.x/bpel-dao/src/main/java/org/apache/ode/bpel/dao/MessageExchangeDAO.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-dao/src/main/java/org/apache/ode/bpel/dao/MessageExchangeDAO.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-dao/src/main/java/org/apache/ode/bpel/dao/MessageExchangeDAO.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -54,6 +54,8 @@
*/
Date getCreateTime();
+ void setCreateTime(Date createTime);
+
/**
* Get the input message.
*
Modified:
branches/ODE/ODE-1.x/bpel-dao/src/main/java/org/apache/ode/bpel/dao/ProcessInstanceDAO.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-dao/src/main/java/org/apache/ode/bpel/dao/ProcessInstanceDAO.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-dao/src/main/java/org/apache/ode/bpel/dao/ProcessInstanceDAO.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -198,6 +198,13 @@
void delete(Set<CLEANUP_CATEGORY> cleanupCategories);
/**
+ * Delete the process instance object from the database.
+ * @param cleanupCategories the categories of entities to delete
+ * @param deleteMyRoleMex will clean up the my role mex if set to true
+ */
+ void delete(Set<CLEANUP_CATEGORY> cleanupCategories, boolean deleteMyRoleMex);
+
+ /**
* Insert a BPEL event to the database (associating with this process).
* @param event BPEL event
*/
@@ -255,4 +262,5 @@
public int count;
}
+ Collection<String> getMessageExchangeIds();
}
Modified:
branches/ODE/ODE-1.x/bpel-dao/src/main/java/org/apache/ode/bpel/dao/ProcessManagementDAO.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-dao/src/main/java/org/apache/ode/bpel/dao/ProcessManagementDAO.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-dao/src/main/java/org/apache/ode/bpel/dao/ProcessManagementDAO.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -20,31 +20,83 @@
package org.apache.ode.bpel.dao;
import java.util.Collection;
+import java.util.Date;
+import java.util.Map;
+import java.util.Set;
+import javax.xml.namespace.QName;
+
/**
- * This DAO handles any process and instance management related database operations. The
idea is to separate out
- * the operational side of database tasks from core engine.
+ * This DAO handles any process and instance management related database
+ * operations. The idea is to separate out the operational side of database
+ * tasks from core engine.
*
* @author sean
- *
+ *
*/
public interface ProcessManagementDAO {
- /**
- * Finds process instances that have failures on a given process id, and, returns the
number of failed instances
- * and the last failed date in an object array.
- *
- * @param conn BpelDAOConnection
- * @param status the status string, e.g. "active"
- * @param processId the string representation of the QName of the process
- * @return an array containing the number of failed instances and the last failed date
- */
- public Object[] findFailedCountAndLastFailedDateForProcessId(BpelDAOConnection conn,
String status, String processId);
-
- /**
- * Prefetches the counts of activity failures for the given instances and sets the
values to the _activityFailureCount
- * member variable of the ProcesInstanceDAOImpl.
- *
- * @param instances a collection of process instances
- */
- public void prefetchActivityFailureCounts(Collection<ProcessInstanceDAO>
instances);
+ public static class InstanceSummaryKey {
+ public final String pid;
+ public final String instanceStatus;
+
+ public InstanceSummaryKey(String pid, String instanceStatus) {
+ super();
+ this.pid = pid;
+ this.instanceStatus = instanceStatus;
+ }
+
+ @Override
+ public String toString() {
+ return "InstanceSummaryKey [instanceStatus=" + instanceStatus
+ + ", pid=" + pid + "]";
+ }
+
+ @Override
+ public int hashCode() {
+ final int prime = 31;
+ int result = 1;
+ result = prime
+ * result
+ + ((instanceStatus == null) ? 0 : instanceStatus.hashCode());
+ result = prime * result + ((pid == null) ? 0 : pid.hashCode());
+ return result;
+ }
+
+ @Override
+ public boolean equals(Object obj) {
+ if (this == obj)
+ return true;
+ if (obj == null)
+ return false;
+ if (getClass() != obj.getClass())
+ return false;
+ InstanceSummaryKey other = (InstanceSummaryKey) obj;
+ if (instanceStatus == null) {
+ if (other.instanceStatus != null)
+ return false;
+ } else if (!instanceStatus.equals(other.instanceStatus))
+ return false;
+ if (pid == null) {
+ if (other.pid != null)
+ return false;
+ } else if (!pid.equals(other.pid))
+ return false;
+ return true;
+ }
+
+ }
+
+ public static class FailedSummaryValue {
+ public final Long count;
+ public final Date lastFailed;
+ public FailedSummaryValue(Long count, Date lastFailed) {
+ super();
+ this.count = count;
+ this.lastFailed = lastFailed;
+ }
+ }
+
+ public Map<InstanceSummaryKey, Long> countInstancesSummary(Set<String>
pids);
+
+ public Map<String, FailedSummaryValue>
findFailedCountAndLastFailedDateForProcessIds(Set<String> pids);
}
\ No newline at end of file
Added: branches/ODE/ODE-1.x/bpel-epr/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/bpel-epr/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/bpel-epr/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,76 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-epr</artifactId>
+ <name>ODE :: Interface Layers Common</name>
+ <packaging>jar</packaging>
+ <modelVersion>4.0.0</modelVersion>
+
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-utils</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-dao</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-api</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>org.apache.derby</groupId>
+ <artifactId>derby</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-jta_1.1_spec</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.components</groupId>
+ <artifactId>geronimo-connector</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.components</groupId>
+ <artifactId>geronimo-transaction</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.jencks</groupId>
+ <artifactId>jencks</artifactId>
+ <version>${jencks.version}</version>
+ <classifier>all</classifier>
+ </dependency>
+ <dependency>
+ <groupId>commons-beanutils</groupId>
+ <artifactId>commons-beanutils</artifactId>
+ <version>1.8.2</version>
+ </dependency>
+ </dependencies>
+</project>
Modified:
branches/ODE/ODE-1.x/bpel-epr/src/main/java/org/apache/ode/il/DynamicService.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-epr/src/main/java/org/apache/ode/il/DynamicService.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-epr/src/main/java/org/apache/ode/il/DynamicService.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -33,7 +33,9 @@
import org.apache.axiom.om.OMAbstractFactory;
import org.apache.axiom.om.OMElement;
import org.apache.axiom.om.OMFactory;
+import org.apache.axiom.om.OMNamespace;
import org.apache.axiom.om.impl.builder.StAXOMBuilder;
+import org.apache.axiom.om.impl.dom.NamespaceImpl;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.apache.ode.bpel.pmapi.ProcessInfoCustomizer;
@@ -69,7 +71,10 @@
Object result = invokedMethod.invoke(_service, params);
OMElement response = null;
if (result != null) {
- response = OM.createOMElement(new
QName(payload.getNamespace().getNamespaceURI(), methodName+"Response"));
+ if (__log.isDebugEnabled())
+ __log.debug("Invoke: operation "+operation+" on
"+_clazz + ":\n" + payload + "\nOM:" + OM + "
namespace:" + payload.getNamespace());
+ response = OM.createOMElement(new QName((payload.getNamespace() == null ?
"" : payload.getNamespace().getNamespaceURI()),
methodName+"Response"));
+
OMElement parts = convertToOM(result);
parts = stripNamespace(parts);
response.addChild(parts);
@@ -128,9 +133,11 @@
return alist.toArray((Object[]) Array.newInstance(targetClazz,
alist.size()));
} else if (XmlObject.class.isAssignableFrom(clazz)) {
try {
- Class beanFactory = Class.forName(clazz.getCanonicalName() +
".Factory");
+ Class beanFactory = clazz.forName(clazz.getCanonicalName() +
"$Factory");
+ elmt.setNamespace(new NamespaceImpl(""));
+ elmt.setLocalName("xml-fragment");
return beanFactory.getMethod("parse", XMLStreamReader.class)
- .invoke(elmt.getXMLStreamReaderWithoutCaching());
+ .invoke(null, elmt.getXMLStreamReaderWithoutCaching());
} catch (ClassNotFoundException e) {
throw new RuntimeException("Couldn't find class " +
clazz.getCanonicalName() + ".Factory to instantiate xml bean", e);
} catch (IllegalAccessException e) {
Modified:
branches/ODE/ODE-1.x/bpel-epr/src/main/java/org/apache/ode/il/MockScheduler.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-epr/src/main/java/org/apache/ode/il/MockScheduler.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-epr/src/main/java/org/apache/ode/il/MockScheduler.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -71,59 +71,66 @@
public String schedulePersistedJob(final Map<String, Object> detail, final Date
date) throws ContextException {
if (date != null) {
+ return scheduleVolatileJob(true, detail, date);
+ } else {
+ return scheduleVolatileJob(true, detail);
+ }
+ }
+
+ public String scheduleVolatileJob(boolean transacted, Map<String, Object>
jobDetail) throws ContextException {
+ return scheduleVolatileJob(transacted, jobDetail, null);
+ }
+
+ public String scheduleVolatileJob(final boolean transacted, final Map<String,
Object> detail, final Date date) throws ContextException {
+ if (date != null) {
registerSynchronizer(new Synchronizer() {
public void afterCompletion(boolean success) {
if (!success) return;
_timer.schedule(new TimerTask() {
@SuppressWarnings("unchecked")
public void run() {
- try {
- execIsolatedTransaction(new Callable() {
- public Object call() throws Exception {
- JobInfo ji = new JobInfo("volatileJob",
detail, 0);
- doExecute(ji);
- return null;
- }
- });
- } catch (Exception e) {
- throw new ContextException("Failure when scheduling
a new volatile job.", e);
- }
+ exec(transacted, detail);
}
}, date);
}
- public void beforeCompletion() { }
+
+ public void beforeCompletion() {
+ }
});
return null;
} else {
- return scheduleVolatileJob(true, detail);
+ registerSynchronizer(new Synchronizer() {
+ @SuppressWarnings("unchecked")
+ public void afterCompletion(boolean success) {
+ if (!success) return;
+ exec(transacted, detail);
+ }
+
+ public void beforeCompletion() {
+ }
+ });
+ return null;
}
}
- public String scheduleVolatileJob(final boolean transacted, final Map<String,
Object> detail) throws ContextException {
- registerSynchronizer(new Synchronizer() {
- @SuppressWarnings("unchecked")
- public void afterCompletion(boolean success) {
- if (!success) return;
- try {
- if (transacted) {
- execIsolatedTransaction(new Callable() {
- public Object call() throws Exception {
- JobInfo ji = new JobInfo("volatileJob", detail,
0);
- doExecute(ji);
- return null;
- }
- });
- } else {
+ private void exec(boolean transacted, final Map<String, Object> detail) {
+ try {
+ if (transacted) {
+
+ execIsolatedTransaction(new Callable() {
+ public Object call() throws Exception {
JobInfo ji = new JobInfo("volatileJob", detail, 0);
doExecute(ji);
+ return null;
}
- } catch (Exception e) {
- throw new ContextException("Failure when starting a new volatile
job.", e);
- }
+ });
+ } else {
+ JobInfo ji = new JobInfo("volatileJob", detail, 0);
+ doExecute(ji);
}
- public void beforeCompletion() { }
- });
- return null;
+ } catch (Exception e) {
+ throw new ContextException("Failure when scheduling a new volatile
job.", e);
+ }
}
public String scheduleMapSerializableRunnable(final MapSerializableRunnable runnable,
final Date when) throws ContextException {
@@ -149,6 +156,13 @@
}
public <T> T execTransaction(Callable<T> transaction) throws Exception,
ContextException {
+ return execTransaction(transaction, 0);
+ }
+
+ public <T> T execTransaction(Callable<T> transaction, int timeout) throws
Exception, ContextException {
+ if (timeout > 0) {
+ _txm.setTransactionTimeout(timeout);
+ }
beginTransaction();
try {
T retval = transaction.call();
@@ -158,6 +172,11 @@
__log.error("Caught an exception during transaction", t);
rollbackTransaction();
throw new ContextException("Error in tx", t);
+ } finally {
+ if (timeout > 0) {
+ // restores the default value
+ _txm.setTransactionTimeout(0);
+ }
}
}
Modified:
branches/ODE/ODE-1.x/bpel-epr/src/main/java/org/apache/ode/il/config/OdeConfigProperties.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-epr/src/main/java/org/apache/ode/il/config/OdeConfigProperties.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-epr/src/main/java/org/apache/ode/il/config/OdeConfigProperties.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -23,6 +23,7 @@
import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.IOException;
+import java.util.Map;
import java.util.Properties;
import org.apache.commons.logging.Log;
@@ -71,6 +72,8 @@
public static final String PROP_WORKING_DIR = "working.dir";
+ public static final String PROP_DEPLOY_DIR = "deploy.dir";
+
public static final String PROP_EVENT_LISTENERS = "event.listeners";
public static final String PROP_MEX_INTERCEPTORS = "mex.interceptors";
@@ -95,6 +98,8 @@
public static final String PROP_DAOCF = "dao.factory";
+ public static final String PROP_MIGRATION_TRANSACTION_TIMEOUT =
"migration.transaction.timeout";
+
public static final String DEFAULT_TX_FACTORY_CLASS_NAME =
"org.apache.ode.il.EmbeddedGeronimoFactory";
private File _cfgFile;
@@ -168,8 +173,8 @@
}
for (Object key : _props.keySet()) {
String value = (String) _props.get(key);
- value = SystemUtils.replaceSystemProperties(value);
- _props.put(key, value);
+ value = SystemUtils.replaceSystemProperties(value);
+ _props.put(key, value);
}
}
@@ -199,6 +204,22 @@
public String getDbIntenralJdbcUrl() {
return getProperty(OdeConfigProperties.PROP_DB_INTERNAL_URL,
"jdbc:derby://localhost/ode");
}
+
+ public String getDbInternalMCFClass() {
+ return getProperty("db.int.mcf");
+ }
+
+ public Properties getDbInternalMCFProperties() {
+ String prefix = _prefix + "db.int.mcf.";
+ Properties p = new Properties();
+ for (Map.Entry<Object, Object> e : _props.entrySet()) {
+ String s = "" + e.getKey();
+ if (s.startsWith(prefix)) {
+ p.put(s.substring(prefix.length()), e.getValue());
+ }
+ }
+ return p;
+ }
/**
* JDBC driver class (for use in INTERNAL mode).
@@ -237,6 +258,10 @@
return getProperty(OdeConfigProperties.PROP_WORKING_DIR);
}
+ public String getDeployDir() {
+ return getProperty(OdeConfigProperties.PROP_DEPLOY_DIR);
+ }
+
public String getTxFactoryClass() {
return getProperty(OdeConfigProperties.PROP_TX_FACTORY_CLASS,
DEFAULT_TX_FACTORY_CLASS_NAME);
}
@@ -258,7 +283,7 @@
}
public long getDehydrationMaximumAge() {
- return Long.valueOf(getProperty(PROP_PROCESS_DEHYDRATION_MAXIMUM_AGE,
""+20*60*1000));
+ return Long.valueOf(getProperty(PROP_PROCESS_DEHYDRATION_MAXIMUM_AGE,
""+20*60*1000));
}
public int getDehydrationMaximumCount() {
@@ -313,5 +338,9 @@
public String getDbInternalPassword() {
return getProperty(PROP_DB_INTERNAL_PASSWORD);
}
+
+ public int getMigrationTransactionTimeout() {
+ return Integer.valueOf(getProperty(PROP_MIGRATION_TRANSACTION_TIMEOUT,
String.valueOf(0)));
+ }
}
Modified:
branches/ODE/ODE-1.x/bpel-epr/src/main/java/org/apache/ode/il/dbutil/Database.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-epr/src/main/java/org/apache/ode/il/dbutil/Database.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-epr/src/main/java/org/apache/ode/il/dbutil/Database.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -26,6 +26,7 @@
import javax.sql.DataSource;
import javax.transaction.TransactionManager;
+import org.apache.commons.beanutils.BeanUtils;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.apache.derby.jdbc.EmbeddedDriver;
@@ -136,7 +137,7 @@
public DataSource getDataSource() {
//return __logSql.isDebugEnabled() ? new LoggingDataSourceWrapper(_datasource,
__logSql) : _datasource;
- return __logSql.isDebugEnabled() ? LoggingInterceptor.createLoggingDS(_datasource,
__logSql) : _datasource;
+ return __logSql.isDebugEnabled() ?
LoggingInterceptor.createLoggingDS(_datasource, __logSql) : _datasource;
}
private void initDataSource() throws DatabaseConfigException {
@@ -170,14 +171,13 @@
__log.info(__msgs.msgOdeUsingInternalDb(_odeConfig.getDbIntenralJdbcUrl(),
_odeConfig.getDbInternalJdbcDriverClass()));
initInternalDb(_odeConfig.getDbIntenralJdbcUrl(),
_odeConfig.getDbInternalJdbcDriverClass(),
_odeConfig.getDbInternalUserName(), _odeConfig.getDbInternalPassword());
-
}
private void initInternalDb(String url, String driverClass, String username,String
password) throws DatabaseConfigException {
__log.debug("Creating connection pool for " + url + " with driver
" + driverClass);
if (!(_txm instanceof RecoverableTransactionManager)) {
- throw new RuntimeException("TransactionManager is not recoverable.");
+ throw new RuntimeException("TransactionManager is not
recoverable.");
}
TransactionSupport transactionSupport = LocalTransactions.INSTANCE;
@@ -201,16 +201,32 @@
getClass().getName(),
getClass().getClassLoader());
- JDBCDriverMCF mcf = new JDBCDriverMCF();
+
try {
- mcf.setDriver(driverClass);
- mcf.setConnectionURL(url);
- if (username != null) {
- mcf.setUserName(username);
+ javax.resource.spi.ManagedConnectionFactory mcf = null;
+ String mcfClass = _odeConfig.getDbInternalMCFClass();
+ if (mcfClass != null) {
+ Properties dbInternalMCFProps = _odeConfig.getDbInternalMCFProperties();
+ if (__log.isDebugEnabled()) {
+ __log.debug("Using internal DB MCF " + mcfClass + "
" + dbInternalMCFProps);
+ }
+ mcf = (javax.resource.spi.ManagedConnectionFactory)
Class.forName(mcfClass).newInstance();
+ BeanUtils.copyProperties(mcf, dbInternalMCFProps);
+ } else {
+ if (__log.isDebugEnabled()) {
+ __log.debug("Using internal DB JDBCDriverMCF");
+ }
+ JDBCDriverMCF mcf2 = new JDBCDriverMCF();
+ mcf = mcf2;
+ mcf2.setDriver(driverClass);
+ mcf2.setConnectionURL(url);
+ if (username != null) {
+ mcf2.setUserName(username);
+ }
+ if (password != null) {
+ mcf2.setPassword(password);
+ }
}
- if (password != null) {
- mcf.setPassword(password);
- }
_connectionManager.doStart();
_datasource = (DataSource) mcf.createConnectionFactory(_connectionManager);
} catch (Exception ex) {
Added:
branches/ODE/ODE-1.x/bpel-epr/src/main/test/org/apache/ode/bpel/epr/WSDL11EndpointTest.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-epr/src/main/test/org/apache/ode/bpel/epr/WSDL11EndpointTest.java
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-epr/src/main/test/org/apache/ode/bpel/epr/WSDL11EndpointTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,71 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.ode.bpel.epr;
+
+import junit.framework.TestCase;
+
+import org.apache.ode.utils.DOMUtils;
+import org.apache.ode.utils.Namespaces;
+import org.w3c.dom.Document;
+import org.w3c.dom.Node;
+
+/**
+ * A test for the WSDL11Endpoint class, to define how it works.
+ *
+ *
+ * @author <a href="mailto:atoulme@intalio.com">Antoine Toulme</a>
+ */
+public class WSDL11EndpointTest extends TestCase {
+
+ public void testAcceptServiceElement() {
+ WSDL11Endpoint endpoint = new WSDL11Endpoint();
+ Document doc = DOMUtils.newDocument();
+ Node node = doc.createElementNS(Namespaces.WSDL_11, "service");
+
node.appendChild(doc.createTextNode("http://example.com/hello"));
+ assertTrue(endpoint.accept(node));
+ }
+
+
+ public void testAcceptServiceRefElement() {
+ WSDL11Endpoint endpoint = new WSDL11Endpoint();
+ Document doc = DOMUtils.newDocument();
+ Node node = doc.createElementNS(Namespaces.WS_BPEL_20_NS,
"service-ref");
+ Node child = doc.createElementNS(Namespaces.WSDL_11, "service");
+ node.appendChild(child);
+
child.appendChild(doc.createTextNode("http://example.com/hello"));
+ assertTrue(endpoint.accept(node));
+ }
+
+
+ public void testAcceptServiceWithRandomElement() {
+ WSDL11Endpoint endpoint = new WSDL11Endpoint();
+ Document doc = DOMUtils.newDocument();
+ Node child =
doc.createElementNS("http://example.com/someNM",
"helloHeloo");
+
child.appendChild(doc.createTextNode("http://example.com/hello"));
+ assertFalse("The endpoint should accept a random element",
endpoint.accept(child));
+ }
+
+ public void testAcceptServiceWithTextNode() {
+ WSDL11Endpoint endpoint = new WSDL11Endpoint();
+ Document doc = DOMUtils.newDocument();
+ assertFalse("The endpoint should accept a text node",
+
endpoint.accept(doc.createTextNode("http://example.com/hello")));
+ }
+}
Added: branches/ODE/ODE-1.x/bpel-obj/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/bpel-obj/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/bpel-obj/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,64 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-obj</artifactId>
+ <name>ODE :: OBJ</name>
+ <packaging>jar</packaging>
+ <modelVersion>4.0.0</modelVersion>
+
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-utils</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>wsdl4j</groupId>
+ <artifactId>wsdl4j</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-logging</groupId>
+ <artifactId>commons-logging</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon-dom</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon-xpath</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon-xqj</artifactId>
+ </dependency>
+ </dependencies>
+</project>
Modified:
branches/ODE/ODE-1.x/bpel-obj/src/main/java/org/apache/ode/bpel/o/OActivity.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-obj/src/main/java/org/apache/ode/bpel/o/OActivity.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-obj/src/main/java/org/apache/ode/bpel/o/OActivity.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -18,9 +18,11 @@
*/
package org.apache.ode.bpel.o;
-import org.apache.ode.utils.ObjectPrinter;
-
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.Comparator;
import java.util.HashSet;
+import java.util.List;
import java.util.Set;
@@ -77,4 +79,29 @@
return buf.toString();
}
+ @Override
+ public String digest() {
+ StringBuffer buf = new StringBuffer(getClass().getSimpleName());
+ buf.append('#');
+ buf.append(getId());
+ buf.append("{");
+ List<OAgent> l = new ArrayList<OAgent>();
+ l.addAll(nested);
+ Collections.sort(l, new Comparator<OAgent>() {
+ private String key(OAgent o) {
+ return o.getClass().getSimpleName() + "#" + o.getId();
+ }
+
+ public int compare(OAgent o1, OAgent o2) {
+ return key(o1).compareTo(key(o2));
+ }
+ });
+
+ for (OAgent child : l) {
+ buf.append(child.digest());
+ buf.append(";");
+ }
+ buf.append("}");
+ return buf.toString();
+ }
}
Modified: branches/ODE/ODE-1.x/bpel-obj/src/main/java/org/apache/ode/bpel/o/OAssign.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-obj/src/main/java/org/apache/ode/bpel/o/OAssign.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-obj/src/main/java/org/apache/ode/bpel/o/OAssign.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -18,18 +18,16 @@
*/
package org.apache.ode.bpel.o;
+import java.io.IOException;
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.xml.namespace.QName;
+
import org.apache.ode.bpel.o.OScope.Variable;
import org.apache.ode.utils.DOMUtils;
import org.w3c.dom.Document;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-import org.xml.sax.SAXException;
-import javax.xml.namespace.QName;
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.List;
-
public class OAssign extends OActivity {
static final long serialVersionUID = -1L ;
@@ -80,37 +78,39 @@
public static class Literal extends OBase implements RValue {
private static final long serialVersionUID = 1L;
- public transient String stringLiteral;
+ public transient String xmlLiteral;
public Literal(OProcess owner, Document xmlLiteral) {
super(owner);
if (xmlLiteral == null)
throw new IllegalArgumentException("null xmlLiteral!");
- this.stringLiteral = DOMUtils.domToString(xmlLiteral);
+ this.xmlLiteral = DOMUtils.domToString(xmlLiteral);
}
public String toString() {
- return "{Literal " + stringLiteral + "}";
+ return "{Literal " + xmlLiteral + "}";
}
private void writeObject(java.io.ObjectOutputStream out)
throws IOException
{
- out.writeObject(stringLiteral);
+ out.writeObject(xmlLiteral);
}
private void readObject(java.io.ObjectInputStream in)
throws IOException
{
+ String domStr = null;
try {
- stringLiteral = (String) in.readObject();
+ domStr = (String) in.readObject();
} catch (ClassNotFoundException e) {
throw (IOException)(new IOException("XML de-serialization
error.")).initCause(e);
}
+ xmlLiteral = domStr;
}
- public Document getXmlLiteral() throws SAXException, IOException {
- return DOMUtils.stringToDOM(stringLiteral).getOwnerDocument();
+ public String getXmlLiteral() {
+ return xmlLiteral;
}
}
Modified: branches/ODE/ODE-1.x/bpel-obj/src/main/java/org/apache/ode/bpel/o/OBase.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-obj/src/main/java/org/apache/ode/bpel/o/OBase.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-obj/src/main/java/org/apache/ode/bpel/o/OBase.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -78,6 +78,9 @@
debugInfo.extensibilityElements = null;
debugInfo = null;
}
+ }
+ public String digest() {
+ return "";
}
}
Modified:
branches/ODE/ODE-1.x/bpel-obj/src/main/java/org/apache/ode/bpel/o/OConstants.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-obj/src/main/java/org/apache/ode/bpel/o/OConstants.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-obj/src/main/java/org/apache/ode/bpel/o/OConstants.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -31,6 +31,7 @@
public QName qnMissingReply;
public QName qnUninitializedVariable;
public QName qnConflictingReceive;
+ public QName qnConflictingRequest;
public QName qnSelectionFailure;
public QName qnMismatchedAssignmentFailure;
public QName qnJoinFailure;
@@ -53,5 +54,12 @@
public OConstants(OProcess owner) {
super(owner);
}
-
+
+ private String getNS() {
+ return qnMissingRequest.getNamespaceURI();
+ }
+
+ public QName qnAmbiguousReceive() {
+ return new QName(getNS(), "ambiguousReceive");
+ }
}
Modified: branches/ODE/ODE-1.x/bpel-obj/src/main/java/org/apache/ode/bpel/o/OProcess.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-obj/src/main/java/org/apache/ode/bpel/o/OProcess.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-obj/src/main/java/org/apache/ode/bpel/o/OProcess.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -216,4 +216,9 @@
xsdTypes.clear();
xslSheets.clear();
}
+
+ @Override
+ public String digest() {
+ return processName + ";" + procesScope.digest();
+ }
}
Modified: branches/ODE/ODE-1.x/bpel-ql/build.properties
===================================================================
--- branches/ODE/ODE-1.x/bpel-ql/build.properties 2010-04-14 15:43:12 UTC (rev 619)
+++ branches/ODE/ODE-1.x/bpel-ql/build.properties 2010-04-14 18:25:55 UTC (rev 620)
@@ -1,26 +1,26 @@
-#
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-#
http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-#
-
-#Mon Mar 20 18:02:40 EET 2006
-javacc.home=../buildlib/javacc-4.0
-grammar.node.package_dir=com/fs/ode/ql/jcc
-grammar.node.custom=src/jcc/com/fs/ode/ql/jcc
-grammar.node.package=org.apache.ode.ql.jcc
-grammar.syntax.src=com/fs/ode/ql/jcc/ql.jj
-grammar.tree.src=src/main/jjtree/ql.jjt
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+#
http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+
+#Mon Mar 20 18:02:40 EET 2006
+javacc.home=../buildlib/javacc-4.0
+grammar.node.package_dir=com/fs/ode/ql/jcc
+grammar.node.custom=src/jcc/com/fs/ode/ql/jcc
+grammar.node.package=org.apache.ode.ql.jcc
+grammar.syntax.src=com/fs/ode/ql/jcc/ql.jj
+grammar.tree.src=src/main/jjtree/ql.jjt
Added: branches/ODE/ODE-1.x/bpel-ql/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/bpel-ql/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/bpel-ql/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,71 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-ql</artifactId>
+ <name>ODE :: BPEL Query Language</name>
+ <packaging>jar</packaging>
+ <modelVersion>4.0.0</modelVersion>
+
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-compiler</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>javacc-maven-plugin</artifactId>
+ <executions>
+ <execution>
+ <goals>
+ <goal>jjtree-javacc</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-surefire-plugin</artifactId>
+ <version>2.5</version>
+ <configuration>
+ <systemPropertyVariables>
+ <baseDir>${project.build.directory}/test-classes</baseDir>
+ </systemPropertyVariables>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+</project>
Added: branches/ODE/ODE-1.x/bpel-runtime/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/bpel-runtime/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/bpel-runtime/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,245 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-runtime</artifactId>
+ <name>ODE :: Runtime Engine</name>
+ <packaging>jar</packaging>
+ <modelVersion>4.0.0</modelVersion>
+
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <dependencies>
+ <dependency>
+ <groupId>log4j</groupId>
+ <artifactId>log4j</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-compiler</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-dao</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-schemas</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-store</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jacob</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jacob-ap</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-utils</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-epr</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-scheduler-simple</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-dao-jpa</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-dao-hibernate</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>commons-pool</groupId>
+ <artifactId>commons-pool</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>hsqldb</groupId>
+ <artifactId>hsqldb</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>jmock</groupId>
+ <artifactId>jmock</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.derby</groupId>
+ <artifactId>derby</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-agents</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jacob</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jacob-ap</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-utils</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-dao</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-collections</groupId>
+ <artifactId>commons-collections</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-logging</groupId>
+ <artifactId>commons-logging</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-httpclient</groupId>
+ <artifactId>commons-httpclient</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-lang</groupId>
+ <artifactId>commons-lang</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>jaxen</groupId>
+ <artifactId>jaxen</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-jta_1.1_spec</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-stax-api_1.0_spec</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>javax.persistence</groupId>
+ <artifactId>persistence-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>wsdl4j</groupId>
+ <artifactId>wsdl4j</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.xmlbeans</groupId>
+ <artifactId>xmlbeans</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon-xpath</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon-dom</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon-xqj</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>xerces</groupId>
+ <artifactId>xercesImpl</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <scope>test</scope>
+ </dependency>
+
+ <dependency>
+ <groupId>tranql</groupId>
+ <artifactId>tranql-connector-derby-common</artifactId>
+ <version>1.1</version>
+ <scope>test</scope>
+ </dependency>
+
+
+ </dependencies>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>apt-maven-plugin</artifactId>
+ <version>1.0-alpha-3</version>
+ <configuration>
+
<factory>org.apache.ode.jacob.ap.JacobAnnotationProcessorFactory</factory>
+ <outputDirectory>target/generated/apt</outputDirectory>
+ </configuration>
+ <executions>
+ <execution>
+ <goals>
+ <goal>process</goal>
+ <goal>test-process</goal>
+ </goals>
+ </execution>
+ </executions>
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jacob-ap</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ </dependencies>
+ </plugin>
+ </plugins>
+ </build>
+</project>
Added: branches/ODE/ODE-1.x/bpel-runtime/pom2.xml
===================================================================
--- branches/ODE/ODE-1.x/bpel-runtime/pom2.xml (rev 0)
+++ branches/ODE/ODE-1.x/bpel-runtime/pom2.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,151 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-runtimes</artifactId>
+ <name>ODE :: BPEL Runtimes</name>
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jacob</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jacob-ap</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-utils</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-dao</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-collections</groupId>
+ <artifactId>commons-collections</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-logging</groupId>
+ <artifactId>commons-logging</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-httpclient</groupId>
+ <artifactId>commons-httpclient</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-lang</groupId>
+ <artifactId>commons-lang</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>jaxen</groupId>
+ <artifactId>jaxen</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-jta_1.1_spec</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-stax-api_1.0_spec</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>javax.persistence</groupId>
+ <artifactId>persistence-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>wsdl4j</groupId>
+ <artifactId>wsdl4j</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.xmlbeans</groupId>
+ <artifactId>xmlbeans</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon-xpath</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon-dom</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon-xqj</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>xerces</groupId>
+ <artifactId>xercesImpl</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>apt-maven-plugin</artifactId>
+ <version>1.0-alpha-3</version>
+ <configuration>
+
<factory>org.apache.ode.jacob.ap.JacobAnnotationProcessorFactory</factory>
+ <outputDirectory>target/generated/apt</outputDirectory>
+ </configuration>
+ <executions>
+ <execution>
+ <goals>
+ <goal>process</goal>
+ <goal>test-process</goal>
+ </goals>
+ </execution>
+ </executions>
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jacob-ap</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ </dependencies>
+ </plugin>
+ </plugins>
+ </build>
+
+</project>
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/elang/xpath20/runtime/JaxpFunctionResolver.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/elang/xpath20/runtime/JaxpFunctionResolver.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/elang/xpath20/runtime/JaxpFunctionResolver.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -304,6 +304,7 @@
try {
result =
XslTransformHandler.getInstance().transform(_ectx.getProcessQName(), xslUri, source,
parametersMap, resolver);
} catch (Exception e) {
+ __log.error("Could not transform XSL sheet " + args.get(0) +
" on element " + DOMUtils.domToString(varElmt), e);
e.printStackTrace();
throw new XPathFunctionException(
new
FaultException(_oxpath.getOwner().constants.qnSubLanguageExecutionFault,
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/elang/xpath20/runtime/JaxpVariableResolver.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/elang/xpath20/runtime/JaxpVariableResolver.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/elang/xpath20/runtime/JaxpVariableResolver.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -25,6 +25,14 @@
import javax.xml.xpath.XPathVariableResolver;
import net.sf.saxon.Configuration;
+import net.sf.saxon.om.Item;
+import net.sf.saxon.type.AtomicType;
+import net.sf.saxon.type.SchemaType;
+import net.sf.saxon.type.ValidationException;
+import net.sf.saxon.value.AtomicValue;
+import net.sf.saxon.value.EmptySequence;
+import net.sf.saxon.value.StringValue;
+import net.sf.saxon.value.Value;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
@@ -36,6 +44,7 @@
import org.apache.ode.bpel.o.OMessageVarType;
import org.apache.ode.bpel.o.OScope;
import org.apache.ode.bpel.o.OXsdTypeVarType;
+import org.apache.ode.utils.DOMUtils;
import org.apache.ode.utils.Namespaces;
import org.apache.ode.utils.xsd.XSTypes;
import org.w3c.dom.Document;
@@ -61,7 +70,7 @@
public Object resolveVariable(QName variableName) {
__log.debug("Resolving variable " + variableName);
- if(!(_oxpath instanceof OXPath10ExpressionBPEL20)){
+ if (!(_oxpath instanceof OXPath10ExpressionBPEL20)) {
throw new IllegalStateException("XPath variables not supported for bpel
1.1");
}
@@ -72,10 +81,13 @@
} else if ("processQName".equals(variableName.getLocalPart())) {
return _ectx.getProcessQName();
}
+ if ("currentEventDateTime".equals(variableName.getLocalPart())) {
+ return _ectx.getCurrentEventDateTime();
+ }
}
OXPath10ExpressionBPEL20 expr = _oxpath;
- if(expr.isJoinExpression){
+ if (expr.isJoinExpression) {
OLink olink = _oxpath.links.get(variableName.getLocalPart());
try {
@@ -83,7 +95,7 @@
} catch (FaultException e) {
throw new WrappedResolverException(e);
}
- }else{
+ } else {
String varName;
String partName;
int dotloc = variableName.getLocalPart().indexOf('.');
@@ -95,58 +107,52 @@
partName = variableName.getLocalPart().substring(dotloc + 1);
}
OScope.Variable variable = _oxpath.vars.get(varName);
- OMessageVarType.Part part = partName == null ? null :
((OMessageVarType)variable.type).parts.get(partName);
+ OMessageVarType.Part part = partName == null ? null : ((OMessageVarType)
variable.type).parts.get(partName);
- try{
+ try {
final Node variableNode = _ectx.readVariable(variable, part);
if (variableNode == null)
- throw new
FaultException(variable.getOwner().constants.qnSelectionFailure,
- "Unknown variable " +
variableName.getLocalPart());
+ throw new
FaultException(variable.getOwner().constants.qnSelectionFailure, "Unknown variable
" + variableName.getLocalPart());
if (_ectx.narrowTypes()) {
- if (variable.type instanceof OXsdTypeVarType &&
((OXsdTypeVarType)variable.type).simple)
- return
getSimpleContent(variableNode,((OXsdTypeVarType)variable.type).xsdType);
- if (part != null && part.type instanceof OXsdTypeVarType
&& ((OXsdTypeVarType)part.type).simple)
- return
getSimpleContent(variableNode,((OXsdTypeVarType)part.type).xsdType);
+ if (variable.type instanceof OXsdTypeVarType &&
((OXsdTypeVarType) variable.type).simple)
+ return getSimpleContent(variableNode, ((OXsdTypeVarType)
variable.type).xsdType);
+ if (part != null && part.type instanceof OXsdTypeVarType
&& ((OXsdTypeVarType) part.type).simple)
+ return getSimpleContent(variableNode, ((OXsdTypeVarType)
part.type).xsdType);
}
// Saxon used to expect a node list, but now a regular node will
suffice.
return variableNode;
- }catch(FaultException e){
+ } catch (FaultException e) {
throw new WrappedResolverException(e);
}
}
}
-
- private Object getSimpleContent(Node simpleNode, QName type) {
- Document doc = (simpleNode instanceof Document)
- ? ((Document) simpleNode)
- : simpleNode.getOwnerDocument();
- String text = simpleNode.getTextContent();
- try {
- Object jobj = XSTypes.toJavaObject(type,text);
- if (jobj instanceof Calendar) {
- // Saxon 9.x prefers Dates over Calendars.
- return ((Calendar) jobj).getTime();
- } else if (jobj instanceof String) {
- // Saxon 9.x has a bug for which this is a workaround.
- return doc.createTextNode(jobj.toString());
- }
- return jobj;
- } catch (Exception e) {
- // Elegant way failed, trying brute force
- try {
- return Integer.valueOf(text);
- } catch (NumberFormatException nfe) { }
- try {
- return Double.valueOf(text);
- } catch (NumberFormatException nfe) { }
-
- // Remember: always a node set
- if (simpleNode.getParentNode() != null)
- return simpleNode.getParentNode().getChildNodes();
- else {
- return doc.createTextNode(text);
- }
+
+ public static Value convertSimpleTypeToSaxon(QName type, String value, Configuration
_config) {
+ int fp = _config.getNamePool().allocate("", type.getNamespaceURI(),
type.getLocalPart());
+ SchemaType type2 = _config.getSchemaType(fp);
+ if (type2 == null || !type2.isAtomicType()) {
+ __log.warn("Can't find simple type " + type + " value
" + value + " result: " + null);
+ return null;
+ } else {
+ try {
+ AtomicValue value2 = StringValue.convertStringToAtomicType(value,
(AtomicType) type2, null).asAtomic();
+ if (__log.isDebugEnabled()) {
+ __log.debug("converting " + type + " value " +
value + " result: " + value2);
+ }
+ return value2;
+ } catch (ValidationException e) {
+ __log.debug("Can't convert " + value + " to " +
type + " returning empty sequence");
+ return EmptySequence.getInstance();
+ }
}
}
+
+ public static Object getSimpleContent(Node simpleNode, QName type) {
+ Document doc = (simpleNode instanceof Document) ? ((Document) simpleNode) :
simpleNode.getOwnerDocument();
+ String text = simpleNode.getTextContent();
+ Object o = convertSimpleTypeToSaxon(type, text,
Configuration.makeConfiguration(null, null));
+ __log.debug("getSimpleContent for " + DOMUtils.domToString(simpleNode)
+ " " + type + " returned " + o);
+ return o;
+ }
}
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/elang/xpath20/runtime/XPath20ExpressionRuntime.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/elang/xpath20/runtime/XPath20ExpressionRuntime.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/elang/xpath20/runtime/XPath20ExpressionRuntime.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -166,7 +166,7 @@
public Node evaluateNode(OExpression cexp, EvaluationContext ctx) throws
FaultException, EvaluationException {
List retVal = evaluate(cexp, ctx);
if (retVal.size() == 0)
- throw new FaultException(cexp.getOwner().constants.qnSelectionFailure,
"No results for expression: " + cexp);
+ throw new FaultException(cexp.getOwner().constants.qnSelectionFailure,
"No results for expression: " + cexp, new
Throwable("ignoreMissingFromData"));
if (retVal.size() > 1)
throw new FaultException(cexp.getOwner().constants.qnSelectionFailure,
"Multiple results for expression: " + cexp);
return (Node) retVal.get(0);
@@ -213,18 +213,8 @@
private Object evaluate(OExpression cexp, EvaluationContext ctx, QName type) throws
FaultException, EvaluationException {
try {
OXPath20ExpressionBPEL20 oxpath20 = ((OXPath20ExpressionBPEL20) cexp);
-
System.setProperty("javax.xml.xpath.XPathFactory:"+NamespaceConstant.OBJECT_MODEL_SAXON,
- "net.sf.saxon.xpath.XPathFactoryImpl");
-
System.setProperty("javax.xml.xpath.XPathFactory:"+XPathConstants.DOM_OBJECT_MODEL,
- "net.sf.saxon.xpath.XPathFactoryImpl");
-
System.setProperty("javax.xml.xpath.XPathFactory:"+NamespaceConstant.OBJECT_MODEL_JDOM,
- "net.sf.saxon.xpath.XPathFactoryImpl");
-
System.setProperty("javax.xml.xpath.XPathFactory:"+NamespaceConstant.OBJECT_MODEL_XOM,
- "net.sf.saxon.xpath.XPathFactoryImpl");
-
System.setProperty("javax.xml.xpath.XPathFactory:"+NamespaceConstant.OBJECT_MODEL_DOM4J,
- "net.sf.saxon.xpath.XPathFactoryImpl");
-
- XPathFactory xpf =
XPathFactory.newInstance(NamespaceConstant.OBJECT_MODEL_SAXON);
+ XPathFactory xpf = new XPathFactoryImpl();
+
JaxpFunctionResolver funcResolver = new JaxpFunctionResolver(
ctx, oxpath20);
JaxpVariableResolver varResolver = new JaxpVariableResolver(ctx, oxpath20,
((XPathFactoryImpl) xpf).getConfiguration());
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/elang/xquery10/runtime/XQuery10ExpressionRuntime.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/elang/xquery10/runtime/XQuery10ExpressionRuntime.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/elang/xquery10/runtime/XQuery10ExpressionRuntime.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -46,11 +46,15 @@
import javax.xml.xquery.XQStaticContext;
import net.sf.saxon.Configuration;
+import net.sf.saxon.om.Item;
import net.sf.saxon.om.Validation;
import net.sf.saxon.trans.DynamicError;
+import net.sf.saxon.trans.XPathException;
import net.sf.saxon.value.DurationValue;
+import net.sf.saxon.value.Value;
import net.sf.saxon.xqj.SaxonXQConnection;
import net.sf.saxon.xqj.SaxonXQDataSource;
+import net.sf.saxon.xqj.SaxonXQItem;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
@@ -363,34 +367,54 @@
// Evaluate referenced variable
Object value = variableResolver.resolveVariable(variable);
- // Figure out type of variable
- XQSequenceType xqType = getItemType(xqconn, value);
-
- // Saxon doesn't like binding sequences to variables
- if (value instanceof Node) {
- // a node is a node-list, but the inverse isn't true.
- // so, if the value is truly a node, leave it alone.
- } else if (value instanceof NodeList) {
- // So extract the first item from the node list
- NodeList nodeList = (NodeList) value;
- ArrayList nodeArray = new ArrayList();
- for (int i = 0; i < nodeList.getLength(); i++) {
- nodeArray.add(nodeList.item(i));
- }
- value = xqconn.createSequence(nodeArray.iterator());
- }
-
-
- // Bind value with external variable
- if (value != null && xqType != null) {
- if (value instanceof XQSequence) {
- exp.bindSequence(variable, (XQSequence) value);
- } else {
- if (xqType instanceof XQItemType) {
- exp.bindObject(variable, value, (XQItemType) xqType);
- }
- }
- }
+ if (value instanceof Value) {
+ SaxonXQConnection saxonConn = (SaxonXQConnection) xqconn;
+ try {
+ Item item = ((Value) value).asItem();
+ if (item == null) {
+ exp.bindSequence(variable,
xqconn.createSequence(Collections.EMPTY_LIST.iterator()));
+ } else {
+ XQItem item2 = new SaxonXQItem(item, saxonConn);
+ exp.bindItem(variable, item2);
+ }
+ } catch (XPathException e) {
+ __log.warn("", e);
+ }
+ } else {
+
+ if (value instanceof Date) {
+ Date d = (Date) value;
+ value = org.apache.ode.utils.ISO8601DateParser.format(d);
+ }
+
+ // Figure out type of variable
+ XQSequenceType xqType = getItemType(xqconn, value);
+
+ // Saxon doesn't like binding sequences to variables
+ if (value instanceof Node) {
+ // a node is a node-list, but the inverse isn't true.
+ // so, if the value is truly a node, leave it alone.
+ } else if (value instanceof NodeList) {
+ // So extract the first item from the node list
+ NodeList nodeList = (NodeList) value;
+ ArrayList nodeArray = new ArrayList();
+ for (int i = 0; i < nodeList.getLength(); i++) {
+ nodeArray.add(nodeList.item(i));
+ }
+ value = xqconn.createSequence(nodeArray.iterator());
+ }
+
+ // Bind value with external variable
+ if (value != null && xqType != null) {
+ if (value instanceof XQSequence) {
+ exp.bindSequence(variable, (XQSequence) value);
+ } else {
+ if (xqType instanceof XQItemType) {
+ exp.bindObject(variable, value, (XQItemType) xqType);
+ }
+ }
+ }
+ }
}
// Set context node
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/BpelEngineImpl.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/BpelEngineImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/BpelEngineImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -46,6 +46,7 @@
import org.apache.ode.bpel.iapi.MessageExchange;
import org.apache.ode.bpel.iapi.MyRoleMessageExchange;
import org.apache.ode.bpel.iapi.PartnerRoleMessageExchange;
+import org.apache.ode.bpel.iapi.ProcessState;
import org.apache.ode.bpel.iapi.Scheduler;
import org.apache.ode.bpel.iapi.MessageExchange.FailureType;
import org.apache.ode.bpel.iapi.MessageExchange.MessageExchangePattern;
@@ -99,13 +100,13 @@
private static final Messages __msgs = MessageBundle.getMessages(Messages.class);
- private static final double PROCESS_OVERHEAD_MEMORY_FACTOR = 1.2;
+ private static final double PROCESS_OVERHEAD_MEMORY_FACTOR = 1.2;
/** Active processes, keyed by process id. */
- final HashMap<QName, BpelProcess> _activeProcesses = new HashMap<QName,
BpelProcess>();
+ public final HashMap<QName, BpelProcess> _activeProcesses = new
HashMap<QName, BpelProcess>();
- /** Mapping from myrole endpoint name to active process. */
- private final HashMap<Endpoint, List<BpelProcess>> _serviceMap = new
HashMap<Endpoint, List<BpelProcess>>();
+ /** Mapping from myrole service name to active process. */
+ private final HashMap<QName, List<BpelProcess>> _serviceMap = new
HashMap<QName, List<BpelProcess>>();
/** Mapping from a potentially shared endpoint to its EPR */
private SharedEndpoints _sharedEps;
@@ -125,7 +126,7 @@
}
public SharedEndpoints getSharedEndpoints() {
- return _sharedEps;
+ return _sharedEps;
}
public MyRoleMessageExchange createMessageExchange(String clientKey, QName
targetService,
@@ -133,23 +134,34 @@
throws BpelEngineException {
List<BpelProcess> targets = route(targetService, null);
+ List<BpelProcess> activeTargets = new ArrayList<BpelProcess>();
+ for (BpelProcess target : targets) {
+ if (target.getConf().getState() == ProcessState.ACTIVE) {
+ activeTargets.add(target);
+ }
+ }
if (targets == null || targets.size() == 0)
throw new BpelEngineException("NoSuchService: " + targetService);
- if (targets.size() == 1) {
+ if (targets.size() == 1 || activeTargets.size() == 1) {
// If the number of targets is one, create and return a simple MEX
- BpelProcess target = targets.get(0);
- return createNewMyRoleMex(target, clientKey, targetService, operation,
pipedMexId);
+ BpelProcess target;
+ if (activeTargets.size() == 1) {
+ target = activeTargets.get(0);
+ } else {
+ target = targets.get(0);
+ }
+ return createNewMyRoleMex(target, clientKey, targetService, operation,
pipedMexId);
} else {
- // If the number of targets is greater than one, create and return
- // a brokered MEX that embeds the simple MEXs for each of the targets
- BpelProcess template = targets.get(0);
+ // If the number of targets is greater than one, create and return
+ // a brokered MEX that embeds the simple MEXs for each of the targets
+ BpelProcess template = activeTargets.get(0);
ArrayList<MyRoleMessageExchange> meps = new
ArrayList<MyRoleMessageExchange>();
- for (BpelProcess target : targets) {
- meps.add(createNewMyRoleMex(target, clientKey, targetService, operation,
pipedMexId));
- }
- return createNewMyRoleMex(template, meps);
+ for (BpelProcess target : activeTargets) {
+ meps.add(createNewMyRoleMex(target, clientKey, targetService, operation,
pipedMexId));
+ }
+ return createNewMyRoleMex(template, meps);
}
}
@@ -185,13 +197,13 @@
* @throws BpelEngineException
*/
private MyRoleMessageExchange createNewMyRoleMex(BpelProcess target,
List<MyRoleMessageExchange> meps)
- throws BpelEngineException {
- MyRoleMessageExchangeImpl templateMex = (MyRoleMessageExchangeImpl) meps.get(0);
- MessageExchangeDAO templateMexDao = templateMex.getDAO();
- return new BrokeredMyRoleMessageExchangeImpl(target, this, meps, templateMexDao,
templateMex);
+ throws BpelEngineException {
+ MyRoleMessageExchangeImpl templateMex = (MyRoleMessageExchangeImpl) meps.get(0);
+ MessageExchangeDAO templateMexDao = templateMex.getDAO();
+ return new BrokeredMyRoleMessageExchangeImpl(target, this, meps, templateMexDao,
templateMex);
}
-
+
public MyRoleMessageExchange createMessageExchange(String clientKey, QName
targetService, String operation) {
return createMessageExchange(clientKey, targetService, operation, null);
}
@@ -200,7 +212,7 @@
MessageExchangeDAO mexdao =
_contexts.inMemDao.getConnection().getMessageExchange(mexId);
if (mexdao == null) mexdao =
_contexts.dao.getConnection().getMessageExchange(mexId);
if (mexdao != null)
- mexdao.setProcess(processDao);
+ mexdao.setProcess(processDao);
}
public MessageExchange getMessageExchange(String mexId) {
@@ -236,9 +248,9 @@
OPartnerLink plink = (OPartnerLink)
process.getOProcess().getChild(mexdao.getPartnerLinkModelId());
// the partner link might not be hydrated
if (plink != null) {
- PortType ptype = plink.myRolePortType;
- Operation op = plink.getMyRoleOperation(mexdao.getOperation());
- mex.setPortOp(ptype, op);
+ PortType ptype = plink.myRolePortType;
+ Operation op = plink.getMyRoleOperation(mexdao.getOperation());
+ mex.setPortOp(ptype, op);
}
}
break;
@@ -253,8 +265,8 @@
// enable extensibility
protected PartnerRoleMessageExchangeImpl createPartnerRoleMessageExchangeImpl(
- MessageExchangeDAO mexdao, PortType ptype, Operation op, OPartnerLink plink,
BpelProcess process) {
- return new PartnerRoleMessageExchangeImpl(this, mexdao, ptype, op, null,
plink.hasMyRole() ? process
+ MessageExchangeDAO mexdao, PortType ptype, Operation op, OPartnerLink plink,
BpelProcess process) {
+ return new PartnerRoleMessageExchangeImpl(this, mexdao, ptype, op, null,
plink.hasMyRole() ? process
.getInitialMyRoleEPR(plink) : null,
process.getPartnerRoleChannel(plink));
}
@@ -265,10 +277,9 @@
if (__log.isDebugEnabled())
__log.debug("Deactivating process " + p.getPID());
- Iterator<Map.Entry<Endpoint,List<BpelProcess>>> serviceIter
= _serviceMap.entrySet().iterator();
+ Iterator<List<BpelProcess>> serviceIter =
_serviceMap.values().iterator();
while (serviceIter.hasNext()) {
- Map.Entry<Endpoint,List<BpelProcess>> processEntry =
serviceIter.next();
- Iterator<BpelProcess> entryProcesses =
processEntry.getValue().iterator();
+ Iterator<BpelProcess> entryProcesses =
serviceIter.next().iterator();
while (entryProcesses.hasNext()) {
BpelProcess entryProcess = entryProcesses.next();
if (entryProcess.getPID().equals(process)) {
@@ -282,7 +293,7 @@
// release the resources held by this process
p.dehydrate();
// update the process footprints list
- _hydratedSizes.remove(p.getPID());
+ _hydratedSizes.remove(p.getPID());
}
return p;
}
@@ -292,7 +303,7 @@
}
public BpelProcess getProcess(QName pid) {
- return _activeProcesses.get(pid);
+ return _activeProcesses.get(pid);
}
/**
@@ -303,10 +314,10 @@
_activeProcesses.put(process.getPID(), process);
for (Endpoint e : process.getServiceNames()) {
__log.debug("Register process: serviceId=" + e + ",
process=" + process);
- List<BpelProcess> processes = _serviceMap.get(e);
+ List<BpelProcess> processes = _serviceMap.get(e.serviceName);
if (processes == null) {
- processes = new ArrayList<BpelProcess>();
- _serviceMap.put(e, processes);
+ processes = new ArrayList<BpelProcess>();
+ _serviceMap.put(e.serviceName, processes);
}
// Remove any older version of the process from the list
Iterator<BpelProcess> processesIter = processes.iterator();
@@ -314,8 +325,18 @@
BpelProcess cachedVersion = processesIter.next();
__log.debug("cached version " + cachedVersion.getPID() + "
vs registering version " + process.getPID());
if (cachedVersion.getProcessType().equals(process.getProcessType())) {
- processesIter.remove();
- cachedVersion.deactivate();
+ //Check for versions to retain newer one
+ if (cachedVersion.getVersion() > process.getVersion()) {
+ __log.debug("removing current version");
+ process.activate(this);
+ process.deactivate();
+ return;
+ } else {
+ __log.debug("removing cached older version");
+ processesIter.remove();
+ cachedVersion.deactivate();
+ }
+
}
}
processes.add(process);
@@ -336,12 +357,7 @@
List<BpelProcess> route(QName service, Message request) {
// TODO: use the message to route to the correct service if more than
// one service is listening on the same endpoint.
-
- List<BpelProcess> routed = null;
- for (Endpoint endpoint : _serviceMap.keySet()) {
- if (endpoint.serviceName.equals(service))
- routed = _serviceMap.get(endpoint);
- }
+ List<BpelProcess> routed = _serviceMap.get(service);
if (__log.isDebugEnabled())
__log.debug("Routed: svcQname " + service + " --> " +
routed);
return routed;
@@ -358,9 +374,9 @@
public void onScheduledJob(Scheduler.JobInfo jobInfo) throws
Scheduler.JobProcessorException {
final WorkEvent we = new WorkEvent(jobInfo.jobDetail);
- if( __log.isTraceEnabled() ) __log.trace("[JOB] onScheduledJob " + jobInfo
+ "" + we.getIID());
-
- // We lock the instance to prevent concurrent transactions and prevent unnecessary
rollbacks,
+ if( __log.isTraceEnabled() ) __log.trace("[JOB] onScheduledJob " +
jobInfo + "" + we.getIID());
+
+ // We lock the instance to prevent concurrent transactions and prevent
unnecessary rollbacks,
// Note that we don't want to wait too long here to get our lock, since we
are likely holding
// on to scheduler's locks of various sorts.
try {
@@ -377,10 +393,7 @@
throw new Scheduler.JobProcessorException(true);
} catch (org.apache.ode.bpel.engine.InstanceLockManager.TimeoutException e) {
__log.debug("Instance " + we.getIID() + " is busy,
rescheduling job.");
- // TODO: This should really be more of something like the exponential backoff
algorithm in ethernet.
- _contexts.scheduler.schedulePersistedJob(jobInfo.jobDetail, new
Date(System.currentTimeMillis()
- + Math.min(randomExp(1000), 10000)));
- return;
+ throw new Scheduler.JobProcessorException(true);
}
// DONT PUT CODE HERE-need this method real tight in a try/catch block, we need
to handle
// all types of failure here, the scheduler is not going to know how to handle
our errors,
@@ -411,54 +424,59 @@
return;
}
-
- if (we.getType().equals(WorkEvent.Type.INVOKE_CHECK)) {
- if (__log.isDebugEnabled()) __log.debug("handleWorkEvent:
InvokeCheck event for mexid " + we.getMexId());
-
- sendPartnerRoleFailure(we,
MessageExchange.FailureType.COMMUNICATION_ERROR);
- return;
- } else if (we.getType().equals(WorkEvent.Type.INVOKE_INTERNAL)) {
- if (__log.isDebugEnabled()) __log.debug("handleWorkEvent:
InvokeInternal event for mexid " + we.getMexId());
+ ClassLoader cl = Thread.currentThread().getContextClassLoader();
+ try {
+ Thread.currentThread().setContextClassLoader(process._classLoader);
+ if (we.getType().equals(WorkEvent.Type.INVOKE_CHECK)) {
+ if (__log.isDebugEnabled()) __log.debug("handleWorkEvent:
InvokeCheck event for mexid " + we.getMexId());
+
+ sendPartnerRoleFailure(we,
MessageExchange.FailureType.COMMUNICATION_ERROR);
+ return;
+ } else if (we.getType().equals(WorkEvent.Type.INVOKE_INTERNAL)) {
+ if (__log.isDebugEnabled()) __log.debug("handleWorkEvent:
InvokeInternal event for mexid " + we.getMexId());
- setMessageExchangeProcess(we.getMexId(), process.getProcessDAO());
- MyRoleMessageExchangeImpl mex = (MyRoleMessageExchangeImpl)
getMessageExchange(we.getMexId());
- if (!process.processInterceptors(mex,
InterceptorInvoker.__onJobScheduled)) {
- boolean isTwoWay =
Boolean.valueOf(mex.getProperty("isTwoWay"));
- if (isTwoWay) {
- String causeCodeValue = mex.getProperty("causeCode");
- mex.getDAO().setProcess(process.getProcessDAO());
- sendMyRoleFault(process, we, causeCodeValue != null ?
- Integer.valueOf(causeCodeValue) :
InvalidProcessException.DEFAULT_CAUSE_CODE);
- return;
- } else {
- throw new Scheduler.JobProcessorException(checkRetry(jobInfo,
null));
+ setMessageExchangeProcess(we.getMexId(), process.getProcessDAO());
+ MyRoleMessageExchangeImpl mex = (MyRoleMessageExchangeImpl)
getMessageExchange(we.getMexId());
+ if (!process.processInterceptors(mex,
InterceptorInvoker.__onJobScheduled)) {
+ boolean isTwoWay =
Boolean.valueOf(mex.getProperty("isTwoWay"));
+ if (isTwoWay) {
+ String causeCodeValue =
mex.getProperty("causeCode");
+ mex.getDAO().setProcess(process.getProcessDAO());
+ sendMyRoleFault(process, we, causeCodeValue != null ?
+ Integer.valueOf(causeCodeValue) :
InvalidProcessException.DEFAULT_CAUSE_CODE);
+ return;
+ } else {
+ throw new Scheduler.JobProcessorException(checkRetry(we));
+ }
}
}
+ process.handleWorkEvent(jobInfo.jobDetail);
+ debuggingDelay();
+ } finally {
+ Thread.currentThread().setContextClassLoader(cl);
}
-
- process.handleWorkEvent(jobInfo.jobDetail);
- debuggingDelay();
} catch (BpelEngineException bee) {
__log.error(__msgs.msgScheduledJobFailed(we.getDetail()), bee);
- throw new Scheduler.JobProcessorException(bee, checkRetry(jobInfo, bee));
+ throw new Scheduler.JobProcessorException(bee, checkRetry(we));
} catch (ContextException ce) {
__log.error(__msgs.msgScheduledJobFailed(we.getDetail()), ce);
- throw new Scheduler.JobProcessorException(ce, checkRetry(jobInfo, ce));
+ throw new Scheduler.JobProcessorException(ce, checkRetry(we));
} catch (InvalidProcessException ipe) {
__log.error(__msgs.msgScheduledJobFailed(we.getDetail()), ipe);
sendMyRoleFault(process, we, ipe.getCauseCode());
} catch (RuntimeException rte) {
__log.error(__msgs.msgScheduledJobFailed(we.getDetail()), rte);
- throw new Scheduler.JobProcessorException(rte, checkRetry(jobInfo, rte));
+ throw new Scheduler.JobProcessorException(rte, checkRetry(we));
} catch (Throwable t) {
__log.error(__msgs.msgScheduledJobFailed(we.getDetail()), t);
- throw new Scheduler.JobProcessorException(false);
+ throw new Scheduler.JobProcessorException(t, checkRetry(we));
}
}
- private boolean checkRetry(final JobInfo jobInfo, Throwable t) {
- __log.error("Job could not be completed after " + jobInfo.retryCount +
" retries: " + jobInfo, t);
- return jobInfo.jobDetail.get("inmem") == null;
+ private boolean checkRetry(WorkEvent we) {
+ // Only retry if the job is NOT in memory. Not that this does not guaranty that a
retry will be scheduled.
+ // Actually events are not retried if not persisted and the scheduler might
choose to discard the event if it has been retried too many times.
+ return !we.isInMem();
}
/**
@@ -490,7 +508,7 @@
// Note that the eventListeners list is a copy-on-write array, so need
// to mess with synchronization.
for (org.apache.ode.bpel.iapi.BpelEventListener l : _contexts.eventListeners) {
- l.onEvent(event);
+ l.onEvent(event);
}
}
@@ -503,173 +521,173 @@
return _contexts.globalInterceptors;
}
-
+
public void registerMessageExchangeInterceptor(MessageExchangeInterceptor
interceptor) {
- _contexts.globalInterceptors.add(interceptor);
+ _contexts.globalInterceptors.add(interceptor);
}
public void unregisterMessageExchangeInterceptor(MessageExchangeInterceptor
interceptor) {
- _contexts.globalInterceptors.remove(interceptor);
+ _contexts.globalInterceptors.remove(interceptor);
}
public void unregisterMessageExchangeInterceptor(Class interceptorClass) {
- MessageExchangeInterceptor candidate = null;
- for (MessageExchangeInterceptor interceptor : _contexts.globalInterceptors) {
- if (interceptor.getClass().isAssignableFrom(interceptorClass)) {
- candidate = interceptor;
- break;
- }
- }
- if (candidate != null) {
- _contexts.globalInterceptors.remove(candidate);
- }
+ MessageExchangeInterceptor candidate = null;
+ for (MessageExchangeInterceptor interceptor : _contexts.globalInterceptors) {
+ if (interceptor.getClass().isAssignableFrom(interceptorClass)) {
+ candidate = interceptor;
+ break;
+ }
+ }
+ if (candidate != null) {
+ _contexts.globalInterceptors.remove(candidate);
+ }
}
- public long getTotalBpelFootprint() {
- long bpelFootprint = 0;
- for (BpelProcess process : _activeProcesses.values()) {
- Long size = _hydratedSizes.get(process.getPID());
- if (size == null) {
- size = _unhydratedSizes.get(process.getPID());
- }
- if (size != null && size.longValue() > 0) {
- bpelFootprint += size;
- }
- }
- return bpelFootprint;
- }
+ public long getTotalBpelFootprint() {
+ long bpelFootprint = 0;
+ for (BpelProcess process : _activeProcesses.values()) {
+ Long size = _hydratedSizes.get(process.getPID());
+ if (size == null) {
+ size = _unhydratedSizes.get(process.getPID());
+ }
+ if (size != null && size.longValue() > 0) {
+ bpelFootprint += size;
+ }
+ }
+ return bpelFootprint;
+ }
- public long getHydratedFootprint() {
- long hydratedFootprint = 0;
- for (BpelProcess process : _activeProcesses.values()) {
- if (!process.hintIsHydrated()) {
- continue;
- }
- Long size = _hydratedSizes.get(process.getPID());
- if (size == null) {
- size = _unhydratedSizes.get(process.getPID());
- }
- if (size != null && size.longValue() > 0) {
- hydratedFootprint += size;
- }
- }
- return hydratedFootprint;
- }
-
- public long getHydratedProcessSize(QName processName) {
- return getHydratedProcessSize(_activeProcesses.get(processName));
- }
-
- private long getHydratedProcessSize(BpelProcess process) {
- long potentialGrowth = 0;
- if (!process.hintIsHydrated()) {
- Long mySize = _hydratedSizes.get(process.getPID());
- if (mySize == null) {
- mySize = _unhydratedSizes.get(process.getPID());
- }
- if (mySize != null && mySize.longValue() > 0) {
- potentialGrowth = mySize.longValue();
- }
- }
- return getHydratedProcessSize(potentialGrowth);
- }
-
- private long getHydratedProcessSize(long potentialGrowth) {
- long processMemory = (long)
- ((getHydratedFootprint() + potentialGrowth) *
- PROCESS_OVERHEAD_MEMORY_FACTOR);
- return processMemory;
- }
+ public long getHydratedFootprint() {
+ long hydratedFootprint = 0;
+ for (BpelProcess process : _activeProcesses.values()) {
+ if (!process.hintIsHydrated()) {
+ continue;
+ }
+ Long size = _hydratedSizes.get(process.getPID());
+ if (size == null) {
+ size = _unhydratedSizes.get(process.getPID());
+ }
+ if (size != null && size.longValue() > 0) {
+ hydratedFootprint += size;
+ }
+ }
+ return hydratedFootprint;
+ }
+
+ public long getHydratedProcessSize(QName processName) {
+ return getHydratedProcessSize(_activeProcesses.get(processName));
+ }
+
+ private long getHydratedProcessSize(BpelProcess process) {
+ long potentialGrowth = 0;
+ if (!process.hintIsHydrated()) {
+ Long mySize = _hydratedSizes.get(process.getPID());
+ if (mySize == null) {
+ mySize = _unhydratedSizes.get(process.getPID());
+ }
+ if (mySize != null && mySize.longValue() > 0) {
+ potentialGrowth = mySize.longValue();
+ }
+ }
+ return getHydratedProcessSize(potentialGrowth);
+ }
+
+ private long getHydratedProcessSize(long potentialGrowth) {
+ long processMemory = (long)
+ ((getHydratedFootprint() + potentialGrowth) *
+ PROCESS_OVERHEAD_MEMORY_FACTOR);
+ return processMemory;
+ }
- public int getHydratedProcessCount(QName processName) {
- int processCount = 0;
- for (BpelProcess process : _activeProcesses.values()) {
- if (process.hintIsHydrated() || process.getPID().equals(processName)) {
- processCount++;
- }
- }
- return processCount;
- }
+ public int getHydratedProcessCount(QName processName) {
+ int processCount = 0;
+ for (BpelProcess process : _activeProcesses.values()) {
+ if (process.hintIsHydrated() || process.getPID().equals(processName)) {
+ processCount++;
+ }
+ }
+ return processCount;
+ }
- private long _processThrottledMaximumSize = Long.MAX_VALUE;
- private int _processThrottledMaximumCount = Integer.MAX_VALUE;
- private int _instanceThrottledMaximumCount = Integer.MAX_VALUE;
- private boolean _hydrationThrottled = false;
+ private long _processThrottledMaximumSize = Long.MAX_VALUE;
+ private int _processThrottledMaximumCount = Integer.MAX_VALUE;
+ private int _instanceThrottledMaximumCount = Integer.MAX_VALUE;
+ private boolean _hydrationThrottled = false;
- public void setInstanceThrottledMaximumCount(
- int instanceThrottledMaximumCount) {
- this._instanceThrottledMaximumCount = instanceThrottledMaximumCount;
- }
-
- public int getInstanceThrottledMaximumCount() {
- return _instanceThrottledMaximumCount;
- }
-
- public void setProcessThrottledMaximumCount(
- int hydrationThrottledMaximumCount) {
- this._processThrottledMaximumCount = hydrationThrottledMaximumCount;
+ public void setInstanceThrottledMaximumCount(
+ int instanceThrottledMaximumCount) {
+ this._instanceThrottledMaximumCount = instanceThrottledMaximumCount;
+ }
+
+ public int getInstanceThrottledMaximumCount() {
+ return _instanceThrottledMaximumCount;
+ }
+
+ public void setProcessThrottledMaximumCount(
+ int hydrationThrottledMaximumCount) {
+ this._processThrottledMaximumCount = hydrationThrottledMaximumCount;
if (hydrationThrottledMaximumCount < Integer.MAX_VALUE) {
- registerMessageExchangeInterceptor(new ProcessCountThrottler());
+ registerMessageExchangeInterceptor(new ProcessCountThrottler());
} else {
- unregisterMessageExchangeInterceptor(ProcessCountThrottler.class);
+ unregisterMessageExchangeInterceptor(ProcessCountThrottler.class);
}
- }
-
- public int getProcessThrottledMaximumCount() {
- return _processThrottledMaximumCount;
- }
+ }
+
+ public int getProcessThrottledMaximumCount() {
+ return _processThrottledMaximumCount;
+ }
- public void setProcessThrottledMaximumSize(
- long hydrationThrottledMaximumSize) {
- this._processThrottledMaximumSize = hydrationThrottledMaximumSize;
+ public void setProcessThrottledMaximumSize(
+ long hydrationThrottledMaximumSize) {
+ this._processThrottledMaximumSize = hydrationThrottledMaximumSize;
if (hydrationThrottledMaximumSize < Long.MAX_VALUE) {
- registerMessageExchangeInterceptor(new ProcessSizeThrottler());
+ registerMessageExchangeInterceptor(new ProcessSizeThrottler());
} else {
- unregisterMessageExchangeInterceptor(ProcessSizeThrottler.class);
+ unregisterMessageExchangeInterceptor(ProcessSizeThrottler.class);
}
- }
+ }
- public long getProcessThrottledMaximumSize() {
- return _processThrottledMaximumSize;
- }
-
- public void setProcessSize(QName processId, boolean hydratedOnce) {
- BpelProcess process = _activeProcesses.get(processId);
- long processSize = process.sizeOf();
- if (hydratedOnce) {
+ public long getProcessThrottledMaximumSize() {
+ return _processThrottledMaximumSize;
+ }
+
+ public void setProcessSize(QName processId, boolean hydratedOnce) {
+ BpelProcess process = _activeProcesses.get(processId);
+ long processSize = process.sizeOf();
+ if (hydratedOnce) {
_hydratedSizes.put(process.getPID(), new Long(processSize));
_unhydratedSizes.remove(process.getPID());
- } else {
- _hydratedSizes.remove(process.getPID());
- _unhydratedSizes.put(process.getPID(), new Long(processSize));
- }
- }
+ } else {
+ _hydratedSizes.remove(process.getPID());
+ _unhydratedSizes.put(process.getPID(), new Long(processSize));
+ }
+ }
- /**
- * Returns true if the last used process was dehydrated because it was not in-use.
- */
- public boolean dehydrateLastUnusedProcess() {
- BpelProcess lastUnusedProcess = null;
- long lastUsedMinimum = Long.MAX_VALUE;
- for (BpelProcess process : _activeProcesses.values()) {
- if (process.hintIsHydrated()
- && process.getLastUsed() < lastUsedMinimum
- && process.getInstanceInUseCount() == 0) {
- lastUsedMinimum = process.getLastUsed();
- lastUnusedProcess = process;
- }
- }
- if (lastUnusedProcess != null) {
- lastUnusedProcess.dehydrate();
- return true;
- }
- return false;
- }
+ /**
+ * Returns true if the last used process was dehydrated because it was not in-use.
+ */
+ public boolean dehydrateLastUnusedProcess() {
+ BpelProcess lastUnusedProcess = null;
+ long lastUsedMinimum = Long.MAX_VALUE;
+ for (BpelProcess process : _activeProcesses.values()) {
+ if (process.hintIsHydrated()
+ && process.getLastUsed() < lastUsedMinimum
+ && process.getInstanceInUseCount() == 0) {
+ lastUsedMinimum = process.getLastUsed();
+ lastUnusedProcess = process;
+ }
+ }
+ if (lastUnusedProcess != null) {
+ lastUnusedProcess.dehydrate();
+ return true;
+ }
+ return false;
+ }
- public void sendMyRoleFault(BpelProcess process, WorkEvent we, int causeCode) {
- MessageExchange mex = (MessageExchange) getMessageExchange(we.getMexId());
+ public void sendMyRoleFault(BpelProcess process, WorkEvent we, int causeCode) {
+ MessageExchange mex = (MessageExchange) getMessageExchange(we.getMexId());
if (!(mex instanceof MyRoleMessageExchange)) {
- return;
+ return;
}
QName faultQName = null;
OConstants constants = process.getOProcess().constants;
@@ -713,18 +731,29 @@
}
MexDaoUtil.setFaulted((MessageExchangeImpl) mex, faultQName, faultElement);
}
- }
-
- private void sendPartnerRoleFailure(WorkEvent we, FailureType failureType) {
+ }
+
+ private void sendPartnerRoleFailure(WorkEvent we, FailureType failureType) {
MessageExchange mex = (MessageExchange) getMessageExchange(we.getMexId());
- if (mex instanceof PartnerRoleMessageExchange) {
- if (mex.getStatus() == MessageExchange.Status.ASYNC || mex.getStatus() ==
MessageExchange.Status.REQUEST) {
- String msg = "No response received for invoke (mexId=" +
we.getMexId() + "), forcing it into a failed state.";
- if (__log.isDebugEnabled()) __log.debug(msg);
- MexDaoUtil.setFailure((PartnerRoleMessageExchangeImpl) mex, failureType, msg, null);
- }
- }
- }
+ if (mex instanceof PartnerRoleMessageExchange) {
+ if (mex.getStatus() == MessageExchange.Status.ASYNC || mex.getStatus() ==
MessageExchange.Status.REQUEST) {
+ String msg = "No response received for invoke (mexId=" +
we.getMexId() + "), forcing it into a failed state.";
+ if (__log.isDebugEnabled()) __log.debug(msg);
+ MexDaoUtil.setFailure((PartnerRoleMessageExchangeImpl) mex, failureType,
msg, null);
+ }
+ }
+ }
+ public BpelProcess getNewestProcessByType(QName processType) {
+ int v = -1;
+ BpelProcess q = null;
+ for (BpelProcess p : _activeProcesses.values()) {
+ if (p.getProcessType().equals(processType) && v < p.getVersion())
{
+ v = p.getVersion();
+ q = p;
+ }
+ }
+ return q;
+ }
}
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/BpelProcess.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/BpelProcess.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/BpelProcess.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -113,6 +113,8 @@
private volatile long _lastUsed;
BpelEngineImpl _engine;
+ ClassLoader _classLoader = getClass().getClassLoader();
+
DebuggerSupport _debugger;
ExpressionLanguageRuntimeRegistry _expLangRuntimeRegistry;
private ReplacementMap _replacementMap;
@@ -196,12 +198,11 @@
return sb.toString();
}
- /**
- * Entry point for message exchanges aimed at the my role.
- *
- * @param mex
- */
- void invokeProcess(MyRoleMessageExchangeImpl mex) {
+ public interface InvokeHandler {
+ boolean invoke(PartnerLinkMyRoleImpl target, PartnerLinkMyRoleImpl.RoutingInfo
routingInfo, boolean createInstance);
+ }
+
+ public void invokeProcess(MyRoleMessageExchangeImpl mex, InvokeHandler invokeHandler)
{
boolean routed = false;
try {
@@ -232,15 +233,7 @@
if (mex.getStatus() != MessageExchange.Status.FAILURE) {
for (PartnerLinkMyRoleImpl.RoutingInfo routing : routings) {
- if (routing.messageRoute == null && createInstance) {
- // No route but we can create a new instance
- target.invokeNewInstance(mex, routing);
- routed = true;
- } else if (routing.messageRoute != null) {
- // Found a route, hitting it
- target.invokeInstance(mex, routing);
- routed = true;
- }
+ routed = routed || invokeHandler.invoke(target, routing,
createInstance);
}
}
if (routed) {
@@ -254,26 +247,48 @@
// we save the routing on the last myrole
// actually the message queue should be attached to the instance instead
of the correlator
targets.get(targets.size()-1).noRoutingMatch(mex, routings);
- }
+ } else {
+ // Now we have to update our message exchange status. If the
<reply> was not hit during the
+ // invocation, then we will be in the "REQUEST" phase which
means that either this was a one-way
+ // or a two-way that needs to delivery the reply asynchronously.
+ if (mex.getStatus() == MessageExchange.Status.REQUEST) {
+ mex.setStatus(MessageExchange.Status.ASYNC);
+ }
- // Now we have to update our message exchange status. If the <reply>
was not hit during the
- // invocation, then we will be in the "REQUEST" phase which means
that either this was a one-way
- // or a two-way that needs to delivery the reply asynchronously.
- if (mex.getStatus() == MessageExchange.Status.REQUEST) {
- mex.setStatus(MessageExchange.Status.ASYNC);
+ markused();
}
-
- markused();
} finally {
_hydrationLatch.release(1);
}
// For a one way, once the engine is done, the mex can be safely released.
// Sean: not really, if route is not found, we cannot delete the mex yet
- if (mex.getPattern().equals(MessageExchange.MessageExchangePattern.REQUEST_ONLY)
&& routed) {
+ if (mex.getPattern().equals(MessageExchange.MessageExchangePattern.REQUEST_ONLY)
&& routed &&
getCleanupCategories(false).contains(CLEANUP_CATEGORY.MESSAGES)) {
mex.release();
}
}
+
+ /**
+ * Entry point for message exchanges aimed at the my role.
+ *
+ * @param mex
+ */
+ void invokeProcess(final MyRoleMessageExchangeImpl mex) {
+ invokeProcess(mex, new InvokeHandler() {
+ public boolean invoke(PartnerLinkMyRoleImpl target,
PartnerLinkMyRoleImpl.RoutingInfo routing, boolean createInstance) {
+ if (routing.messageRoute == null && createInstance) {
+ // No route but we can create a new instance
+ target.invokeNewInstance(mex, routing);
+ return true;
+ } else if (routing.messageRoute != null) {
+ // Found a route, hitting it
+ target.invokeInstance(mex, routing);
+ return true;
+ }
+ return false;
+ }
+ });
+ }
/** Several myroles can use the same service in a given process */
private List<PartnerLinkMyRoleImpl> getMyRolesForService(QName serviceName) {
@@ -505,7 +520,7 @@
}
}
- protected ProcessDAO getProcessDAO() {
+ public ProcessDAO getProcessDAO() {
return _pconf.isTransient() ?
_engine._contexts.inMemDao.getConnection().getProcess(_pid) : getEngine()._contexts.dao
.getConnection().getProcess(_pid);
}
@@ -578,22 +593,27 @@
}
void deactivate() {
- // Deactivate all the my-role endpoints.
- for (Endpoint endpoint : _myEprs.keySet()) {
- // Deactivate the EPR only if there are no more references
- // to this endpoint from any (active) BPEL process.
- if (isShareable(endpoint)) {
- __log.debug("deactivating shared endpoint " + endpoint);
- if (!_sharedEps.decrementReferenceCount(endpoint)) {
+ // the BindingContext contains only the endpoints for the latest process version
+ if (org.apache.ode.bpel.iapi.ProcessState.ACTIVE.equals(_pconf.getState())) {
+ // Deactivate all the my-role endpoints.
+ for (Endpoint endpoint : _myEprs.keySet()) {
+ // Deactivate the EPR only if there are no more references
+ // to this endpoint from any (active) BPEL process.
+ if (isShareable(endpoint)) {
+ if(__log.isDebugEnabled()) __log.debug("deactivating shared
endpoint " + endpoint+ " for pid "+ _pid);
+ if (!_sharedEps.decrementReferenceCount(endpoint)) {
+
_engine._contexts.bindingContext.deactivateMyRoleEndpoint(endpoint);
+ _sharedEps.removeEndpoint(endpoint);
+ }
+ } else {
+ if(__log.isDebugEnabled()) __log.debug("deactivating non-shared
endpoint " + endpoint + " for pid "+ _pid);
_engine._contexts.bindingContext.deactivateMyRoleEndpoint(endpoint);
- _sharedEps.removeEndpoint(endpoint);
}
- } else {
- __log.debug("deactivating non-shared endpoint " + endpoint);
- _engine._contexts.bindingContext.deactivateMyRoleEndpoint(endpoint);
}
+ // TODO Deactivate all the partner-role channels
+ } else {
+ if(__log.isDebugEnabled()) __log.debug("pid "+_pid+" is not
ACTIVE, no endpoints to deactivate");
}
- // TODO Deactivate all the partner-role channels
}
private boolean isShareable(Endpoint endpoint) {
@@ -898,7 +918,7 @@
* exists and matches the GUID.
*/
if (isInMemory()) {
- createProcessDAO(_engine._contexts.inMemDao.getConnection(), _pid,
_pconf.getVersion(), _oprocess);
+ createProcessDAO(_engine._contexts.inMemDao.getConnection(), _pid,
_pconf.getVersion(), _oprocess);
} else if (_engine._contexts.scheduler.isTransacted()) {
// If we have a transaction, we do this in the current transaction
if(__log.isDebugEnabled()) __log.debug("Creating new process DAO for
" + _pid + " (guid=" + _oprocess.guid + ")...");
@@ -1082,20 +1102,36 @@
PROCESS_MEMORY_TO_SERIALIZED_SIZE_RATIO;
}
- public long getTimeout(OPartnerLink partnerLink) {
+ public long getTimeout(OPartnerLink partnerLink, boolean p2p) {
// OPartnerLink, PartnerLinkPartnerRoleImpl
final PartnerLinkPartnerRoleImpl linkPartnerRole =
_partnerRoles.get(partnerLink);
long timeout = Properties.DEFAULT_MEX_TIMEOUT;
- String timeout_property =
_pconf.getEndpointProperties(linkPartnerRole._initialEPR).get(Properties.PROP_MEX_TIMEOUT);
- if (timeout_property != null) {
- try {
- timeout = Long.parseLong(timeout_property);
- } catch (NumberFormatException e) {
- if (__log.isWarnEnabled())
- __log.warn("Mal-formatted Property: [" +
Properties.PROP_MEX_TIMEOUT + "=" + timeout_property + "] Default value
(" + timeout + ") will be used");
+ if (linkPartnerRole._initialEPR != null) {
+ String property = null;
+ String value = null;
+ Map<String, String> props =
_pconf.getEndpointProperties(linkPartnerRole._initialEPR);
+ if (p2p) {
+ property = Properties.PROP_P2P_MEX_TIMEOUT;
+ value = props.get(property);
}
+ if (value == null) {
+ property = Properties.PROP_MEX_TIMEOUT;
+ value = props.get(property);
+ }
+ if (value != null) {
+ try {
+ timeout = Long.parseLong(value);
+ } catch (NumberFormatException e) {
+ if (__log.isWarnEnabled())
+ __log.warn("Mal-formatted Property: [" + property +
"=" + value + "] Default value (" + timeout + ") will be
used");
+ }
+ }
}
return timeout;
}
+
+ public int getVersion() {
+ return
Integer.parseInt(_pid.getLocalPart().substring(_pid.getLocalPart().lastIndexOf('-')
+ 1));
+ }
}
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/BpelRuntimeContextImpl.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/BpelRuntimeContextImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/BpelRuntimeContextImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -21,10 +21,16 @@
import java.io.ByteArrayInputStream;
import java.io.ByteArrayOutputStream;
import java.net.URI;
-import java.util.*;
+import java.util.ArrayList;
+import java.util.Calendar;
+import java.util.Collection;
+import java.util.Date;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Set;
+import javax.wsdl.Fault;
import javax.wsdl.Operation;
-import javax.wsdl.OperationType;
import javax.xml.namespace.QName;
import org.apache.commons.logging.Log;
@@ -43,6 +49,8 @@
import org.apache.ode.bpel.dao.ProcessInstanceDAO;
import org.apache.ode.bpel.dao.ScopeDAO;
import org.apache.ode.bpel.dao.XmlDataDAO;
+import org.apache.ode.bpel.evar.ExternalVariableModuleException;
+import org.apache.ode.bpel.evar.ExternalVariableModule.Value;
import org.apache.ode.bpel.evt.CorrelationSetWriteEvent;
import org.apache.ode.bpel.evt.ProcessCompletionEvent;
import org.apache.ode.bpel.evt.ProcessInstanceEvent;
@@ -61,8 +69,12 @@
import org.apache.ode.bpel.iapi.Scheduler;
import org.apache.ode.bpel.iapi.MessageExchange.FailureType;
import org.apache.ode.bpel.iapi.MessageExchange.MessageExchangePattern;
+import org.apache.ode.bpel.iapi.MessageExchange.Status;
import org.apache.ode.bpel.iapi.ProcessConf.CLEANUP_CATEGORY;
+import org.apache.ode.bpel.iapi.ProcessConf.PartnerRoleConfig;
+import org.apache.ode.bpel.intercept.InterceptorInvoker;
import org.apache.ode.bpel.memdao.ProcessInstanceDaoImpl;
+import org.apache.ode.bpel.o.OFailureHandling;
import org.apache.ode.bpel.o.OMessageVarType;
import org.apache.ode.bpel.o.OPartnerLink;
import org.apache.ode.bpel.o.OProcess;
@@ -100,7 +112,7 @@
private static final Log __log = LogFactory.getLog(BpelRuntimeContextImpl.class);
/** Data-access object for process instance. */
- private ProcessInstanceDAO _dao;
+ protected ProcessInstanceDAO _dao;
/** Process Instance ID */
private final Long _iid;
@@ -113,10 +125,14 @@
private MyRoleMessageExchangeImpl _instantiatingMessageExchange;
- private OutstandingRequestManager _outstandingRequests;
+ protected OutstandingRequestManager _outstandingRequests;
- private BpelProcess _bpelProcess;
+ protected IMAManager _imaManager;
+ protected BpelProcess _bpelProcess;
+
+ private Date _currentEventDateTime;
+
/** Five second maximum for continous execution. */
private long _maxReductionTimeMs = 2000000;
@@ -131,14 +147,15 @@
_soup = new ExecutionQueueImpl(null);
_soup.setReplacementMap(_bpelProcess.getReplacementMap(dao.getProcess().getProcessId()));
- _outstandingRequests = new OutstandingRequestManager();
+ _outstandingRequests = null;
+ _imaManager = new IMAManager();
_vpu.setContext(_soup);
if (bpelProcess.isInMemory()) {
ProcessInstanceDaoImpl inmem = (ProcessInstanceDaoImpl) _dao;
if (inmem.getSoup() != null) {
_soup = (ExecutionQueueImpl) inmem.getSoup();
- _outstandingRequests = (OutstandingRequestManager)
_soup.getGlobalData();
+ _imaManager = (IMAManager) _soup.getGlobalData();
_vpu.setContext(_soup);
}
} else {
@@ -150,7 +167,7 @@
} catch (Exception ex) {
throw new RuntimeException(ex);
}
- _outstandingRequests = (OutstandingRequestManager)
_soup.getGlobalData();
+ _imaManager = (IMAManager) _soup.getGlobalData();
}
}
@@ -185,9 +202,9 @@
* @see
BpelRuntimeContext#isVariableInitialized(org.apache.ode.bpel.runtime.VariableInstance)
*/
public boolean isVariableInitialized(VariableInstance var) {
- if (var == null) {
- return false;
- }
+ if (var == null) {
+ return false;
+ }
ScopeDAO scopeDAO = _dao.getScope(var.scopeInstance);
XmlDataDAO dataDAO = scopeDAO.getVariable(var.declaration.name);
return !dataDAO.isNull();
@@ -226,7 +243,7 @@
public void afterCompletion(boolean success) {
}
public void beforeCompletion() {
- _dao.delete(_bpelProcess.getCleanupCategories(false));
+ _dao.delete(_bpelProcess.getCleanupCategories(false), false);
}
});
}
@@ -255,7 +272,7 @@
public void afterCompletion(boolean success) {
}
public void beforeCompletion() {
- _dao.delete(_bpelProcess.getCleanupCategories(true));
+ _dao.delete(_bpelProcess.getCleanupCategories(true), false);
}
});
}
@@ -331,13 +348,25 @@
correlators.add(processDao.getCorrelator(correlatorId));
}
- int conflict = _outstandingRequests.findConflict(selectors);
+ // Checking conflicts
+ int conflict = _imaManager.findConflict(selectors);
if (conflict != -1)
throw new
FaultException(_bpelProcess.getOProcess().constants.qnConflictingReceive,
selectors[conflict]
.toString());
- _outstandingRequests.register(pickResponseChannelStr, selectors);
+ // Check for ambiguous receive
+ for (int i = 0; i < selectors.length; ++i) {
+ CorrelatorDAO correlator = correlators.get(i);
+ Selector selector = selectors[i];
+ if (!correlator.checkRoute(selector.correlationKeySet)) {
+ throw new
FaultException(_bpelProcess.getOProcess().constants.qnAmbiguousReceive(),
selector.toString());
+ }
+ }
+
+ //Registering
+ _imaManager.register(pickResponseChannelStr, selectors);
+
// First check if we match to a new instance.
if (_instantiatingMessageExchange != null && _dao.getState() ==
ProcessState.STATE_READY) {
if (BpelProcess.__log.isDebugEnabled()) {
@@ -408,7 +437,7 @@
return
_bpelProcess.getInitialMyRoleEPR(pLink.partnerLink).toXML().getDocumentElement();
}
- private PartnerLinkDAO fetchPartnerLinkDAO(PartnerLinkInstance pLink) {
+ protected PartnerLinkDAO fetchPartnerLinkDAO(PartnerLinkInstance pLink) {
ScopeDAO scopeDAO = _dao.getScope(pLink.scopeInstanceId);
return scopeDAO.getPartnerLink(pLink.partnerLink.getId());
}
@@ -466,12 +495,12 @@
}
- public Node readVariable(Long scopeInstanceId, String varname, boolean forWriting)
throws FaultException {
- ScopeDAO scopedao = _dao.getScope(scopeInstanceId);
- XmlDataDAO var = scopedao.getVariable(varname);
- return (var == null || var.isNull()) ? null : var.get();
- }
-
+ public Node readVariable(Long scopeInstanceId, String varname, boolean forWriting)
throws FaultException {
+ ScopeDAO scopedao = _dao.getScope(scopeInstanceId);
+ XmlDataDAO var = scopedao.getVariable(varname);
+ return (var == null || var.isNull()) ? null : var.get();
+ }
+
public Node writeVariable(VariableInstance variable, Node changes) {
ScopeDAO scopeDAO = _dao.getScope(variable.scopeInstance);
XmlDataDAO dataDAO = scopeDAO.getVariable(variable.declaration.name);
@@ -482,17 +511,81 @@
}
public void cancelOutstandingRequests(String channelId) {
- _outstandingRequests.cancel(channelId);
+ _imaManager.cancel(channelId, false);
}
+
+ public void processOutstandingRequest(PartnerLinkInstance partnerLink, String opName,
String bpelMexId, String odeMexId) throws FaultException {
+ String mexRef = _imaManager.processOutstandingRequest(partnerLink, opName,
bpelMexId, odeMexId);
+ if (mexRef != null) {
+ reply2(partnerLink, opName, bpelMexId, null,
_bpelProcess.getOProcess().constants.qnConflictingRequest, false, mexRef);
+ throw new
FaultException(_bpelProcess.getOProcess().constants.qnConflictingRequest);
+ }
+ }
- public void reply(final PartnerLinkInstance plinkInstnace, final String opName, final
String mexId, Element msg,
- QName fault) throws FaultException {
- String mexRef = _outstandingRequests.release(plinkInstnace, opName, mexId);
+ protected void doAsyncReply(MyRoleMessageExchangeImpl m) {
+ MessageExchangeDAO mex = m.getDAO();
+ PartnerRoleMessageExchange pmex = null;
- if (mexRef == null) {
- throw new
FaultException(_bpelProcess.getOProcess().constants.qnMissingRequest);
+ if (mex.getPipedMessageExchangeId() != null) {
+ pmex = (PartnerRoleMessageExchange) _bpelProcess
+ .getEngine().getMessageExchange(mex.getPipedMessageExchangeId());
}
+ if (pmex != null) {
+ if (BpelProcess.__log.isDebugEnabled()) {
+ __log.debug("Replying to a p2p mex, myrole " + m + " -
partnerole " + pmex);
+ }
+
+ if (pmex.getStatus() == Status.ASYNC || pmex.getStatus() == Status.REQUEST)
{
+ try {
+ switch (m.getStatus()) {
+ case FAILURE:
+ // We can't seem to get the failure out of the myrole
mex?
+ pmex.replyWithFailure(MessageExchange.FailureType.OTHER,
"operation failed", null);
+ break;
+ case FAULT:
+ Fault fault =
pmex.getOperation().getFault(m.getFault().getLocalPart());
+ if (fault == null) {
+ __log.error("process " + _bpelProcess + "
instance " + _iid + " thrown unmapped fault in p2p communication " +
m.getFault() + " " + m.getFaultExplanation() + " - converted to
failure");
+ pmex.replyWithFailure(MessageExchange.FailureType.OTHER,
"process thrown unmapped fault in p2p communication " + m.getFault() + "
" + m.getFaultExplanation() + " - converted to failure",
m.getFaultResponse().getMessage());
+ } else {
+ Message faultRes =
pmex.createMessage(pmex.getOperation().getFault(m.getFault().getLocalPart())
+ .getMessage().getQName());
+ faultRes.setMessage(m.getResponse().getMessage());
+ pmex.replyWithFault(m.getFault(), faultRes);
+ }
+ break;
+ case RESPONSE:
+ Message response =
pmex.createMessage(pmex.getOperation().getOutput().getMessage().getQName());
+ response.setMessage(m.getResponse().getMessage());
+ pmex.reply(response);
+ break;
+ default:
+ __log.warn("Unexpected state: " + m.getStatus());
+ break;
+ }
+ } finally {
+ mex.release(_bpelProcess.isCleanupCategoryEnabled(m.getStatus() ==
MessageExchange.Status.RESPONSE, CLEANUP_CATEGORY.MESSAGES));
+ }
+ } else {
+ __log.warn("Can't send response to a p2p mex: " + mex +
" partner mex: " + pmex);
+ }
+ } else {
+ checkInvokeExternalPermission();
+ _bpelProcess._engine._contexts.mexContext.onAsyncReply(m);
+ //mex.release(_bpelProcess.isCleanupCategoryEnabled(m.getStatus() ==
MessageExchange.Status.RESPONSE, CLEANUP_CATEGORY.MESSAGES));
+ }
+ }
+
+ public void reply(final PartnerLinkInstance plinkInstnace, final String opName, final
String mexId, Element msg,
+ QName fault) throws FaultException {
+ String mexRef = _imaManager.release(plinkInstnace, opName, mexId);
+ reply2(plinkInstnace, opName, mexId, msg, fault, false, mexRef);
+ }
+
+ public void reply2(final PartnerLinkInstance plinkInstnace, final String opName,
final String mexId, Element msg,
+ QName fault, boolean failure, final String mexRef) throws
FaultException {
+
// prepare event
ProcessMessageExchangeEvent evt = new ProcessMessageExchangeEvent();
evt.setMexId(mexId);
@@ -509,7 +602,9 @@
_bpelProcess.initMyRoleMex(m);
m.setResponse(new MessageImpl(message));
- if (fault != null) {
+ if (failure) {
+ mex.setStatus(MessageExchange.Status.FAILURE.toString());
+ } else if (fault != null) {
mex.setStatus(MessageExchange.Status.FAULT.toString());
mex.setFault(fault);
evt.setAspect(ProcessMessageExchangeEvent.PROCESS_FAULT);
@@ -518,37 +613,7 @@
evt.setAspect(ProcessMessageExchangeEvent.PROCESS_OUTPUT);
}
- if (mex.getPipedMessageExchangeId() != null) {
- PartnerRoleMessageExchange pmex = (PartnerRoleMessageExchange) _bpelProcess
- .getEngine().getMessageExchange(mex.getPipedMessageExchangeId());
- if (BpelProcess.__log.isDebugEnabled()) {
- __log.debug("Replying to a p2p mex, myrole " + m + " -
partnerole " + pmex);
- }
- try {
- switch (m.getStatus()) {
- case FAILURE:
- // We can't seem to get the failure out of the myrole mex?
- pmex.replyWithFailure(MessageExchange.FailureType.OTHER,
"operation failed", null);
- break;
- case FAULT:
- Message faultRes =
pmex.createMessage(pmex.getOperation().getFault(m.getFault().getLocalPart())
- .getMessage().getQName());
- faultRes.setMessage(m.getResponse().getMessage());
- pmex.replyWithFault(m.getFault(), faultRes);
- break;
- case RESPONSE:
- Message response =
pmex.createMessage(pmex.getOperation().getOutput().getMessage().getQName());
- response.setMessage(m.getResponse().getMessage());
- pmex.reply(response);
- break;
- default:
- __log.warn("Unexpected state: " + m.getStatus());
- break;
- }
- } finally {
- mex.release(_bpelProcess.isCleanupCategoryEnabled(m.getStatus() ==
MessageExchange.Status.RESPONSE, CLEANUP_CATEGORY.MESSAGES));
- }
- } else _bpelProcess._engine._contexts.mexContext.onAsyncReply(m);
+ doAsyncReply(m);
// send event
sendEvent(evt);
@@ -638,7 +703,11 @@
we.setChannel(timerChannel.export());
we.setType(WorkEvent.Type.TIMER);
we.setInMem(_bpelProcess.isInMemory());
- _bpelProcess._engine._contexts.scheduler.schedulePersistedJob(we.getDetail(),
timeToFire);
+ if(_bpelProcess.isInMemory()){
+ _bpelProcess._engine._contexts.scheduler.scheduleVolatileJob(true,
we.getDetail(), timeToFire);
+ }else{
+ _bpelProcess._engine._contexts.scheduler.schedulePersistedJob(we.getDetail(),
timeToFire);
+ }
}
private void scheduleCorrelatorMatcher(String correlatorId, CorrelationKeySet keySet)
{
@@ -648,9 +717,15 @@
we.setCorrelatorId(correlatorId);
we.setCorrelationKeySet(keySet);
we.setInMem(_bpelProcess.isInMemory());
- _bpelProcess._engine._contexts.scheduler.scheduleVolatileJob(true,
we.getDetail());
+ if(_bpelProcess.isInMemory()){
+ _bpelProcess._engine._contexts.scheduler.scheduleVolatileJob(true,
we.getDetail());
+ }else{
+ _bpelProcess._engine._contexts.scheduler.schedulePersistedJob(we.getDetail(),
null);
+ }
}
+ public void checkInvokeExternalPermission() {}
+
/**
* Called back when the process executes an invokation.
*
@@ -695,6 +770,7 @@
MessageExchangeDAO mexDao = _dao.getConnection().createMessageExchange(
MessageExchangeDAO.DIR_BPEL_INVOKES_PARTNERROLE);
+ mexDao.setCreateTime(getCurrentEventDateTime());
mexDao.setStatus(MessageExchange.Status.NEW.toString());
mexDao.setOperation(operation.getName());
mexDao.setPortType(partnerLink.partnerLink.partnerRolePortType.getQName());
@@ -728,14 +804,14 @@
EndpointReference myRoleEndpoint = partnerLink.partnerLink.hasMyRole() ?
_bpelProcess
.getInitialMyRoleEPR(partnerLink.partnerLink) : null;
PartnerRoleMessageExchangeImpl mex =
- createPartnerRoleMessageExchangeImpl(mexDao, partnerLink,
- operation, partnerEpr, myRoleEndpoint);
+ createPartnerRoleMessageExchangeImpl(mexDao, partnerLink,
+ operation, partnerEpr, myRoleEndpoint);
mex.setProperty("activityId", ""+aid);
List<BpelProcess> p2pProcesses = null;
Endpoint partnerEndpoint =
_bpelProcess.getInitialPartnerRoleEndpoint(partnerLink.partnerLink);
- if (partnerEndpoint != null)
+ if (getConfigForPartnerLink(partnerLink.partnerLink).usePeer2Peer &&
partnerEndpoint != null)
p2pProcesses = _bpelProcess.getEngine().route(partnerEndpoint.serviceName,
mex.getRequest());
if (p2pProcesses != null && !p2pProcesses.isEmpty()) {
@@ -745,7 +821,7 @@
operation.getName(), mex.getMessageExchangeId());
if (myRoleMex instanceof BrokeredMyRoleMessageExchangeImpl) {
- mex.setSubscriberCount(((BrokeredMyRoleMessageExchangeImpl)
myRoleMex).getSubscriberCount());
+ mex.setSubscriberCount(((BrokeredMyRoleMessageExchangeImpl)
myRoleMex).getSubscriberCount());
}
if (BpelProcess.__log.isDebugEnabled()) {
@@ -769,15 +845,17 @@
myRoleMex.invoke(odeRequest);
// Can't expect any sync response
+ scheduleInvokeCheck(mex, partnerLink.partnerLink, true);
mex.replyAsync();
} else {
// If we couldn't find the endpoint, then there is no sense
// in asking the IL to invoke.
if (partnerEpr != null) {
+ checkInvokeExternalPermission();
mexDao.setEPR(partnerEpr.toXML().getDocumentElement());
mex.setStatus(MessageExchange.Status.REQUEST);
// Assuming an unreliable protocol, we schedule a task to check if
recovery mode will be needed
- scheduleInvokeCheck(mex, partnerLink.partnerLink);
+ scheduleInvokeCheck(mex, partnerLink.partnerLink, false);
_bpelProcess._engine._contexts.mexContext.invokePartner(mex);
} else {
__log.error("Couldn't find endpoint for partner EPR " +
DOMUtils.domToString(partnerEPR));
@@ -818,18 +896,18 @@
// enable extensibility
protected PartnerRoleMessageExchangeImpl
createPartnerRoleMessageExchangeImpl(MessageExchangeDAO mexDao,
- PartnerLinkInstance partnerLink, Operation operation, EndpointReference
partnerEpr,
- EndpointReference myRoleEndpoint) {
- return new PartnerRoleMessageExchangeImpl(getBpelProcess().getEngine(), mexDao,
+ PartnerLinkInstance partnerLink, Operation operation, EndpointReference
partnerEpr,
+ EndpointReference myRoleEndpoint) {
+ return new PartnerRoleMessageExchangeImpl(getBpelProcess().getEngine(), mexDao,
partnerLink.partnerLink.partnerRolePortType, operation, partnerEpr,
myRoleEndpoint,
getBpelProcess().getPartnerRoleChannel(partnerLink.partnerLink));
}
protected BpelProcess getBpelProcess() {
- return _bpelProcess;
+ return _bpelProcess;
}
- private void scheduleInvokeCheck(PartnerRoleMessageExchangeImpl mex, OPartnerLink
partnerLink) {
+ private void scheduleInvokeCheck(PartnerRoleMessageExchangeImpl mex, OPartnerLink
partnerLink, boolean p2p) {
boolean isTwoWay = mex.getMessageExchangePattern() ==
org.apache.ode.bpel.iapi.MessageExchange.MessageExchangePattern.REQUEST_RESPONSE;
if (!_bpelProcess.isInMemory() && isTwoWay) {
@@ -839,7 +917,7 @@
event.setInMem(false);
event.setType(WorkEvent.Type.INVOKE_CHECK);
// use a greater timeout to make sure the check job does not get executed
while the service invocation is still waiting for a response
- final long timeout = (long) (getBpelProcess().getTimeout(partnerLink)*1.5);
+ long timeout = getBpelProcess().getTimeout(partnerLink, p2p);
if (__log.isDebugEnabled()) __log.debug("Creating invocation check event
in "+timeout+"ms for mexid " + mex.getMessageExchangeId());
Date future = new Date(System.currentTimeMillis() + timeout);
String jobId =
_bpelProcess._engine._contexts.scheduler.schedulePersistedJob(event.getDetail(), future);
@@ -847,7 +925,7 @@
}
}
- private void buildOutgoingMessage(MessageDAO message, Element outgoingElmt) {
+ protected void buildOutgoingMessage(MessageDAO message, Element outgoingElmt) {
if (outgoingElmt == null) return;
Document doc = DOMUtils.newDocument();
@@ -868,16 +946,17 @@
message.setHeader(header);
}
- void execute() {
+ public void execute() {
long maxTime = System.currentTimeMillis() + _maxReductionTimeMs;
boolean canReduce = true;
+ assert _outstandingRequests == null && _imaManager != null;
while (ProcessState.canExecute(_dao.getState()) &&
System.currentTimeMillis() < maxTime && canReduce) {
canReduce = _vpu.execute();
}
_dao.setLastActiveTime(new Date());
if (!ProcessState.isFinished(_dao.getState())) {
if (__log.isDebugEnabled()) __log.debug("Setting execution state on
instance " + _iid);
- _soup.setGlobalData(_outstandingRequests);
+ _soup.setGlobalData(_imaManager);
if (_bpelProcess.isInMemory()) {
// don't serialize in-memory processes
@@ -914,7 +993,7 @@
}
}
- void inputMsgMatch(final String responsechannel, final int idx,
MyRoleMessageExchangeImpl mex) {
+ public void inputMsgMatch(final String responsechannel, final int idx,
MyRoleMessageExchangeImpl mex) {
// if we have a message match, this instance should be marked
// active if it isn't already
if (_dao.getState() == ProcessState.STATE_READY) {
@@ -931,8 +1010,6 @@
sendEvent(evt);
}
- _outstandingRequests.associate(responsechannel, mex.getMessageExchangeId());
-
final String mexId = mex.getMessageExchangeId();
_vpu.inject(new JacobRunnable() {
private static final long serialVersionUID = 3168964409165899533L;
@@ -944,11 +1021,11 @@
});
}
- void timerEvent(final String timerResponseChannel) {
+ protected void timerEvent(final String timerResponseChannel) {
// In case this is a pick event, we remove routes,
// and cancel the outstanding requests.
_dao.getProcess().removeRoutes(timerResponseChannel, _dao);
- _outstandingRequests.cancel(timerResponseChannel);
+ _imaManager.cancel(timerResponseChannel, true);
// Ignore timer events after the process is finished.
if (ProcessState.isFinished(_dao.getState())) {
@@ -971,7 +1048,7 @@
// receive/reply association.
final String id = timerResponseChannel.export();
_dao.getProcess().removeRoutes(id, _dao);
- _outstandingRequests.cancel(id);
+ _imaManager.cancel(id, true);
_vpu.inject(new JacobRunnable() {
private static final long serialVersionUID = 6157913683737696396L;
@@ -987,7 +1064,7 @@
invocationResponse(mex.getDAO().getMessageExchangeId(),
mex.getDAO().getChannel());
}
- void invocationResponse(final String mexid, final String responseChannelId) {
+ public void invocationResponse(final String mexid, final String responseChannelId) {
if (responseChannelId == null)
throw new NullPointerException("Null responseChannelId");
if (mexid == null)
@@ -1090,7 +1167,7 @@
}
private void completeOutstandingMessageExchanges() {
- String[] mexRefs = _outstandingRequests.releaseAll();
+ String[] mexRefs = _imaManager.releaseAll();
for (String mexId : mexRefs) {
MessageExchangeDAO mexDao = _dao.getConnection().getMessageExchange(mexId);
if (mexDao != null) {
@@ -1107,15 +1184,14 @@
}
default:
mex.setFailure(FailureType.OTHER, "No response.",
null);
- _bpelProcess._engine._contexts.mexContext.onAsyncReply(mex);
- mex.release(_bpelProcess.isCleanupCategoryEnabled(true,
CLEANUP_CATEGORY.MESSAGES));
+ doAsyncReply(mex);
}
}
}
}
private void faultOutstandingMessageExchanges(FaultData faultData) {
- String[] mexRefs = _outstandingRequests.releaseAll();
+ String[] mexRefs = _imaManager.releaseAll();
for (String mexId : mexRefs) {
MessageExchangeDAO mexDao = _dao.getConnection().getMessageExchange(mexId);
if (mexDao != null) {
@@ -1129,20 +1205,20 @@
mex.setFault(faultData.getFaultName(), message);
mex.setFaultExplanation(faultData.getExplanation());
- _bpelProcess._engine._contexts.mexContext.onAsyncReply(mex);
+ doAsyncReply(mex);
}
}
}
private void failOutstandingMessageExchanges() {
- String[] mexRefs = _outstandingRequests.releaseAll();
+ String[] mexRefs = _imaManager.releaseAll();
for (String mexId : mexRefs) {
MessageExchangeDAO mexDao = _dao.getConnection().getMessageExchange(mexId);
if (mexDao != null) {
MyRoleMessageExchangeImpl mex = new
MyRoleMessageExchangeImpl(_bpelProcess, _bpelProcess._engine, mexDao);
_bpelProcess.initMyRoleMex(mex);
mex.setFailure(FailureType.OTHER, "No response.", null);
- _bpelProcess._engine._contexts.mexContext.onAsyncReply(mex);
+ doAsyncReply(mex);
}
}
}
@@ -1172,7 +1248,7 @@
case ASYNC:
case REQUEST:
// In the case of pub-sub, the status may already be OK.
- case COMPLETED_OK:
+ case COMPLETED_OK:
MessageDAO request = dao.getRequest();
if (request == null) {
// this also should not happen
@@ -1271,10 +1347,14 @@
MessageExchangeDAO dao = _dao.getConnection().getMessageExchange(mexId);
dao.release(_bpelProcess.isCleanupCategoryEnabled(instanceSucceeded,
CLEANUP_CATEGORY.MESSAGES) );
- // Canceling invocation check job
+ // We used to cancel the invoke check job here but it turns out
+ // it creates more contention on the ODE_JOB table. It's better
+ // just to let the job get scheduled and discarded quietly
+ /*
String jobId = dao.getProperty("invokeCheckJobId");
if (jobId != null)
_bpelProcess._engine._contexts.scheduler.cancelJob(jobId);
+ */
}
@@ -1307,18 +1387,6 @@
__log.info("ActivityRecovery: Registering activity " + activityId +
", failure reason: " + reason +
" on channel " + channel.export());
_dao.createActivityRecovery(channel.export(), (int) activityId, reason, dateTime,
details, actions, retries);
- // Release and fail any outstanding request
- String[] mexRefs = _outstandingRequests.releaseAll();
- if(mexRefs!=null){
- for(String mexRef:mexRefs){
- MessageExchangeDAO mexDao =
_dao.getConnection().getMessageExchange(mexRef);
- if (mexDao !=null) {
- MyRoleMessageExchangeImpl mex = new
MyRoleMessageExchangeImpl(_bpelProcess, _bpelProcess._engine, mexDao);
- _bpelProcess.initMyRoleMex(mex);
- mex.setFailure(FailureType.OTHER, reason, details);
- }
- }
- }
}
public void unregisterActivityForRecovery(ActivityRecoveryChannel channel) {
@@ -1397,57 +1465,82 @@
Set<String> groupIds = new HashSet<String>();
for (MessageRouteDAO mroute : mroutes) {
- // We have a match, so we can get rid of the routing entries.
- groupIds.add(mroute.getGroupId());
-
- // Found message matching one of our selectors.
- if (BpelProcess.__log.isDebugEnabled()) {
- BpelProcess.__log.debug("SELECT: " + mroute.getGroupId() +
": matched to MESSAGE " + mexdao
- + " on CKEYSET " + ckeySet);
- }
-
- MyRoleMessageExchangeImpl mex = new MyRoleMessageExchangeImpl(_bpelProcess,
_bpelProcess._engine, mexdao);
-
- inputMsgMatch(mroute.getGroupId(), mroute.getIndex(), mex);
- execute();
+ // We have a match, so we can get rid of the routing entries.
+ groupIds.add(mroute.getGroupId());
+
+ // Found message matching one of our selectors.
+ if (BpelProcess.__log.isDebugEnabled()) {
+ BpelProcess.__log.debug("SELECT: " + mroute.getGroupId() +
": matched to MESSAGE " + mexdao
+ + " on CKEYSET " + ckeySet);
+ }
+
+ MyRoleMessageExchangeImpl mex = new
MyRoleMessageExchangeImpl(_bpelProcess, _bpelProcess._engine, mexdao);
+
+ inputMsgMatch(mroute.getGroupId(), mroute.getIndex(), mex);
+ execute();
}
for (String groupId : groupIds) {
- correlator.removeRoutes(groupId, _dao);
+ correlator.removeRoutes(groupId, _dao);
}
// Do not release yet if the process is suspended, the mex will be used
again
if (_dao.getState() != ProcessState.STATE_SUSPENDED)
- mexdao.releasePremieMessages();
+ mexdao.releasePremieMessages();
} else {
__log.debug("MatcherEvent handling: nothing to do, no matching message
in DB");
}
}
- public Node readExtVar(Variable variable, Node reference) throws
ExternalVariableModuleException {
- Value val = _bpelProcess.getEVM().read(variable, reference, _iid);
- return val.value;
- }
+ public Node readExtVar(Variable variable, Node reference) throws
ExternalVariableModuleException {
+ Value val = _bpelProcess.getEVM().read(variable, reference, _iid);
+ return val.value;
+ }
- public ValueReferencePair writeExtVar(Variable variable, Node reference, Node value)
throws ExternalVariableModuleException {
- ValueReferencePair vrp = new ValueReferencePair();
-
- Value val = _bpelProcess.getEVM().write(variable, reference, value, _iid);
- vrp.reference = val.locator.reference;
- vrp.value = val.value;
-
- return vrp;
- }
+ public ValueReferencePair writeExtVar(Variable variable, Node reference, Node value)
throws ExternalVariableModuleException {
+ ValueReferencePair vrp = new ValueReferencePair();
+
+ Value val = _bpelProcess.getEVM().write(variable, reference, value, _iid);
+ vrp.reference = val.locator.reference;
+ vrp.value = val.value;
+
+ return vrp;
+ }
- public URI getBaseResourceURI() {
- return _bpelProcess.getBaseResourceURI();
- }
-
- public Node getProcessProperty(QName propertyName) {
- return _bpelProcess.getProcessProperty(propertyName);
- }
+ public URI getBaseResourceURI() {
+ return _bpelProcess.getBaseResourceURI();
+ }
+
+ public Node getProcessProperty(QName propertyName) {
+ return _bpelProcess.getProcessProperty(propertyName);
+ }
- public QName getProcessQName() {
- return _bpelProcess.getProcessType();
- }
+ public QName getProcessQName() {
+ return _bpelProcess.getProcessType();
+ }
+
+ public Date getCurrentEventDateTime() {
+ if (_currentEventDateTime == null)
+ return Calendar.getInstance().getTime();
+ else
+ return _currentEventDateTime;
+ }
+
+ public void setCurrentEventDateTime(Date eventDateTime) {
+ _currentEventDateTime = eventDateTime;
+ }
+
+ public ClassLoader getProcessClassLoader() {
+ return _bpelProcess._classLoader;
+ }
+
+ public PartnerRoleConfig getConfigForPartnerLink(OPartnerLink pLink) {
+ PartnerRoleConfig c =
_bpelProcess.getConf().getPartnerRoleConfig().get(pLink.name);
+ if (c == null) {
+ return new PartnerRoleConfig(null, true);
+ } else {
+ return c;
+ }
+ }
+
}
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/BpelServerImpl.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/BpelServerImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/BpelServerImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -27,6 +27,7 @@
import java.util.Properties;
import java.util.Set;
import java.util.concurrent.ExecutorService;
+import java.util.concurrent.TimeUnit;
import java.util.concurrent.locks.ReadWriteLock;
import java.util.concurrent.locks.ReentrantReadWriteLock;
@@ -106,6 +107,8 @@
private DehydrationPolicy _dehydrationPolicy;
private boolean _hydrationLazy;
private int _hydrationLazyMinimumSize;
+ private int _migrationTransactionTimeout;
+ private Thread processDefReaper;
BpelEngineImpl _engine;
protected BpelDatabase _db;
@@ -155,15 +158,16 @@
__log.debug("BPEL SERVER starting.");
// Eventually running some migrations before starting
- new MigrationHandler(_contexts).migrate(_registeredProcesses);
+ if (!(new MigrationHandler(_contexts).migrate(_registeredProcesses,
_migrationTransactionTimeout))) {
+ throw new RuntimeException("An error occurred while migrating your
database to a newer version of the server. Please make sure that the required migration
scripts have been executed before starting the server.");
+ }
_state = State.RUNNING;
__log.info(__msgs.msgServerStarted());
if (_dehydrationPolicy != null) {
- Thread thread = new Thread(new ProcessDefReaper(),
"Dehydrator");
- thread.setDaemon(true);
- thread.start();
-
+ processDefReaper = new Thread(new ProcessDefReaper(),
"Dehydrator");
+ processDefReaper.setDaemon(true);
+ processDefReaper.start();
}
} finally {
_mngmtLock.writeLock().unlock();
@@ -217,6 +221,10 @@
__log.debug("BPEL SERVER STOPPING");
+ if (processDefReaper != null) {
+ processDefReaper.interrupt();
+ processDefReaper = null;
+ }
_contexts.scheduler.stop();
_engine = null;
_state = State.INIT;
@@ -308,6 +316,7 @@
__log.debug("Registering process " + conf.getProcessId() + "
with server.");
BpelProcess process = createBpelProcess(conf);
+ process._classLoader = Thread.currentThread().getContextClassLoader();
_engine.registerProcess(process);
_registeredProcesses.add(process);
@@ -448,7 +457,7 @@
try {
while (true) {
Thread.sleep(pollingTime);
- _mngmtLock.writeLock().lockInterruptibly();
+ if (!_mngmtLock.writeLock().tryLock(100L, TimeUnit.MILLISECONDS))
continue;
try {
__log.debug("Kicking reaper, OProcess instances: " +
OProcess.instanceCount);
// Copying the runnning process list to avoid synchronization
@@ -473,7 +482,7 @@
}
}
} catch (InterruptedException e) {
- __log.info(e);
+ __log.debug(e);
}
}
}
@@ -670,4 +679,8 @@
deleteProcessDAO(pconf.getProcessId(), pconf.isTransient());
}
}
+
+ public void setMigrationTransactionTimeout(int migrationTransactionTimeout) {
+ this._migrationTransactionTimeout = migrationTransactionTimeout;
+ }
}
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/BrokeredMyRoleMessageExchangeImpl.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/BrokeredMyRoleMessageExchangeImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/BrokeredMyRoleMessageExchangeImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -25,11 +25,15 @@
import java.util.concurrent.TimeUnit;
import java.util.concurrent.TimeoutException;
+import javax.wsdl.Operation;
+import javax.wsdl.PortType;
+
import org.apache.ode.bpel.dao.MessageExchangeDAO;
import org.apache.ode.bpel.iapi.BpelEngineException;
import org.apache.ode.bpel.iapi.EndpointReference;
import org.apache.ode.bpel.iapi.Message;
import org.apache.ode.bpel.iapi.MyRoleMessageExchange;
+import org.apache.ode.bpel.iapi.ProcessState;
/**
@@ -65,10 +69,13 @@
public Future invoke(Message request) {
Future myFuture = null;
for (MyRoleMessageExchange subscriber : subscribers) {
- Future theirFuture = subscriber.invoke(request);
- if (subscriber == template) {
- myFuture = theirFuture;
- }
+ BpelProcess process = ((MyRoleMessageExchangeImpl) subscriber)._process;
+ if (process.getConf().getState() == ProcessState.ACTIVE) {
+ Future theirFuture = subscriber.invoke(request);
+ if (myFuture == null) {
+ myFuture = theirFuture;
+ }
+ }
}
return myFuture;
}
@@ -116,4 +123,14 @@
((MyRoleMessageExchangeImpl) subscriber).setSubscriberCount(subscriberCount);
}
}
+
+ @Override
+ public PortType getPortType() {
+ return template.getPortType();
+ }
+
+ @Override
+ public Operation getOperation() {
+ return template.getOperation();
+ }
}
Added:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/IMAManager.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/IMAManager.java
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/IMAManager.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,291 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.ode.bpel.engine;
+
+import org.apache.ode.bpel.runtime.PartnerLinkInstance;
+import org.apache.ode.bpel.runtime.Selector;
+import org.apache.ode.utils.ObjectPrinter;
+
+import java.io.Serializable;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.Map;
+import java.util.Set;
+
+import javax.wsdl.OperationType;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+/**
+ * <p>
+ * This class handles behaviour of IMAs (Inbound Message Activities) as specified in WS
BPEL.
+ * This includes detecting conflictingReceive and conflictingRequest faults.
+ * </p>
+ */
+public class IMAManager implements Serializable {
+ private static final long serialVersionUID = -5556374398943757951L;
+
+ private static final Log __log = LogFactory.getLog(IMAManager.class);
+
+ // holds rid for registered IMAs
+ public final Map<RequestIdTuple, Entry> _byRid = new HashMap<RequestIdTuple,
Entry>();
+ // holds outstanding rid that are now waiting to reply (Open IMAs)
+ public final Map<OutstandingRequestIdTuple, String> _byOrid = new
HashMap<OutstandingRequestIdTuple, String>();
+ public final Map<String, Entry> _byChannel = new HashMap<String,
Entry>();
+
+ /**
+ * finds conflictingReceive
+ *
+ * @param selectors
+ * @return
+ */
+ int findConflict(Selector selectors[]) {
+ if (__log.isTraceEnabled()) {
+ __log.trace(ObjectPrinter.stringifyMethodEnter("findConflict", new
Object[] { "selectors", selectors }));
+ }
+
+ Set<RequestIdTuple> workingSet = new
HashSet<RequestIdTuple>(_byRid.keySet());
+ for (int i = 0; i < selectors.length; ++i) {
+ final RequestIdTuple rid = new RequestIdTuple(selectors[i].plinkInstance,
selectors[i].opName);
+ if (workingSet.contains(rid)) {
+ return i;
+ }
+ workingSet.add(rid);
+ }
+ return -1;
+ }
+
+ /**
+ * Register IMA
+ *
+ * @param pickResponseChannel
+ * response channel associated with this receive/pick
+ * @param selectors
+ * selectors for this receive/pick
+ */
+ void register(String pickResponseChannel, Selector selectors[]) {
+ if (__log.isTraceEnabled()) {
+ __log.trace(ObjectPrinter.stringifyMethodEnter("register", new
Object[] { "pickResponseChannel", pickResponseChannel, "selectors",
selectors }));
+ }
+
+ if (_byChannel.containsKey(pickResponseChannel)) {
+ String errmsg = "INTERNAL ERROR: Duplicate ENTRY for RESPONSE CHANNEL
" + pickResponseChannel;
+ __log.fatal(errmsg);
+ throw new IllegalArgumentException(errmsg);
+ }
+
+ Entry entry = new Entry(pickResponseChannel, selectors);
+ for (int i = 0; i < selectors.length; ++i) {
+ final RequestIdTuple rid = new RequestIdTuple(selectors[i].plinkInstance,
selectors[i].opName);
+ if (_byRid.containsKey(rid)) {
+ String errmsg = "INTERNAL ERROR: Duplicate ENTRY for RID " +
rid;
+ __log.fatal(errmsg);
+ throw new IllegalStateException(errmsg);
+ }
+ _byRid.put(rid, entry);
+ }
+
+ _byChannel.put(pickResponseChannel, entry);
+ }
+
+ /**
+ * Registers Open IMA.
+ * It doesn't open IMA for non two way operations.
+ *
+ * @param partnerLink
+ * @param opName
+ * @param mexId
+ * @param mexRef
+ * @return
+ */
+ String processOutstandingRequest(PartnerLinkInstance partnerLink, String opName,
String mexId, String mexRef) {
+ if (__log.isTraceEnabled()) {
+ __log.trace(ObjectPrinter.stringifyMethodEnter("process", new
Object[] { "partnerLinkInstance", partnerLink, "operationName",
opName, "messageExchangeId", mexId, "mexRef", mexRef }));
+ }
+ final OutstandingRequestIdTuple orid = new OutstandingRequestIdTuple(partnerLink,
opName, mexId);
+ if (_byOrid.containsKey(orid)) {
+ //conflictingRequest found
+ return mexRef;
+ }
+ // We convert into outstanding request only for in-out operations (pending
release operation)
+ if
(partnerLink.partnerLink.getMyRoleOperation(opName).getStyle().equals(OperationType.REQUEST_RESPONSE))
{
+ _byOrid.put(orid, mexRef);
+ }
+ return null;
+ }
+
+ /**
+ * This is used to remove IMA from registered state.
+ *
+ * @see #register(String, Selector[])
+ * @param pickResponseChannel
+ */
+ void cancel(String pickResponseChannel, boolean isTimer) {
+ if (__log.isTraceEnabled())
+ __log.trace(ObjectPrinter.stringifyMethodEnter("cancel", new
Object[] { "pickResponseChannel", pickResponseChannel }));
+
+ Entry entry = _byChannel.remove(pickResponseChannel);
+ if (entry != null) {
+ while (_byRid.values().remove(entry));
+ } else if (!isTimer){
+ String errmsg = "INTERNAL ERROR: No ENTRY for RESPONSE CHANNEL " +
pickResponseChannel;
+ __log.fatal(errmsg);
+ throw new IllegalArgumentException(errmsg);
+ }
+ }
+
+ /**
+ * Release Open IMA.
+ *
+ * @param plinkInstnace
+ * partner link
+ * @param opName
+ * operation
+ * @param mexId
+ * message exchange identifier IN THE BPEL SENSE OF THE TERM (i.e. a
receive/reply disambiguator).
+ * @return message exchange identifier associated with the registration that matches
the parameters
+ */
+ public String release(PartnerLinkInstance plinkInstnace, String opName, String mexId)
{
+ if (__log.isTraceEnabled())
+ __log.trace(ObjectPrinter.stringifyMethodEnter("release", new
Object[] { "plinkInstance", plinkInstnace, "opName", opName,
"mexId", mexId }));
+
+ final OutstandingRequestIdTuple orid = new
OutstandingRequestIdTuple(plinkInstnace, opName, mexId);
+ String mexRef = _byOrid.remove(orid);
+ if (mexRef == null) {
+ if (__log.isDebugEnabled()) {
+ __log.debug("==release: ORID " + orid + " not found in
" + _byOrid);
+ }
+ return null;
+ }
+ return mexRef;
+ }
+
+ public void migrateRids(Map<OutstandingRequestManager.RequestIdTuple,
OutstandingRequestManager.Entry> oldRids) {
+ for (OutstandingRequestManager.RequestIdTuple oldRid : oldRids.keySet()) {
+ OutstandingRequestManager.Entry oldEntry = oldRids.get(oldRid);
+ if (oldEntry.mexRef != null) {
+ //open IMA
+ OutstandingRequestIdTuple orid = new
OutstandingRequestIdTuple(oldRid.partnerLink, oldRid.opName, oldRid.mexId);
+ _byOrid.put(orid, oldEntry.mexRef);
+ } else {
+ //registered IMA
+ RequestIdTuple rid = new RequestIdTuple(oldRid.partnerLink,
oldRid.opName);
+ Entry entry = new Entry(oldEntry.pickResponseChannel, (Selector[])
oldEntry.selectors);
+ _byRid.put(rid, entry);
+ _byChannel.put(entry.pickResponseChannel, entry);
+ }
+ }
+ }
+
+ /**
+ * "Release" all Open IMAs
+ *
+ * @return a list of message exchange identifiers for message exchanges that were
begun (receive/pick got a message) but not yet completed (reply not yet sent)
+ */
+ public String[] releaseAll() {
+ if (__log.isTraceEnabled())
+ __log.trace(ObjectPrinter.stringifyMethodEnter("releaseAll",
null));
+
+ ArrayList<String> mexRefs = new ArrayList<String>();
+ while (!_byOrid.isEmpty()) {
+ String mexRef = _byOrid.entrySet().iterator().next().getValue();
+ mexRefs.add(mexRef);
+ _byOrid.values().remove(mexRef);
+ }
+ return mexRefs.toArray(new String[mexRefs.size()]);
+ }
+
+ public String toString() {
+ return ObjectPrinter.toString(this, new Object[] { "byRid", _byRid,
"byOrid", _byOrid, "byChannel", _byChannel });
+ }
+
+ private class RequestIdTuple implements Serializable {
+ private static final long serialVersionUID = -1059389611839777482L;
+ /** On which partner link it was received. */
+ PartnerLinkInstance partnerLink;
+ /** Name of the operation. */
+ String opName;
+
+ /** Constructor. */
+ private RequestIdTuple(PartnerLinkInstance partnerLink, String opName) {
+ this.partnerLink = partnerLink;
+ this.opName = opName;
+ }
+
+ public int hashCode() {
+ return this.partnerLink.hashCode() ^ this.opName.hashCode();
+ }
+
+ public boolean equals(Object obj) {
+ RequestIdTuple other = (RequestIdTuple) obj;
+ return other.partnerLink.equals(partnerLink) &&
other.opName.equals(opName);
+ }
+
+ public String toString() {
+ return ObjectPrinter.toString(this, new Object[] { "partnerLink",
partnerLink, "opName", opName});
+ }
+ }
+
+ private class OutstandingRequestIdTuple implements Serializable {
+ private static final long serialVersionUID = -1059389611839777482L;
+ /** On which partner link it was received. */
+ PartnerLinkInstance partnerLink;
+ /** Name of the operation. */
+ String opName;
+ /** Message exchange identifier. */
+ String mexId;
+
+ /** Constructor. */
+ private OutstandingRequestIdTuple(PartnerLinkInstance partnerLink, String opName,
String mexId) {
+ this.partnerLink = partnerLink;
+ this.opName = opName;
+ this.mexId = mexId == null ? "" : mexId;
+ }
+
+ public int hashCode() {
+ return this.partnerLink.hashCode() ^ this.opName.hashCode() ^
this.mexId.hashCode();
+ }
+
+ public boolean equals(Object obj) {
+ OutstandingRequestIdTuple other = (OutstandingRequestIdTuple) obj;
+ return other.partnerLink.equals(partnerLink) &&
other.opName.equals(opName) && other.mexId.equals(mexId);
+ }
+
+ public String toString() {
+ return ObjectPrinter.toString(this, new Object[] { "partnerLink",
partnerLink, "opName", opName, "mexId", mexId });
+ }
+ }
+
+ public class Entry implements Serializable {
+ private static final long serialVersionUID = -583743124656582887L;
+ final String pickResponseChannel;
+ public Selector[] selectors;
+
+ private Entry(String pickResponseChannel, Selector[] selectors) {
+ this.pickResponseChannel = pickResponseChannel;
+ this.selectors = selectors;
+ }
+
+ public String toString() {
+ return ObjectPrinter.toString(this, new Object[] {
"pickResponseChannel", pickResponseChannel, "selectors", selectors
});
+ }
+ }
+}
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/MessageExchangeImpl.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/MessageExchangeImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/MessageExchangeImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -28,7 +28,6 @@
import org.apache.ode.bpel.iapi.Message;
import org.apache.ode.bpel.iapi.MessageExchange;
import org.apache.ode.utils.msg.MessageBundle;
-import org.apache.ode.utils.Namespaces;
import org.w3c.dom.Element;
import javax.wsdl.Operation;
@@ -151,7 +150,7 @@
_operation = operation;
}
- MessageExchangeDAO getDAO() {
+ public MessageExchangeDAO getDAO() {
return _dao;
}
@@ -159,6 +158,7 @@
setStatus(Status.FAULT);
getDAO().setFault(faultType);
getDAO().setResponse(((MessageImpl)outputFaultMessage)._dao);
+
responseReceived();
}
@@ -179,15 +179,9 @@
}
void setFailure(FailureType type, String reason, Element details) throws
BpelEngineException {
- // TODO not using FailureType
+ // TODO not using FailureType, nor details
setStatus(Status.FAILURE);
getDAO().setFaultExplanation(reason);
- if (details != null) {
- Message message = createMessage(new QName(Namespaces.ODE_EXTENSION_NS,
"failureMessage"));
- message.setMessage(details);
- getDAO().setResponse(((MessageImpl) message)._dao);
- }
- responseReceived();
}
void setStatus(Status status) {
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/MessageImpl.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/MessageImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/MessageImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -37,7 +37,7 @@
public class MessageImpl implements Message {
- MessageDAO _dao;
+ public MessageDAO _dao;
public MessageImpl(MessageDAO message) {
_dao = message;
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/MyRoleMessageExchangeImpl.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/MyRoleMessageExchangeImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/MyRoleMessageExchangeImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -34,6 +34,7 @@
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.apache.ode.bpel.dao.MessageExchangeDAO;
+import org.apache.ode.bpel.engine.replayer.Replayer;
import org.apache.ode.bpel.iapi.Message;
import org.apache.ode.bpel.iapi.MessageExchange;
import org.apache.ode.bpel.iapi.MyRoleMessageExchange;
@@ -47,14 +48,13 @@
import org.w3c.dom.Element;
import org.w3c.dom.Node;
-class MyRoleMessageExchangeImpl extends MessageExchangeImpl implements
MyRoleMessageExchange {
+public class MyRoleMessageExchangeImpl extends MessageExchangeImpl implements
MyRoleMessageExchange {
+ private static final Log __log = LogFactory.getLog(MyRoleMessageExchangeImpl.class);
- private static final Log __log = LogFactory.getLog(MyRoleMessageExchangeImpl.class);
-
protected BpelProcess _process;
- private static Map<String, ResponseCallback> _waitingCallbacks =
+ protected static Map<String, ResponseCallback> _waitingCallbacks =
new ConcurrentHashMap<String, ResponseCallback>();
public MyRoleMessageExchangeImpl(BpelProcess process, BpelEngineImpl engine,
MessageExchangeDAO mexdao) {
@@ -66,7 +66,7 @@
return CorrelationStatus.valueOf(getDAO().getCorrelationStatus());
}
- void setCorrelationStatus(CorrelationStatus status) {
+ public void setCorrelationStatus(CorrelationStatus status) {
getDAO().setCorrelationStatus(status.toString());
}
@@ -75,8 +75,7 @@
*
* @param mex
* message exchange
- * @return <code>true</code> if execution should continue,
- * <code>false</code> otherwise
+ * @return <code>true</code> if execution should continue,
<code>false</code> otherwise
*/
private boolean processInterceptors(MyRoleMessageExchangeImpl mex, InterceptorInvoker
invoker) {
InterceptorContextImpl ictx = new
InterceptorContextImpl(_engine._contexts.dao.getConnection(),
@@ -89,8 +88,7 @@
return true;
}
- boolean processInterceptor(MessageExchangeInterceptor i, MyRoleMessageExchangeImpl
mex, InterceptorContext ictx,
- InterceptorInvoker invoker) {
+ boolean processInterceptor(MessageExchangeInterceptor i, MyRoleMessageExchangeImpl
mex, InterceptorContext ictx, InterceptorInvoker invoker) {
__log.debug(invoker + "--> interceptor " + i);
try {
invoker.invoke(i, mex, ictx);
@@ -100,8 +98,7 @@
return false;
} catch (AbortMessageExchangeException ame) {
__log.debug("interceptor " + i + " cause invoke on " +
this + " to be aborted with FAILURE: " + ame.getMessage());
- mex.setFailure(MessageExchange.FailureType.ABORTED,
__msgs.msgInterceptorAborted(mex.getMessageExchangeId(), i
- .toString(), ame.getMessage()), null);
+ mex.setFailure(MessageExchange.FailureType.ABORTED,
__msgs.msgInterceptorAborted(mex.getMessageExchangeId(), i.toString(), ame.getMessage()),
null);
return false;
}
return true;
@@ -137,7 +134,7 @@
// Schedule a new job for invocation
WorkEvent we = new WorkEvent();
we.setType(WorkEvent.Type.INVOKE_INTERNAL);
- if (target.isInMemory()) we.setInMem(true);
+ we.setInMem(target.isInMemory());
we.setProcessId(target.getPID());
we.setMexId(getDAO().getMessageExchangeId());
@@ -147,10 +144,15 @@
}
setStatus(Status.ASYNC);
- if (target.isInMemory())
- _engine._contexts.scheduler.scheduleVolatileJob(true, we.getDetail());
- else
- _engine._contexts.scheduler.schedulePersistedJob(we.getDetail(), null);
+ Replayer replayer = Replayer.replayer.get();
+ if (replayer == null) {
+ if (target.isInMemory())
+ _engine._contexts.scheduler.scheduleVolatileJob(true,
we.getDetail());
+ else
+ _engine._contexts.scheduler.schedulePersistedJob(we.getDetail(),
null);
+ } else {
+ replayer.scheduler.schedulePersistedJob(we.getDetail(), null);
+ }
return new ResponseFuture(getClientId());
}
}
@@ -172,8 +174,7 @@
public String toString() {
try {
- return "{MyRoleMex#" + getMessageExchangeId() + " [Client
" + getClientId() + "] calling " + getServiceName() + "."
- + getOperationName() + "(...)}";
+ return "{MyRoleMex#" + getMessageExchangeId() + " [Client
" + getClientId() + "] calling " + getServiceName() + "." +
getOperationName() + "(...)}";
} catch (Throwable t) {
return "{MyRoleMex#???}";
}
@@ -186,32 +187,32 @@
public void release(boolean instanceSucceeded) {
if(__log.isDebugEnabled()) __log.debug("Releasing mex " +
getMessageExchangeId());
if (_process != null) {
- _dao.release(_process.isCleanupCategoryEnabled(instanceSucceeded,
CLEANUP_CATEGORY.MESSAGES));
+ _dao.release(_process.isCleanupCategoryEnabled(instanceSucceeded,
CLEANUP_CATEGORY.MESSAGES));
}
_dao = null;
}
-
+
/**
* Return a deep clone of the given message
*
* @param message
* @return
*/
- protected Message cloneMessage(Message message) {
- Message clone = createMessage(message.getType());
- clone.setMessage((Element) message.getMessage().cloneNode(true));
- Map<String, Node> headerParts = message.getHeaderParts();
- for (String partName : headerParts.keySet()) {
- clone.setHeaderPart(partName, (Element) headerParts.get(partName).cloneNode(true));
- }
- Map<String, Node> parts = message.getHeaderParts();
- for (String partName : parts.keySet()) {
- clone.setHeaderPart(partName, (Element) parts.get(partName).cloneNode(true));
- }
- return clone;
- }
+ protected Message cloneMessage(Message message) {
+ Message clone = createMessage(message.getType());
+ clone.setMessage((Element) message.getMessage().cloneNode(true));
+ Map<String, Node> headerParts = message.getHeaderParts();
+ for (String partName : headerParts.keySet()) {
+ clone.setHeaderPart(partName, (Element)
headerParts.get(partName).cloneNode(true));
+ }
+ Map<String, Node> parts = message.getHeaderParts();
+ for (String partName : parts.keySet()) {
+ clone.setHeaderPart(partName, (Element) parts.get(partName).cloneNode(true));
+ }
+ return clone;
+ }
- @SuppressWarnings("unchecked")
+ @SuppressWarnings("unchecked")
static class ResponseFuture implements Future {
private String _clientId;
private boolean _done = false;
@@ -223,6 +224,7 @@
public boolean cancel(boolean mayInterruptIfRunning) {
throw new UnsupportedOperationException();
}
+
public Object get() throws InterruptedException, ExecutionException {
try {
return get(0, TimeUnit.MILLISECONDS);
@@ -231,6 +233,7 @@
throw new ExecutionException(e);
}
}
+
public Object get(long timeout, TimeUnit unit) throws InterruptedException,
ExecutionException, TimeoutException {
ResponseCallback callback = _waitingCallbacks.get(_clientId);
if (callback != null) {
@@ -241,22 +244,30 @@
}
return null;
}
+
public boolean isCancelled() {
return false;
}
+
public boolean isDone() {
return _done;
}
}
+ @Override
protected void responseReceived() {
final String cid = getClientId();
_engine._contexts.scheduler.registerSynchronizer(new Scheduler.Synchronizer() {
public void afterCompletion(boolean success) {
__log.debug("Received myrole mex response callback");
- ResponseCallback callback = _waitingCallbacks.remove(cid);
- if (callback != null) callback.responseReceived();
+ if( success ) {
+ ResponseCallback callback = _waitingCallbacks.remove(cid);
+ if (callback != null) callback.responseReceived();
+ } else {
+ __log.warn("Transaction is rolled back on sending back the
response.");
+ }
}
+
public void beforeCompletion() {
}
});
@@ -288,5 +299,4 @@
_timedout = _waiting;
}
}
-
}
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/OutstandingRequestManager.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/OutstandingRequestManager.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/OutstandingRequestManager.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -24,6 +24,7 @@
import java.io.Serializable;
import java.util.ArrayList;
+import java.util.Collection;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Map;
@@ -43,6 +44,7 @@
* for asynchronous messages.
* </p>
*/
+@Deprecated
public class OutstandingRequestManager implements Serializable {
private static final long serialVersionUID = -5556374398943757951L;
@@ -211,19 +213,23 @@
"byChannel", _byChannel
});
}
+
+ public Map<RequestIdTuple, Entry> getRids() {
+ return _byRid;
+ }
/**
* Tuple identifying an outstanding request (i.e. a receive,pick, or onMessage on a
* synchronous operation needing a reply).
*/
- private class RequestIdTuple implements Serializable {
+ public class RequestIdTuple implements Serializable {
private static final long serialVersionUID = -1059389611839777482L;
/** On which partner link it was received. */
- PartnerLinkInstance partnerLink;
+ public PartnerLinkInstance partnerLink;
/** Name of the operation. */
- String opName;
+ public String opName;
/** Message exchange identifier. */
- String mexId;
+ public String mexId;
/** Constructor. */
private RequestIdTuple(PartnerLinkInstance partnerLink, String opName, String mexId)
{
@@ -254,9 +260,9 @@
public class Entry implements Serializable {
private static final long serialVersionUID = -583743124656582887L;
- final String pickResponseChannel;
+ public final String pickResponseChannel;
public Object[] selectors;
- String mexRef;
+ public String mexRef;
private Entry(String pickResponseChannel, Selector[] selectors) {
this.pickResponseChannel = pickResponseChannel;
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/PartnerLinkMyRoleImpl.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/PartnerLinkMyRoleImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/PartnerLinkMyRoleImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -59,7 +59,7 @@
/**
* @author Matthieu Riou <mriou at apache dot org>
*/
-class PartnerLinkMyRoleImpl extends PartnerLinkRoleImpl {
+public class PartnerLinkMyRoleImpl extends PartnerLinkRoleImpl {
private static final Log __log = LogFactory.getLog(BpelProcess.class);
private static final Messages __msgs = MessageBundle.getMessages(Messages.class);
@@ -154,12 +154,12 @@
return routingInfos;
}
- class RoutingInfo {
- MessageRouteDAO messageRoute;
- CorrelationKeySet matchedKeySet;
- CorrelatorDAO correlator;
+ public static class RoutingInfo {
+ public MessageRouteDAO messageRoute;
+ public CorrelationKeySet matchedKeySet;
+ public CorrelatorDAO correlator;
// CorrelationKey[] keys;
- CorrelationKeySet wholeKeySet;
+ public CorrelationKeySet wholeKeySet;
public RoutingInfo(MessageRouteDAO messageRoute, CorrelationKeySet
matchedKeySet,
CorrelatorDAO correlator, CorrelationKeySet wholeKeySet) {
@@ -202,7 +202,9 @@
_process.saveEvent(evt, newInstance);
mex.setCorrelationStatus(MyRoleMessageExchange.CorrelationStatus.CREATE_INSTANCE);
mex.getDAO().setInstance(newInstance);
-
+ if (mex.getDAO().getCreateTime() == null)
+ mex.getDAO().setCreateTime(instance.getCurrentEventDateTime());
+
instance.execute();
}
@@ -237,6 +239,9 @@
mex.setCorrelationStatus(MyRoleMessageExchange.CorrelationStatus.MATCHED);
mex.getDAO().setInstance(routing.messageRoute.getTargetInstance());
+ if (mex.getDAO().getCreateTime() == null)
+ mex.getDAO().setCreateTime(instance.getCurrentEventDateTime());
+
instance.execute();
}
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/PartnerLinkPartnerRoleImpl.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/PartnerLinkPartnerRoleImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/PartnerLinkPartnerRoleImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -33,6 +33,8 @@
Endpoint _initialPartner;
public PartnerRoleChannel _channel;
+
+ public boolean usePeer2Peer = true;
PartnerLinkPartnerRoleImpl(BpelProcess process, OPartnerLink plink, Endpoint
initialPartner) {
super(process, plink);
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/PartnerRoleMessageExchangeImpl.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/PartnerRoleMessageExchangeImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/PartnerRoleMessageExchangeImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -23,6 +23,7 @@
import org.apache.commons.logging.LogFactory;
import org.apache.ode.bpel.dao.MessageExchangeDAO;
import org.apache.ode.bpel.engine.WorkEvent.Type;
+import org.apache.ode.bpel.engine.replayer.Replayer;
import org.apache.ode.bpel.iapi.BpelEngineException;
import org.apache.ode.bpel.iapi.EndpointReference;
import org.apache.ode.bpel.iapi.Message;
@@ -134,14 +135,18 @@
WorkEvent we = new WorkEvent();
we.setIID(getDAO().getInstance().getInstanceId());
we.setType(Type.INVOKE_RESPONSE);
- if
(_engine._activeProcesses.get(getDAO().getProcess().getProcessId()).isInMemory())
- we.setInMem(true);
+
we.setInMem(_engine._activeProcesses.get(getDAO().getProcess().getProcessId()).isInMemory());
we.setChannel(getDAO().getChannel());
we.setMexId(getDAO().getMessageExchangeId());
- if (we.isInMem())
- _engine._contexts.scheduler.scheduleVolatileJob(true, we.getDetail());
- else
- _engine._contexts.scheduler.schedulePersistedJob(we.getDetail(), null);
+ Replayer replayer = Replayer.replayer.get();
+ if (replayer == null) {
+ if (we.isInMem())
+ _engine._contexts.scheduler.scheduleVolatileJob(true, we.getDetail());
+ else
+ _engine._contexts.scheduler.schedulePersistedJob(we.getDetail(), null);
+ } else {
+ replayer.scheduler.schedulePersistedJob(we.getDetail(), null);
+ }
}
/**
@@ -160,7 +165,7 @@
public String toString() {
try {
return "{PartnerRoleMex#" + getMessageExchangeId() + " [PID
" + getCaller() + "] calling " + _epr + "."
- + getOperationName() + "(...)}";
+ + getOperationName() + "(...) Status " + getStatus() +
"}";
} catch (Throwable t) {
return "{PartnerRoleMex#????}";
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/ProcessAndInstanceManagementImpl.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/ProcessAndInstanceManagementImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/ProcessAndInstanceManagementImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -28,9 +28,11 @@
import java.util.Comparator;
import java.util.Date;
import java.util.EnumSet;
+import java.util.HashSet;
import java.util.LinkedList;
import java.util.List;
import java.util.Map;
+import java.util.Set;
import java.util.regex.Pattern;
import javax.xml.namespace.QName;
@@ -50,6 +52,9 @@
import org.apache.ode.bpel.dao.ProcessInstanceDAO;
import org.apache.ode.bpel.dao.ScopeDAO;
import org.apache.ode.bpel.dao.XmlDataDAO;
+import org.apache.ode.bpel.dao.ProcessManagementDAO.FailedSummaryValue;
+import org.apache.ode.bpel.dao.ProcessManagementDAO.InstanceSummaryKey;
+import org.apache.ode.bpel.engine.replayer.Replayer;
import org.apache.ode.bpel.evt.ActivityEvent;
import org.apache.ode.bpel.evt.BpelEvent;
import org.apache.ode.bpel.evt.CorrelationEvent;
@@ -84,6 +89,8 @@
import org.apache.ode.bpel.pmapi.ActivityExtInfoListDocument;
import org.apache.ode.bpel.pmapi.ActivityInfoDocument;
import org.apache.ode.bpel.pmapi.EventInfoListDocument;
+import org.apache.ode.bpel.pmapi.GetCommunication;
+import org.apache.ode.bpel.pmapi.GetCommunicationResponseDocument;
import org.apache.ode.bpel.pmapi.InstanceInfoDocument;
import org.apache.ode.bpel.pmapi.InstanceInfoListDocument;
import org.apache.ode.bpel.pmapi.InstanceManagement;
@@ -96,6 +103,9 @@
import org.apache.ode.bpel.pmapi.ProcessManagement;
import org.apache.ode.bpel.pmapi.ProcessNotFoundException;
import org.apache.ode.bpel.pmapi.ProcessingException;
+import org.apache.ode.bpel.pmapi.Replay;
+import org.apache.ode.bpel.pmapi.ReplayResponse;
+import org.apache.ode.bpel.pmapi.ReplayResponseDocument;
import org.apache.ode.bpel.pmapi.ScopeInfoDocument;
import org.apache.ode.bpel.pmapi.TActivityExtInfo;
import org.apache.ode.bpel.pmapi.TActivityStatus;
@@ -133,8 +143,8 @@
import org.w3c.dom.Node;
/**
- * Implentation of the Process and InstanceManagement APIs.
- *
+ * Implementation of the Process and InstanceManagement APIs.
+ *
* @todo Move this out of the engine, it no longer belongs here.
*/
public class ProcessAndInstanceManagementImpl implements InstanceManagement,
ProcessManagement {
@@ -150,7 +160,7 @@
protected ProcessStore _store;
// Calendar can be expensive to initialize so we cache and clone it
- protected Calendar _calendar = Calendar.getInstance();
+ protected Calendar _calendar = Calendar.getInstance();
protected BpelServerImpl _server;
@@ -165,15 +175,31 @@
ProcessInfoListDocument ret = ProcessInfoListDocument.Factory.newInstance();
final TProcessInfoList procInfoList = ret.addNewProcessInfoList();
final ProcessFilter processFilter = new ProcessFilter(filter, orderKeys);
-
- for (ProcessConf pconf : processQuery(processFilter)) {
- try {
- fillProcessInfo(procInfoList.addNewProcessInfo(), pconf, custom);
- } catch (Exception e) {
- __log.error("Exception when querying process " +
pconf.getProcessId(), e);
- }
+ try {
+ _db.exec(new BpelDatabase.Callable<Object>() {
+ public Object run(BpelDAOConnection conn) throws Exception {
+ Collection<ProcessConf> pconfs = processQuery(processFilter);
+ for (ProcessConf pconf : pconfs) {
+ try {
+ fillProcessInfo(procInfoList.addNewProcessInfo(), pconf,
custom);
+ } catch (Exception e) {
+ failIfSQLException(e);
+ __log.error("Exception when querying process " +
pconf.getProcessId(), e);
+ }
+ }
+ try {
+ fillProcessInfoSummary(conn, procInfoList.getProcessInfoList(),
custom);
+ } catch (Exception e) {
+ failIfSQLException(e);
+ __log.error("Exception fetching instances summary",
e);
+ }
+ return null;
+ }
+ });
+ } catch (Exception e) {
+ __log.error("Exception while listing processes", e);
+ throw new ProcessingException("Exception while listing processes: "
+ e.toString());
}
-
return ret;
}
@@ -185,10 +211,23 @@
return listProcessesCustom(null, null, ProcessInfoCustomizer.ALL);
}
- public ProcessInfoDocument getProcessInfoCustom(QName pid, ProcessInfoCustomizer
custom) {
- return genProcessInfoDocument(pid, custom);
+ public ProcessInfoListDocument listProcessesSummaryOnly() {
+ return listProcessesCustom(null, null, ProcessInfoCustomizer.SUMMARYONLY);
}
+ public ProcessInfoDocument getProcessInfoCustom(final QName pid, final
ProcessInfoCustomizer custom) {
+ try {
+ return _db.exec(new BpelDatabase.Callable<ProcessInfoDocument>() {
+ public ProcessInfoDocument run(BpelDAOConnection conn) {
+ return genProcessInfoDocument(conn, pid, custom);
+ }
+ });
+ } catch (Exception ex) {
+ __log.error("Exception in getProcessInfoCustom()", ex);
+ throw new ManagementException("Exception in getProcessInfoCustom():
" + ex.toString());
+ }
+ }
+
public ProcessInfoDocument getProcessInfo(QName pid) {
return getProcessInfoCustom(pid, ProcessInfoCustomizer.ALL);
}
@@ -200,20 +239,20 @@
__log.error("Exception while setting process state", ex);
throw new ManagementException("Error setting process state: " +
ex.toString());
}
- return genProcessInfoDocument(pid, ProcessInfoCustomizer.NONE);
+ return getProcessInfoCustom(pid, ProcessInfoCustomizer.NONE);
}
- public ProcessInfoDocument setRetired(final QName pid, final boolean retired) throws
ManagementException {
+ public ProcessInfoDocument setRetired(QName pid, boolean retired) throws
ManagementException {
try {
_store.setState(pid, retired ? ProcessState.RETIRED : ProcessState.ACTIVE);
} catch (BpelEngineException e) {
__log.error("Exception while setting process as retired", e);
throw new ProcessNotFoundException("ProcessNotFound:" + pid);
}
- return genProcessInfoDocument(pid, ProcessInfoCustomizer.NONE);
+ return getProcessInfoCustom(pid, ProcessInfoCustomizer.NONE);
}
- public void setPackageRetired(final String packageName, final boolean retired)
+ public void setPackageRetired(String packageName, boolean retired)
throws ManagementException {
try {
_store.setRetiredPackage(packageName, retired);
@@ -228,29 +267,35 @@
ProcessInfoDocument ret = ProcessInfoDocument.Factory.newInstance();
final TProcessInfo pi = ret.addNewProcessInfo();
try {
- try {
- _store.setProperty(pid, propertyName, value);
- } catch (Exception ex) {
- // Likely the process no longer exists in the store.
- __log.debug("Error setting property value for " + pid + ";
" + propertyName, ex);
- }
+ _db.exec(new BpelDatabase.Callable<Object>() {
+ public Object run(BpelDAOConnection conn) throws Exception {
+ try {
+ _store.setProperty(pid, propertyName, value);
+ } catch (Exception ex) {
+ failIfSQLException(ex);
- // We have to do this after we set the property, since the
- // ProcessConf object
- // is immutable.
- ProcessConf proc = _store.getProcessConfiguration(pid);
- if (proc == null)
- throw new ProcessNotFoundException("ProcessNotFound:" + pid);
+ // Likely the process no longer exists in the store.
+ __log.debug("Error setting property value for " + pid +
"; " + propertyName, ex);
+ }
- fillProcessInfo(pi, proc, new
ProcessInfoCustomizer(ProcessInfoCustomizer.Item.PROPERTIES));
+ // We have to do this after we set the property, since the
+ // ProcessConf object
+ // is immutable.
+ ProcessConf proc = _store.getProcessConfiguration(pid);
+ if (proc == null)
+ throw new ProcessNotFoundException("ProcessNotFound:" +
pid);
+ fillProcessInfo(pi, proc, new
ProcessInfoCustomizer(ProcessInfoCustomizer.Item.PROPERTIES));
+
+ return null;
+ }
+ });
} catch (ManagementException me) {
throw me;
} catch (Exception e) {
__log.error("Exception while setting process property", e);
throw new ProcessingException("Exception while setting process property:
" + e.toString());
}
-
return ret;
}
@@ -259,28 +304,34 @@
ProcessInfoDocument ret = ProcessInfoDocument.Factory.newInstance();
final TProcessInfo pi = ret.addNewProcessInfo();
try {
- try {
- _store.setProperty(pid, propertyName, value);
- } catch (Exception ex) {
- // Likely the process no longer exists in the store.
- __log.debug("Error setting property value for " + pid + ";
" + propertyName, ex);
- }
+ _db.exec(new BpelDatabase.Callable<Object>() {
+ public Object run(BpelDAOConnection conn) throws Exception {
+ try {
+ _store.setProperty(pid, propertyName, value);
+ } catch (Exception ex) {
+ failIfSQLException(ex);
- // We have to do this after we set the property, since the
- // ProcessConf object is immutable.
- ProcessConf proc = _store.getProcessConfiguration(pid);
- if (proc == null)
- throw new ProcessNotFoundException("ProcessNotFound:" + pid);
+ // Likely the process no longer exists in the store.
+ __log.debug("Error setting property value for " + pid +
"; " + propertyName, ex);
+ }
- fillProcessInfo(pi, proc, new
ProcessInfoCustomizer(ProcessInfoCustomizer.Item.PROPERTIES));
+ // We have to do this after we set the property, since the
+ // ProcessConf object is immutable.
+ ProcessConf proc = _store.getProcessConfiguration(pid);
+ if (proc == null)
+ throw new ProcessNotFoundException("ProcessNotFound:" +
pid);
+ fillProcessInfo(pi, proc, new
ProcessInfoCustomizer(ProcessInfoCustomizer.Item.PROPERTIES));
+
+ return null;
+ }
+ });
} catch (ManagementException me) {
throw me;
} catch (Exception e) {
__log.error("Exception while setting process property", e);
throw new ProcessingException("Exception while setting process
property" + e.toString());
}
-
return ret;
}
@@ -314,7 +365,6 @@
public Object run(BpelDAOConnection conn) {
Collection<ProcessInstanceDAO> instances =
conn.instanceQuery(instanceFilter);
Map<Long, Collection<CorrelationSetDAO>> icsets =
conn.getCorrelationSets(instances);
-
conn.getProcessManagement().prefetchActivityFailureCounts(instances);
for (ProcessInstanceDAO instance : instances) {
TInstanceInfo info = infolist.addNewInstanceInfo();
fillInstanceSummary(info, instance);
@@ -344,16 +394,34 @@
return listInstancesSummary(null, null, limit);
}
- public InstanceInfoDocument getInstanceInfo(Long iid) throws
InstanceNotFoundException {
- return genInstanceInfoDocument(iid);
+ public InstanceInfoDocument getInstanceInfo(final Long iid) throws
InstanceNotFoundException {
+ try {
+ return _db.exec(new BpelDatabase.Callable<InstanceInfoDocument>() {
+ public InstanceInfoDocument run(BpelDAOConnection conn) {
+ return genInstanceInfoDocument(conn, iid);
+ }
+ });
+ } catch (Exception e) {
+ __log.error("Exception while retrieving instance info", e);
+ throw new ProcessingException("Exception while retrieving instance info:
" + e.toString());
+ }
}
public ScopeInfoDocument getScopeInfo(String siid) {
return getScopeInfoWithActivity(siid, false);
}
- public ScopeInfoDocument getScopeInfoWithActivity(String siid, boolean
includeActivityInfo) {
- return genScopeInfoDocument(siid, includeActivityInfo);
+ public ScopeInfoDocument getScopeInfoWithActivity(final String siid, final boolean
includeActivityInfo) {
+ try {
+ return _db.exec(new BpelDatabase.Callable<ScopeInfoDocument>() {
+ public ScopeInfoDocument run(BpelDAOConnection conn) throws Exception {
+ return genScopeInfoDocument(conn, siid, includeActivityInfo);
+ }
+ });
+ } catch (Exception e) {
+ __log.error("Exception while retrieving scope info", e);
+ throw new ProcessingException("Exception while retrieving scope info:
" + e.toString());
+ }
}
public VariableInfoDocument getVariableInfo(final String scopeId, final String
varName) throws ManagementException {
@@ -392,32 +460,32 @@
//
public InstanceInfoDocument fault(Long iid, QName faultname, Element faultData) {
// TODO: Implement
- return genInstanceInfoDocument(iid);
+ return getInstanceInfo(iid);
}
- public InstanceInfoDocument resume(final Long iid) {
+ public InstanceInfoDocument resume(Long iid) {
// We need debugger support in order to resume (since we have to force
// a reduction. If one is not available the getDebugger() method should
// throw a ProcessingException
getDebugger(iid).resume(iid);
- return genInstanceInfoDocument(iid);
+ return getInstanceInfo(iid);
}
- public InstanceInfoDocument suspend(final Long iid) throws ManagementException {
+ public InstanceInfoDocument suspend(Long iid) throws ManagementException {
DebuggerSupport debugSupport = getDebugger(iid);
assert debugSupport != null : "getDebugger(Long) returned NULL!";
debugSupport.suspend(iid);
- return genInstanceInfoDocument(iid);
+ return getInstanceInfo(iid);
}
- public InstanceInfoDocument terminate(final Long iid) throws ManagementException {
+ public InstanceInfoDocument terminate(Long iid) throws ManagementException {
DebuggerSupport debugSupport = getDebugger(iid);
assert debugSupport != null : "getDebugger(Long) returned NULL!";
debugSupport.terminate(iid);
- return genInstanceInfoDocument(iid);
+ return getInstanceInfo(iid);
}
public InstanceInfoDocument recoverActivity(final Long iid, final Long aid, final
String action) {
@@ -443,23 +511,21 @@
__log.error("Exception during activity recovery", e);
throw new ProcessingException("Exception during activity recovery"
+ e.toString());
}
- return genInstanceInfoDocument(iid);
+ return getInstanceInfo(iid);
}
public Collection<Long> delete(String filter) {
final InstanceFilter instanceFilter = new InstanceFilter(filter);
-
final List<Long> ret = new LinkedList<Long>();
try {
-
_db.exec(new BpelDatabase.Callable<Object>() {
public Object run(BpelDAOConnection conn) {
Collection<ProcessInstanceDAO> instances =
conn.instanceQuery(instanceFilter);
for (ProcessInstanceDAO instance : instances) {
- ProcessConf proc =
_store.getProcessConfiguration(instance.getProcess().getProcessId());
- if (proc == null)
- throw new ProcessNotFoundException("ProcessNotFound:" +
instance.getProcess().getProcessId());
- // delete the instance and all related data
+ ProcessConf proc =
_store.getProcessConfiguration(instance.getProcess().getProcessId());
+ if (proc == null)
+ throw new
ProcessNotFoundException("ProcessNotFound:" +
instance.getProcess().getProcessId());
+ // delete the instance and all related data
instance.delete(EnumSet.allOf(CLEANUP_CATEGORY.class));
ret.add(instance.getInstanceId());
}
@@ -470,7 +536,6 @@
__log.error("Exception during instance deletion", e);
throw new ProcessingException("Exception during instance deletion:
" + e.toString());
}
-
return ret;
}
@@ -547,14 +612,13 @@
* Get the {@link DebuggerSupport} object for the given process identifier.
* Debugger support is required for operations that resume execution in some
* way or manipulate the breakpoints.
- *
+ *
* @param procid
* process identifier
* @return associated debugger support object
* @throws ManagementException
*/
protected final DebuggerSupport getDebugger(QName procid) throws ManagementException
{
-
BpelProcess process = _server._engine._activeProcesses.get(procid);
if (process == null)
throw new ProcessNotFoundException("The process \"" + procid +
"\" does not exist.");
@@ -566,7 +630,7 @@
* Get the {@link DebuggerSupport} object for the given instance identifier.
* Debugger support is required for operations that resume execution in some
* way or manipulate the breakpoints.
- *
+ *
* @param iid
* instance identifier
* @return associated debugger support object
@@ -574,7 +638,6 @@
*/
protected final DebuggerSupport getDebugger(final Long iid) {
QName processId;
-
try {
processId = _db.exec(new BpelDatabase.Callable<QName>() {
public QName run(BpelDAOConnection conn) throws Exception {
@@ -593,7 +656,7 @@
/**
* Execute a database transaction, unwrapping nested
* {@link ManagementException}s.
- *
+ *
* @param runnable
* action to run
* @return
@@ -613,7 +676,7 @@
/**
* Execute a database transaction, unwrapping nested
* {@link ManagementException}s.
- *
+ *
* @param callable
* action to run
* @return
@@ -631,18 +694,19 @@
}
}
- private ProcessInfoDocument genProcessInfoDocument(final QName procid, final
ProcessInfoCustomizer custom)
+ private ProcessInfoDocument genProcessInfoDocument(BpelDAOConnection conn, QName
procid, ProcessInfoCustomizer custom)
throws ManagementException {
- if (procid == null) {
- throw new InvalidRequestException("Valid QName as process id
expected.");
- }
+ if (procid == null) {
+ throw new InvalidRequestException("Valid QName as process id
expected.");
+ }
ProcessInfoDocument ret = ProcessInfoDocument.Factory.newInstance();
- final TProcessInfo pi = ret.addNewProcessInfo();
+ TProcessInfo pi = ret.addNewProcessInfo();
try {
ProcessConf pconf = _store.getProcessConfiguration(procid);
if (pconf == null)
throw new ProcessNotFoundException("ProcessNotFound:" +
procid);
fillProcessInfo(pi, pconf, custom);
+ fillProcessInfoSummary(conn, Collections.singletonList(pi), custom);
} catch (ManagementException me) {
throw me;
} catch (Exception e) {
@@ -656,47 +720,41 @@
/**
* Generate a {@link InstanceInfoDocument} for a given instance. This
* document contains general information about the instance.
- *
+ *
* @param iid
* instance identifier
* @return generated document
*/
- private InstanceInfoDocument genInstanceInfoDocument(final Long iid) {
+ private InstanceInfoDocument genInstanceInfoDocument(BpelDAOConnection conn, Long
iid) {
if (iid == null)
throw new InvalidRequestException("Must specifiy instance id.");
InstanceInfoDocument ret = InstanceInfoDocument.Factory.newInstance();
- final TInstanceInfo ii = ret.addNewInstanceInfo();
+ TInstanceInfo ii = ret.addNewInstanceInfo();
ii.setIid(iid.toString());
- dbexec(new BpelDatabase.Callable<Object>() {
- public Object run(BpelDAOConnection conn) throws Exception {
- ProcessInstanceDAO instance = conn.getInstance(iid);
-
- if (instance == null)
- throw new InstanceNotFoundException("InstanceNotFoundException
" + iid);
- // TODO: deal with "ERROR" state information.
- fillInstanceInfo(ii, instance);
- return null;
- }
- });
-
+ ProcessInstanceDAO instance = conn.getInstance(iid);
+ if (instance == null)
+ throw new InstanceNotFoundException("InstanceNotFoundException " +
iid);
+ // TODO: deal with "ERROR" state information.
+ fillInstanceInfo(ii, instance);
return ret;
}
/**
* Generate a {@link ScopeInfoDocument} for a given scope instance.
- *
+ *
* @param siid
* scope instance identifier
* @param includeActivityInfo
* @return generated document
+ * @throws Exception
*/
- private ScopeInfoDocument genScopeInfoDocument(final String siid, final boolean
includeActivityInfo) {
+ private ScopeInfoDocument genScopeInfoDocument(BpelDAOConnection conn, String siid,
boolean includeActivityInfo) throws Exception {
if (siid == null)
throw new InvalidRequestException("Must specifiy scope instance
id.");
- final Long siidl;
+ Long siidl;
try {
siidl = new Long(siid);
} catch (NumberFormatException nfe) {
@@ -704,29 +762,48 @@
}
ScopeInfoDocument ret = ScopeInfoDocument.Factory.newInstance();
- final TScopeInfo ii = ret.addNewScopeInfo();
+ TScopeInfo ii = ret.addNewScopeInfo();
ii.setSiid(siid);
- dbexec(new BpelDatabase.Callable<Object>() {
- public Object run(BpelDAOConnection conn) throws Exception {
- try {
- ScopeDAO instance = conn.getScope(siidl);
- if (instance == null)
- throw new InvalidRequestException("Scope not found: " +
siidl);
- // TODO: deal with "ERROR" state information.
- fillScopeInfo(ii, instance, includeActivityInfo);
- } catch (Exception e) {
- e.printStackTrace();
- }
- return null;
- }
- });
+ try {
+ ScopeDAO instance = conn.getScope(siidl);
+ if (instance == null)
+ throw new InvalidRequestException("Scope not found: " +
siidl);
+ // TODO: deal with "ERROR" state information.
+ fillScopeInfo(ii, instance, includeActivityInfo);
+ } catch (Exception e) {
+ failIfSQLException(e);
+ __log.error("Exception while retrieving scope information", e);
+ }
return ret;
}
+ private void fillProcessInfoSummary(BpelDAOConnection conn, List<TProcessInfo>
infos, ProcessInfoCustomizer custom) {
+ if (custom.includeInstanceSummary()) {
+ Set<String> pids = new HashSet<String>();
+ for (TProcessInfo i : infos) {
+ pids.add(i.getPid());
+ }
+
+ Map<InstanceSummaryKey, Long> m =
conn.getProcessManagement().countInstancesSummary(pids);
+ Map<String, FailedSummaryValue> f =
conn.getProcessManagement().findFailedCountAndLastFailedDateForProcessIds(pids);
+
+ for (TProcessInfo info : infos) {
+ TInstanceSummary isum = info.addNewInstanceSummary();
+ genInstanceSummaryEntry(isum.addNewInstances(), TInstanceStatus.ACTIVE,
info.getPid(), m);
+ genInstanceSummaryEntry(isum.addNewInstances(),
TInstanceStatus.COMPLETED, info.getPid(), m);
+ genInstanceSummaryEntry(isum.addNewInstances(), TInstanceStatus.ERROR,
info.getPid(), m);
+ genInstanceSummaryEntry(isum.addNewInstances(), TInstanceStatus.FAILED,
info.getPid(), m);
+ genInstanceSummaryEntry(isum.addNewInstances(),
TInstanceStatus.SUSPENDED, info.getPid(), m);
+ genInstanceSummaryEntry(isum.addNewInstances(),
TInstanceStatus.TERMINATED, info.getPid(), m);
+ getInstanceSummaryActivityFailure(isum, f, info.getPid());
+ }
+ }
+ }
+
/**
* Fill in the <code>process-info</code> element of the transfer object.
- *
+ *
* @param info
* destination XMLBean
* @param pconf
@@ -741,6 +818,8 @@
if (pconf == null)
throw new IllegalArgumentException("Null pconf.");
+ if( __log.isDebugEnabled() ) __log.debug("Filling process info for " +
pconf.getProcessId());
+
info.setPid(pconf.getProcessId().toString());
// TODO: ACTIVE and RETIRED should be used separately.
// Active process may be retired at the same time
@@ -756,27 +835,20 @@
TDeploymentInfo depinfo = info.addNewDeploymentInfo();
depinfo.setPackage(pconf.getPackage());
+ if( __log.isDebugEnabled() ) __log.debug(" package name: " +
depinfo.getPackage());
depinfo.setDocument(pconf.getBpelDocument());
depinfo.setDeployDate(toCalendar(pconf.getDeployDate()));
depinfo.setDeployer(pconf.getDeployer());
- if (custom.includeInstanceSummary()) {
- TInstanceSummary isum = info.addNewInstanceSummary();
- genInstanceSummaryEntry(isum.addNewInstances(), TInstanceStatus.ACTIVE,
pconf);
- genInstanceSummaryEntry(isum.addNewInstances(), TInstanceStatus.COMPLETED,
pconf);
- genInstanceSummaryEntry(isum.addNewInstances(), TInstanceStatus.ERROR,
pconf);
- genInstanceSummaryEntry(isum.addNewInstances(), TInstanceStatus.FAILED,
pconf);
- genInstanceSummaryEntry(isum.addNewInstances(), TInstanceStatus.SUSPENDED,
pconf);
- genInstanceSummaryEntry(isum.addNewInstances(), TInstanceStatus.TERMINATED,
pconf);
- getInstanceSummaryActivityFailure(isum, pconf);
+
+ if (custom.includeDocumentLists()) {
+ TProcessInfo.Documents docinfo = info.addNewDocuments();
+ List<File> files = pconf.getFiles();
+ if (files != null)
+ genDocumentInfo(docinfo, files.toArray(new File[files.size()]), true);
+ else if (__log.isDebugEnabled())
+ __log.debug("fillProcessInfo: No files for " +
pconf.getProcessId());
}
- TProcessInfo.Documents docinfo = info.addNewDocuments();
- List<File> files = pconf.getFiles();
- if (files != null)
- genDocumentInfo(docinfo, files.toArray(new File[files.size()]), true);
- else if (__log.isDebugEnabled())
- __log.debug("fillProcessInfo: No files for " +
pconf.getProcessId());
-
TProcessProperties properties = info.addNewProperties();
if (custom.includeProcessProperties()) {
for (Map.Entry<QName, Node> propEntry :
pconf.getProcessProperties().entrySet()) {
@@ -787,7 +859,7 @@
Node node2append = processInfoDoc.importNode(propEntry.getValue(),
true);
propNode.appendChild(node2append);
}
- }
+ }
TEndpointReferences eprs = info.addNewEndpoints();
OProcess oprocess = _server._engine.getOProcess(pconf.getProcessId());
@@ -809,10 +881,22 @@
// TODO: add documents to the above data structure.
}
-
+
+ String findVersionStringFromNodeToken(String packageName) {
+ int i = packageName.length() - 1;
+ while( i > 0 && Character.isDigit(packageName.charAt(i)) ) {
+ i--;
+ }
+ if( i < packageName.length() - 1 && packageName.charAt(i) == '-')
{
+ return packageName.substring(i + 1);
+ }
+
+ return null;
+ }
+
/**
* Generate document information elements for a set of files.
- *
+ *
* @param docinfo
* target element
* @param files
@@ -847,40 +931,21 @@
}
}
- private void genInstanceSummaryEntry(TInstanceSummary.Instances instances,
TInstanceStatus.Enum state,
- ProcessConf pconf) {
+ private void genInstanceSummaryEntry(TInstanceSummary.Instances instances,
+ TInstanceStatus.Enum state, String pid,
Map<InstanceSummaryKey, Long> summary)
+ {
instances.setState(state);
- String queryStatus =
InstanceFilter.StatusKeys.valueOf(state.toString()).toString().toLowerCase();
- final InstanceFilter instanceFilter = new InstanceFilter("status=" +
queryStatus
- + " pid="+ pconf.getProcessId());
-
- int count = dbexec(new BpelDatabase.Callable<Integer>() {
-
- public Integer run(BpelDAOConnection conn) throws Exception {
- return conn.instanceQuery(instanceFilter).size();
- }
- });
- instances.setCount(count);
+ Long count = summary.get(new InstanceSummaryKey(pid, state.toString()));
+ instances.setCount(count == null ? 0 : count.intValue());
}
- private void getInstanceSummaryActivityFailure(final TInstanceSummary summary, final
ProcessConf pconf) {
- dbexec(new BpelDatabase.Callable<Void>() {
- public Void run(BpelDAOConnection conn) throws Exception {
- String queryStatus =
InstanceFilter.StatusKeys.valueOf(TInstanceStatus.ACTIVE.toString()).toString().toLowerCase();
- Object[] results =
conn.getProcessManagement().findFailedCountAndLastFailedDateForProcessId(
- conn, queryStatus, String.valueOf(pconf.getProcessId()));
-
- long failureInstances = (Long)results[0];
- Date lastFailureDt = (Date)results[1];
- if (failureInstances > 0) {
- TFailuresInfo failures = summary.addNewFailures();
- failures.setDtFailure(toCalendar(lastFailureDt));
- failures.setCount((int)failureInstances);
- }
-
- return null;
- }
- });
+ private void getInstanceSummaryActivityFailure(TInstanceSummary summary,
Map<String, FailedSummaryValue> f, String pid) {
+ FailedSummaryValue v = f.get(pid);
+ if (v != null) {
+ TFailuresInfo failures = summary.addNewFailures();
+ failures.setDtFailure(toCalendar(v.lastFailed));
+ failures.setCount(v.count.intValue());
+ }
}
private void fillProperties(TInstanceInfo info, ProcessInstanceDAO instance,
Map<QName, String> props) {
@@ -915,7 +980,7 @@
failures.setCount(instance.getActivityFailureCount());
}
}
-
+
private void fillInstanceInfo(TInstanceInfo info, ProcessInstanceDAO instance) {
fillInstanceSummary(info, instance);
@@ -1122,7 +1187,7 @@
/**
* Convert a {@link Date} to a {@link Calendar}.
- *
+ *
* @param dtime
* a {@link Date}
* @return a {@link Calendar}
@@ -1142,7 +1207,6 @@
public InstanceInfoListDocument queryInstances(final String query) {
InstanceInfoListDocument ret = InstanceInfoListDocument.Factory.newInstance();
final TInstanceInfoList infolist = ret.addNewInstanceInfoList();
-
try {
_db.exec(new BpelDatabase.Callable<Object>() {
public Object run(BpelDAOConnection conn) {
@@ -1157,7 +1221,6 @@
__log.error("Exception while querying instances", e);
throw new ProcessingException("Exception while querying instances:
" + e.toString());
}
-
return ret;
}
@@ -1166,7 +1229,7 @@
* implemented in memory rather than via database calls since the processes
* are managed by the {@link ProcessStore} object and we don't want to make
* this needlessly complicated.
- *
+ *
* @param filter
* @return
*/
@@ -1302,9 +1365,76 @@
Collections.sort(confs, cchain);
}
-
+
}
return confs;
}
+
+ public ReplayResponseDocument replay(final Replay request) throws ManagementException
{
+ final Throwable[] e = new Throwable[1];
+ try {
+ ReplayResponseDocument response = _db.exec(new
BpelDatabase.Callable<ReplayResponseDocument>() {
+ public ReplayResponseDocument run(BpelDAOConnection conn) throws
Exception {
+ try {
+ ReplayResponse response = ReplayResponse.Factory.newInstance();
+ Replayer replayer = new Replayer();
+ List<Long> iids = replayer.replayInstances(request,
_server.getEngine(), conn);
+ for (Long iid : iids) {
+ response.addRestoredIID(iid);
+ }
+ ReplayResponseDocument responseDoc =
ReplayResponseDocument.Factory.newInstance();
+ responseDoc.setReplayResponse(response);
+ return responseDoc;
+ } catch (Throwable t) {
+ e[0] = t;
+ throw new Exception("", t);
+ }
+ }
+ });
+
+ if (e[0] != null) {
+ __log.debug("throwing pending exception");
+ throw e[0];
+ }
+ return response;
+ } catch (Throwable e2) {
+ throw new ManagementException("", e2);
+ }
+ }
+
+ public GetCommunicationResponseDocument getCommunication(final GetCommunication
request) throws ManagementException {
+ final Throwable[] e = new Throwable[1];
+ try {
+ GetCommunicationResponseDocument response = _db.exec(new
BpelDatabase.Callable<GetCommunicationResponseDocument>() {
+ public GetCommunicationResponseDocument run(BpelDAOConnection conn)
throws Exception {
+ try {
+ Replayer replayer = new Replayer();
+
+ GetCommunicationResponseDocument responseDoc =
GetCommunicationResponseDocument.Factory.newInstance();
+
responseDoc.setGetCommunicationResponse(replayer.getCommunication(request, conn));
+ return responseDoc;
+ } catch (Throwable e2) {
+ e[0] = e2;
+ throw new Exception("", e2);
+ }
+ }
+ });
+ if (e[0] != null) {
+ __log.debug("throwing pending exception");
+ throw e[0];
+ }
+ return response;
+ } catch (Throwable e2) {
+ throw new ManagementException("", e2);
+ }
+ }
+
+ private static void failIfSQLException(Exception e) throws Exception {
+ String[] fatal = { "org.hibernate", "org.apache.openjpa",
"java.sql", "javax.sql" };
+ for (int i=0; i<fatal.length; i++) {
+ if (e.getClass().getName().startsWith(fatal[i])) throw e;
+ }
+ }
+
}
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/WorkEvent.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/WorkEvent.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/WorkEvent.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -33,29 +33,29 @@
private Map<String, Object> _jobDetail;
- WorkEvent(Map<String, Object> jobDetail) {
+ public WorkEvent(Map<String, Object> jobDetail) {
_jobDetail = jobDetail;
}
- WorkEvent() {
+ public WorkEvent() {
_jobDetail = new HashMap<String, Object>();
}
- Long getIID() {
+ public Long getIID() {
return (Long) _jobDetail.get("iid");
}
- Type getType() {
+ public Type getType() {
return Type.valueOf((String) _jobDetail.get("type"));
}
- void setType(Type timer) {
+ public void setType(Type timer) {
_jobDetail.put("type", timer.toString());
}
- Map<String, Object> getDetail() {
+ public Map<String, Object> getDetail() {
return _jobDetail;
}
@@ -116,7 +116,7 @@
}
public QName getProcessId() {
- return _jobDetail.get("pid") != null? QName.valueOf((String)
_jobDetail.get("pid")) : null;
+ return _jobDetail.get("pid") != null?
QName.valueOf(_jobDetail.get("pid").toString()) : null;
}
}
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/cron/CronScheduler.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/cron/CronScheduler.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/cron/CronScheduler.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -150,7 +150,7 @@
}
synchronized( _systemTerminationListeners) {
- if( __log.isInfoEnabled() ) __log.info("Refreshing SYSTEM CRON
jobs.");
+ if( __log.isDebugEnabled() ) __log.debug("Refreshing SYSTEM CRON
jobs.");
try {
// if error thrown on reading the schedules.xml, do not cancel existing
cron jobs
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/cron/SystemSchedulesConfig.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/cron/SystemSchedulesConfig.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/cron/SystemSchedulesConfig.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -77,7 +77,7 @@
}
}
- __log.info("SYSTEM CRON configuration found cron jobs: " + jobs);
+ if( __log.isDebugEnabled() ) __log.debug("SYSTEM CRON configuration found
cron jobs: " + jobs);
return jobs;
}
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/migration/MigrationHandler.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/migration/MigrationHandler.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/migration/MigrationHandler.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -19,31 +19,40 @@
package org.apache.ode.bpel.engine.migration;
-import org.apache.ode.bpel.engine.Contexts;
-import org.apache.ode.bpel.engine.BpelDatabase;
-import org.apache.ode.bpel.engine.BpelProcess;
-import org.apache.ode.bpel.dao.BpelDAOConnection;
+import java.sql.Connection;
+import java.sql.PreparedStatement;
+import java.sql.ResultSet;
+import java.sql.SQLException;
+import java.sql.Statement;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Set;
+import java.util.concurrent.Callable;
+
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
+import org.apache.ode.bpel.engine.BpelProcess;
+import org.apache.ode.bpel.engine.Contexts;
-import java.sql.*;
-import java.util.*;
-import java.util.concurrent.Callable;
-
/**
* Checks database schema versions and migrates when necessary.
*/
public class MigrationHandler {
private static final Log __log = LogFactory.getLog(MigrationHandler.class);
- public static final int CURRENT_SCHEMA_VERSION = 5;
+ public static final int CURRENT_SCHEMA_VERSION = 6;
+
private Contexts _contexts;
private List<MigrationLink> migrationLinks = new
ArrayList<MigrationLink>() {{
- add(new MigrationLink(1, 2, new Migration[] { new CorrelatorsMigration(), new
CorrelationKeyMigration() } ));
+ add(new MigrationLink(1, 2, new Migration[] { new CorrelatorsMigration(),
+ new CorrelationKeyMigration() } ));
add(new MigrationLink(2, 3, new Migration[] { new CorrelationKeySetMigration() }
));
add(new MigrationLink(4, 3, new Migration[] { new CorrelationKeySetMigration() }
));
add(new MigrationLink(3, 5, new Migration[] { new
CorrelationKeySetDataMigration() } ));
+ add(new MigrationLink(5, 6, new Migration[] { new OutstandingRequestsMigration()
} ));
}};
@@ -51,10 +60,10 @@
this._contexts = _contexts;
}
- public boolean migrate(final Set<BpelProcess> registeredProcesses) {
+ public boolean migrate(final Set<BpelProcess> registeredProcesses, int
migrationTransactionTimeout) {
if (_contexts.dao.getDataSource() == null) {
__log.debug("No datasource available, stopping migration. Probably
running fully in-memory.");
- return false;
+ return true;
}
final int version;
@@ -67,10 +76,10 @@
}
if (version == -1) {
__log.info("No schema version available from the database, migrations
will be skipped.");
- return false;
+ return true;
}
if (version == CURRENT_SCHEMA_VERSION) return true;
-
+
try {
boolean success = _contexts.scheduler.execTransaction(new
Callable<Boolean>() {
public Boolean call() throws Exception {
@@ -91,7 +100,7 @@
return success;
}
}
- });
+ }, migrationTransactionTimeout);
return success;
} catch (Exception e) {
__log.error("An error occured while migrating your database to a newer
version of ODE, changes have " +
@@ -181,6 +190,5 @@
throw new RuntimeException(e);
}
}
-
}
}
Added:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/migration/OutstandingRequestsMigration.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/migration/OutstandingRequestsMigration.java
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/migration/OutstandingRequestsMigration.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,86 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.ode.bpel.engine.migration;
+
+import java.io.ByteArrayInputStream;
+import java.io.ByteArrayOutputStream;
+import java.io.IOException;
+import java.util.Collection;
+import java.util.Set;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+import org.apache.ode.bpel.dao.BpelDAOConnection;
+import org.apache.ode.bpel.dao.ProcessDAO;
+import org.apache.ode.bpel.dao.ProcessInstanceDAO;
+import org.apache.ode.bpel.engine.BpelProcess;
+import org.apache.ode.bpel.engine.IMAManager;
+import org.apache.ode.bpel.engine.OutstandingRequestManager;
+import org.apache.ode.jacob.vpu.ExecutionQueueImpl;
+
+/**
+ * Migrates OutstandingRequestManager to IMAManager
+ *
+ */
+public class OutstandingRequestsMigration implements Migration {
+ private static Log __log = LogFactory.getLog(OutstandingRequestsMigration.class);
+
+ public boolean migrate(Set<BpelProcess> registeredProcesses, BpelDAOConnection
connection) {
+ boolean migrationResult = true;
+ for (BpelProcess process : registeredProcesses) {
+ ProcessDAO processDao =
connection.getProcess(process.getConf().getProcessId());
+ Collection<ProcessInstanceDAO> pis = processDao.getActiveInstances();
+
+ for (ProcessInstanceDAO instance : pis) {
+ __log.debug("Migrating outstanding requests for instance " +
instance.getInstanceId());
+
+ try {
+ if (instance.getExecutionState() == null) {
+ //Completed instance
+ __log.debug("Skipped");
+ } else {
+ ExecutionQueueImpl soup = new
ExecutionQueueImpl(this.getClass().getClassLoader());
+
soup.setReplacementMap(process.getReplacementMap(processDao.getProcessId()));
+ soup.read(new
ByteArrayInputStream(instance.getExecutionState()));
+ Object data = soup.getGlobalData();
+ if (data instanceof OutstandingRequestManager) {
+ OutstandingRequestManager orm = (OutstandingRequestManager)
data;
+
+ IMAManager imaManager = new IMAManager();
+ imaManager.migrateRids(orm.getRids());
+ soup.setGlobalData(imaManager);
+
+ ByteArrayOutputStream bos = new ByteArrayOutputStream();
+ soup.write(bos);
+ instance.setExecutionState(bos.toByteArray());
+ __log.debug("Migrated outstanding requests for instance
" + instance.getInstanceId());
+ }
+ }
+ } catch (Exception e) {
+ __log.debug("", e);
+ __log.error("Error migrating outstanding requests for instance
" + instance.getInstanceId());
+ migrationResult = false;
+ }
+ }
+ }
+
+ return migrationResult;
+ }
+}
Added:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/replayer/RemainingExchangesException.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/replayer/RemainingExchangesException.java
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/replayer/RemainingExchangesException.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,46 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.ode.bpel.engine.replayer;
+
+import java.util.List;
+
+import org.apache.ode.bpel.pmapi.CommunicationType.Exchange;
+
+/**
+ * It's raised when replayed invokes don't drain out all provided communication.
+ * For example if there is invoke in process and two requests in provided communication,
this
+ * exception occurs.
+ *
+ * @author Rafal Rusin
+ *
+ */
+public class RemainingExchangesException extends Exception {
+ private static final long serialVersionUID = 1L;
+
+ public final List<Exchange> remainingExchanges;
+
+ public RemainingExchangesException(List<Exchange> remainingExchanges) {
+ this.remainingExchanges = remainingExchanges;
+ }
+
+ @Override
+ public String getMessage() {
+ return "Remaining exchanges: " + remainingExchanges.toString();
+ }
+}
Added:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/replayer/Replayer.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/replayer/Replayer.java
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/replayer/Replayer.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,281 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.ode.bpel.engine.replayer;
+
+import java.util.ArrayList;
+import java.util.Calendar;
+import java.util.Collections;
+import java.util.Comparator;
+import java.util.Date;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+
+import javax.xml.namespace.QName;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+import org.apache.ode.bpel.dao.BpelDAOConnection;
+import org.apache.ode.bpel.dao.MessageExchangeDAO;
+import org.apache.ode.bpel.dao.ProcessDAO;
+import org.apache.ode.bpel.dao.ProcessInstanceDAO;
+import org.apache.ode.bpel.engine.BpelEngineImpl;
+import org.apache.ode.bpel.engine.BpelProcess;
+import org.apache.ode.bpel.engine.MyRoleMessageExchangeImpl;
+import org.apache.ode.bpel.engine.PartnerLinkMyRoleImpl;
+import org.apache.ode.bpel.engine.WorkEvent;
+import org.apache.ode.bpel.engine.PartnerLinkMyRoleImpl.RoutingInfo;
+import org.apache.ode.bpel.evt.CorrelationMatchEvent;
+import org.apache.ode.bpel.iapi.BpelEngine;
+import org.apache.ode.bpel.iapi.MyRoleMessageExchange;
+import org.apache.ode.bpel.iapi.MessageExchange.Status;
+import org.apache.ode.bpel.iapi.ProcessConf.CLEANUP_CATEGORY;
+import org.apache.ode.bpel.pmapi.CommunicationType;
+import org.apache.ode.bpel.pmapi.ExchangeType;
+import org.apache.ode.bpel.pmapi.FaultType;
+import org.apache.ode.bpel.pmapi.GetCommunication;
+import org.apache.ode.bpel.pmapi.GetCommunicationResponse;
+import org.apache.ode.bpel.pmapi.Replay;
+import org.apache.ode.bpel.pmapi.CommunicationType.Exchange;
+import org.apache.ode.bpel.runtime.PROCESS;
+import org.apache.xmlbeans.XmlCalendar;
+import org.apache.xmlbeans.XmlException;
+import org.apache.xmlbeans.XmlObject;
+
+/**
+ * Main class used for replaying. It's invoked from InstanceManagement API.
+ * Receives request and sets up replaying contexts for each instance to replay.
+ *
+ * @author Rafal Rusin
+ *
+ */
+public class Replayer {
+ private static final Log __log = LogFactory.getLog(Replayer.class);
+ public static ThreadLocal<Replayer> replayer = new
ThreadLocal<Replayer>();
+ public ReplayerScheduler scheduler = new ReplayerScheduler();
+ public BpelEngineImpl engine = null;
+ public List<ReplayerContext> contexts = null;
+ public BpelDAOConnection conn = null;
+
+ public List<Long> replayInstances(Replay request, BpelEngine engine,
BpelDAOConnection conn) throws Exception {
+ try {
+ replayer.set(this);
+ this.engine = (BpelEngineImpl) engine;
+ this.conn = conn;
+
+ Date startDate = Calendar.getInstance().getTime();
+ contexts = new ArrayList<ReplayerContext>();
+ {
+ List<Long> toDelete = new ArrayList<Long>();
+ List<CommunicationType> toRestore = new
ArrayList<CommunicationType>();
+
+ toDelete.addAll(request.getReplaceInstanceList());
+
+ for (Long iid : request.getUpgradeInstanceList()) {
+ toDelete.add(iid);
+ toRestore.add(CommunicationType.Factory.parse(getCommunication(iid,
conn).toString()));
+ }
+ toRestore.addAll(request.getRestoreInstanceList());
+
+ {
+ Set<CLEANUP_CATEGORY> cleanupCategory = new
HashSet<CLEANUP_CATEGORY>();
+ cleanupCategory.add(CLEANUP_CATEGORY.INSTANCE);
+ cleanupCategory.add(CLEANUP_CATEGORY.MESSAGES);
+ cleanupCategory.add(CLEANUP_CATEGORY.VARIABLES);
+ cleanupCategory.add(CLEANUP_CATEGORY.CORRELATIONS);
+ cleanupCategory.add(CLEANUP_CATEGORY.EVENTS);
+
+ for (Long l : toDelete) {
+ conn.getInstance(l).delete(cleanupCategory);
+ }
+ }
+
+ for (CommunicationType r : toRestore) {
+ ReplayerContext context = new ReplayerContext(startDate);
+ context.bpelEngine = (BpelEngineImpl) engine;
+ context.init(r, scheduler);
+ contexts.add(context);
+ }
+ }
+
+ scheduler.startReplaying(this);
+ {
+ List<Exchange> remainingExchanges = new
ArrayList<Exchange>();
+
+ for (ReplayerContext c : contexts) {
+ c.answers.remainingExchanges(remainingExchanges);
+ }
+ if (remainingExchanges.size() > 0) {
+ throw new RemainingExchangesException(remainingExchanges);
+ }
+ }
+
+ List<Long> r = new ArrayList<Long>();
+ for (ReplayerContext c : contexts) {
+ r.add(c.runtimeContext.getPid());
+ }
+
+ return r;
+ } finally {
+ replayer.set(null);
+ }
+ }
+
+ public GetCommunicationResponse getCommunication(GetCommunication request,
BpelDAOConnection conn) throws Exception {
+ GetCommunicationResponse response =
GetCommunicationResponse.Factory.newInstance();
+ for (Long iid : request.getIidList()) {
+ response.addNewRestoreInstance().set(getCommunication(iid, conn));
+ }
+ return response;
+ }
+
+ private CommunicationType getCommunication(Long iid, BpelDAOConnection conn) {
+ CommunicationType result = CommunicationType.Factory.newInstance();
+ List<Exchange> list = new ArrayList<Exchange>();
+ ProcessInstanceDAO instance = conn.getInstance(iid);
+ if (instance == null)
+ return result;
+ result.setProcessType(instance.getProcess().getType());
+
+ for (String mexId : instance.getMessageExchangeIds()) {
+ MessageExchangeDAO mexDao = conn.getMessageExchange(mexId);
+
+ Exchange e = Exchange.Factory.newInstance();
+ list.add(e);
+ e.setCreateTime(new XmlCalendar(mexDao.getCreateTime()));
+ e.setOperation(mexDao.getOperation());
+ try {
+ e.setIn(XmlObject.Factory.parse(mexDao.getRequest().getData()));
+ } catch (XmlException e1) {
+ __log.error("", e1);
+ }
+ try {
+ Status status = Status.valueOf(mexDao.getStatus());
+ if (status == Status.FAULT) {
+ FaultType f = e.addNewFault();
+ f.setType(mexDao.getFault());
+ f.setExplanation(mexDao.getFaultExplanation());
+ if (mexDao.getResponse() != null) {
+
f.setMessage(XmlObject.Factory.parse(mexDao.getResponse().getData()));
+ }
+ } else if (status == Status.FAILURE) {
+ e.addNewFailure().setExplanation(mexDao.getFaultExplanation());
+ } else {
+ if (mexDao.getResponse() != null) {
+
e.setOut(XmlObject.Factory.parse(mexDao.getResponse().getData()));
+ }
+ }
+ } catch (XmlException e1) {
+ __log.error("", e1);
+ }
+ e.setType(ExchangeType.Enum.forString("" +
mexDao.getDirection()));
+
+ __log.debug("---");
+ __log.debug("" + mexDao.getCallee());
+ __log.debug("" + mexDao.getChannel());
+ __log.debug("" + mexDao.getCreateTime());
+ __log.debug("" + mexDao.getEPR());
+ __log.debug("" + mexDao.getPortType());
+
+ if (e.getType() == ExchangeType.P) {
+ e.setService(mexDao.getPortType());
+ } else {
+ e.setService(mexDao.getCallee());
+ }
+ }
+
+ Collections.sort(list, new Comparator<Exchange>() {
+ public int compare(Exchange arg0, Exchange arg1) {
+ return arg0.getCreateTime().compareTo(arg1.getCreateTime());
+ }
+ });
+
+ for (Exchange e : list) {
+ result.addNewExchange().set(e);
+ }
+ return result;
+ }
+
+ public ReplayerContext findReplayedInstance(long iid) {
+ for (ReplayerContext r : contexts) {
+ if (r.runtimeContext.getPid() == iid) {
+ return r;
+ }
+ }
+ return null;
+ }
+
+ public void handleWorkEvent(Map<String, Object> jobDetail, final Date when) {
+ WorkEvent we = new WorkEvent(jobDetail);
+ __log.debug("handleWorkEvent " + jobDetail + " " + when);
+ if (we.getType() == WorkEvent.Type.INVOKE_INTERNAL) {
+ final BpelProcess p = engine._activeProcesses.get(we.getProcessId());
+ final ProcessDAO processDAO = p.getProcessDAO();
+ final MyRoleMessageExchangeImpl mex = (MyRoleMessageExchangeImpl)
engine.getMessageExchange(we.getMexId());
+
+ p.invokeProcess(mex,
+ // time,
+ new BpelProcess.InvokeHandler() {
+ public boolean invoke(PartnerLinkMyRoleImpl target, RoutingInfo
routing, boolean createInstance) {
+ if (routing.messageRoute == null && createInstance)
{
+ __log.debug("creating new instance via live
communication mex:" + mex);
+ ProcessInstanceDAO newInstance =
processDAO.createInstance(routing.correlator);
+
+ ReplayerContext context = new ReplayerContext(null);
+ context.bpelEngine = (BpelEngineImpl) engine;
+ contexts.add(context);
+
+ ReplayerBpelRuntimeContextImpl runtimeContext = new
ReplayerBpelRuntimeContextImpl(p, newInstance, new PROCESS(p.getOProcess()), mex,
+ // time,
+ context);
+ context.runtimeContext = runtimeContext;
+ runtimeContext.setCurrentEventDateTime(when);
+ runtimeContext.updateMyRoleMex(mex);
+ // first receive is matched to provided
+ // mex
+ runtimeContext.execute();
+ return true;
+ } else if (routing.messageRoute != null) {
+ long iid =
routing.messageRoute.getTargetInstance().getInstanceId();
+ ReplayerContext ctx = findReplayedInstance(iid);
+ if (ctx == null) {
+ throw new IllegalStateException("Trying to hit
existing instance via live communication, but there's no such instance mex:" +
mex + " iid:" + iid);
+ }
+ __log.debug("hitting existing instance via live
communication mex:" + mex + " iid:" + iid);
+
+
ctx.runtimeContext.inputMsgMatch(routing.messageRoute.getGroupId(),
routing.messageRoute.getIndex(), mex);
+
routing.correlator.removeRoutes(routing.messageRoute.getGroupId(),
ctx.runtimeContext.getDAO());
+
+
mex.setCorrelationStatus(MyRoleMessageExchange.CorrelationStatus.MATCHED);
+
mex.getDAO().setInstance(routing.messageRoute.getTargetInstance());
+ ctx.runtimeContext.execute();
+ }
+ return false;
+ }
+ });
+ } else if (we.getType() == WorkEvent.Type.INVOKE_RESPONSE) {
+ __log.debug("reply for live communication");
+ ReplayerContext ctx = findReplayedInstance(we.getIID());
+ assert ctx != null;
+ ctx.runtimeContext.invocationResponse(we.getMexId(), we.getChannel());
+ ctx.runtimeContext.execute();
+ }
+ }
+}
Added:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/replayer/ReplayerBpelRuntimeContextImpl.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/replayer/ReplayerBpelRuntimeContextImpl.java
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/replayer/ReplayerBpelRuntimeContextImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,315 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.ode.bpel.engine.replayer;
+
+import java.util.Date;
+import java.util.concurrent.Callable;
+
+import javax.wsdl.Operation;
+import javax.xml.namespace.QName;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+import org.apache.ode.bpel.common.FaultException;
+import org.apache.ode.bpel.dao.MessageDAO;
+import org.apache.ode.bpel.dao.MessageExchangeDAO;
+import org.apache.ode.bpel.dao.PartnerLinkDAO;
+import org.apache.ode.bpel.dao.ProcessInstanceDAO;
+import org.apache.ode.bpel.engine.BpelEngineImpl;
+import org.apache.ode.bpel.engine.BpelProcess;
+import org.apache.ode.bpel.engine.BpelRuntimeContextImpl;
+import org.apache.ode.bpel.engine.MessageImpl;
+import org.apache.ode.bpel.engine.MyRoleMessageExchangeImpl;
+import org.apache.ode.bpel.engine.PartnerLinkMyRoleImpl;
+import org.apache.ode.bpel.engine.PartnerLinkMyRoleImpl.RoutingInfo;
+import org.apache.ode.bpel.engine.replayer.ReplayerContext.AnswerResult;
+import org.apache.ode.bpel.iapi.MessageExchange.MessageExchangePattern;
+import org.apache.ode.bpel.iapi.MessageExchange.Status;
+import org.apache.ode.bpel.pmapi.CommunicationType.Exchange;
+import org.apache.ode.bpel.runtime.PROCESS;
+import org.apache.ode.bpel.runtime.PartnerLinkInstance;
+import org.apache.ode.bpel.runtime.Selector;
+import org.apache.ode.bpel.runtime.channels.ActivityRecoveryChannel;
+import org.apache.ode.bpel.runtime.channels.FaultData;
+import org.apache.ode.bpel.runtime.channels.InvokeResponseChannel;
+import org.apache.ode.bpel.runtime.channels.PickResponseChannel;
+import org.apache.ode.bpel.runtime.channels.TimerResponseChannel;
+import org.apache.ode.jacob.JacobRunnable;
+import org.apache.ode.utils.DOMUtils;
+import org.apache.ode.utils.GUID;
+import org.apache.ode.utils.ObjectPrinter;
+import org.apache.xmlbeans.XmlObject;
+import org.apache.xmlbeans.XmlOptions;
+import org.w3c.dom.Element;
+import org.w3c.dom.Node;
+import org.w3c.dom.NodeList;
+
+/**
+ * This class intercepts invocations on BpelRuntimeContextImpl and substitutes them as
necessary during replaying.
+ * For exaple when INVOKE activity calls invoke on BpelRuntimeContextImpl then
ReplayerBpelRuntimeContextImpl intercepts this call
+ * and provides specific answer.
+ *
+ * @author Rafal Rusin
+ *
+ */
+public class ReplayerBpelRuntimeContextImpl extends BpelRuntimeContextImpl {
+ private static final Log __log =
LogFactory.getLog(ReplayerBpelRuntimeContextImpl.class);
+
+ private ReplayerContext replayerContext;
+
+ public ReplayerBpelRuntimeContextImpl(BpelProcess bpelProcess, ProcessInstanceDAO
dao, PROCESS PROCESS, MyRoleMessageExchangeImpl instantiatingMessageExchange,
ReplayerContext context) {
+ super(bpelProcess, dao, PROCESS, instantiatingMessageExchange);
+ this.replayerContext = context;
+ }
+
+ @Override
+ public void cancel(TimerResponseChannel timerResponseChannel) {
+ __log.debug("cancel " + timerResponseChannel.export());
+ super.cancel(timerResponseChannel);
+ }
+
+
+
+ @Override
+ public void checkInvokeExternalPermission() {
+ throw new IllegalStateException("Invoking external services is disabled
during replaying");
+ }
+
+ @Override
+ public String invoke(int aid, PartnerLinkInstance partnerLink, Operation operation,
Element outgoingMessage, InvokeResponseChannel channel) throws FaultException {
+ __log.debug("invoke");
+ AnswerResult answerResult =
replayerContext.answers.fetchAnswer(partnerLink.partnerLink.partnerRolePortType.getQName(),
operation.getName(), outgoingMessage, getCurrentEventDateTime());
+
+ if (answerResult.isLive) {
+ return super.invoke(aid, partnerLink, operation, outgoingMessage, channel);
+ } else {
+ PartnerLinkDAO plinkDAO = fetchPartnerLinkDAO(partnerLink);
+
+ MessageExchangeDAO mexDao =
_dao.getConnection().createMessageExchange(MessageExchangeDAO.DIR_BPEL_INVOKES_PARTNERROLE);
+
+ mexDao.setCreateTime(new Date(getCurrentEventDateTime().getTime() + 1));
+ mexDao.setOperation(operation.getName());
+ mexDao.setPortType(partnerLink.partnerLink.partnerRolePortType.getQName());
+ mexDao.setPartnerLinkModelId(partnerLink.partnerLink.getId());
+ mexDao.setPartnerLink(plinkDAO);
+ mexDao.setPattern((operation.getOutput() != null ?
MessageExchangePattern.REQUEST_RESPONSE :
MessageExchangePattern.REQUEST_ONLY).toString());
+ mexDao.setProcess(_dao.getProcess());
+ mexDao.setInstance(_dao);
+ {
+ MessageDAO request = mexDao.createMessage(new QName("replayer",
"replayer"));
+ request.setData(outgoingMessage);
+ // try {
+ // assign(request, answer.getIn());
+ // } catch (Exception e) {
+ // throw new FaultException(new QName("replayer",
"replayer"), e);
+ // }
+ mexDao.setRequest(request);
+ }
+
+ Exchange answer = answerResult.e;
+
+ if
(mexDao.getPattern().equals(MessageExchangePattern.REQUEST_RESPONSE.toString())) {
+ if (answer.isSetFault()) {
+ MessageDAO response = mexDao.createMessage(new
QName("replayer", "replayer"));
+ try {
+ assign(response, answer.getFault());
+ } catch (Exception e) {
+ throw new FaultException(new QName("replayer",
"replayer"), e);
+ }
+ mexDao.setResponse(response);
+ mexDao.setFault(answer.getFault().getType());
+ mexDao.setFaultExplanation(answer.getFault().getExplanation());
+ mexDao.setStatus(Status.FAULT.toString());
+
+ } else if (answer.isSetOut()) {
+ MessageDAO response = mexDao.createMessage(new
QName("replayer", "replayer"));
+ try {
+ assign(response, answer.getOut());
+ } catch (Exception e) {
+ throw new FaultException(new QName("replayer",
"replayer"), e);
+ }
+ mexDao.setResponse(response);
+ mexDao.setStatus(Status.RESPONSE.toString());
+ } else if (answer.isSetFailure()) {
+ mexDao.setFaultExplanation(answer.getFailure().getExplanation());
+ mexDao.setStatus(Status.FAILURE.toString());
+ } else {
+ // We don't have output for in-out operation - resulting with
+ // replayer error to the top
+ throw new IllegalStateException("I don't have response for
invoke " + answer);
+ }
+
+ final String channel2 = channel.export();
+ final String mexid = mexDao.getMessageExchangeId();
+ replayerContext.scheduler.scheduleReplayerJob(new Callable() {
+ public Object call() throws Exception {
+ __log.debug("executing invoke response " + channel2);
+ invocationResponse(mexid, channel2);
+ execute();
+ return null;
+ }
+ }, getCurrentEventDateTime(), this);
+ } else {
+ // in only - continuing
+ mexDao.setStatus(Status.COMPLETED_OK.toString());
+ }
+
+ return mexDao.getMessageExchangeId();
+ }
+ }
+
+ public static class TimerResume extends JacobRunnable {
+ private static final long serialVersionUID = 198476512L;
+
+ private final String channelId;
+
+ public TimerResume(String channelId) {
+ super();
+ this.channelId = channelId;
+ }
+
+ @Override
+ public void run() {
+ importChannel(channelId, TimerResponseChannel.class).onTimeout();
+ }
+ }
+
+ @Override
+ public void registerTimer(final TimerResponseChannel timerChannel, final Date
timeToFire) {
+ __log.debug("register timer " + timerChannel + " " +
timeToFire);
+ final String channel = timerChannel.export();
+
+ if (timeToFire.before(replayerContext.replayStartDate)) {
+ replayerContext.scheduler.scheduleReplayerJob(new Callable() {
+ public Object call() throws Exception {
+ __log.debug("executing timer resume " + timerChannel +
" " + timeToFire);
+ timerEvent(channel);
+ return null;
+ }
+ }, timeToFire, this);
+ } else {
+ super.registerTimer(timerChannel, timeToFire);
+ }
+ }
+
+
+ @Override
+ public void registerActivityForRecovery(ActivityRecoveryChannel channel, long
activityId, String reason, Date dateTime, Element details, String[] actions, int retries)
{
+ super.registerActivityForRecovery(channel, activityId, reason, dateTime, details,
actions, retries);
+ replayerContext.checkRollbackOnFault();
+ }
+
+ @Override
+ public void completedFault(FaultData faultData) {
+ super.completedFault(faultData);
+ replayerContext.checkRollbackOnFault();
+ }
+
+ @Override
+ public void reply(PartnerLinkInstance plinkInstnace, String opName, String mexId,
Element msg, QName fault) throws FaultException {
+ String mexRef = _imaManager.release(plinkInstnace, opName, mexId);
+
+ if (mexRef == null) {
+ throw new
FaultException(_bpelProcess.getOProcess().constants.qnMissingRequest);
+ }
+
+ MessageExchangeDAO mex = _dao.getConnection().getMessageExchange(mexRef);
+
+ String pipedId = mex.getPipedMessageExchangeId();
+ if (pipedId != null) {
+ __log.debug("instance replied for live communication:" + mexRef +
" " + DOMUtils.domToString(msg));
+ super.reply2(plinkInstnace, opName, mexId, msg, fault, false, mexRef);
+ } else {
+ MessageDAO message =
mex.createMessage(plinkInstnace.partnerLink.getMyRoleOperation(opName).getOutput().getMessage().getQName());
+ buildOutgoingMessage(message, msg);
+
+ __log.debug("instance replied mexRef:" + mexRef + " " +
DOMUtils.domToString(msg));
+ mex.setResponse(message);
+ mex.setStatus(Status.RESPONSE.toString());
+ }
+ }
+
+ @Override
+ public void select(PickResponseChannel pickResponseChannel, Date timeout, boolean
createInstance, Selector[] selectors) throws FaultException {
+ super.select(pickResponseChannel, timeout, createInstance, selectors);
+ __log.debug("select " + pickResponseChannel + " " +
ObjectPrinter.toString(selectors, selectors));
+ }
+
+
+ public ProcessInstanceDAO getDAO() {
+ return _dao;
+ }
+
+ public static MyRoleMessageExchangeImpl createMyRoleMex(Exchange e, BpelEngineImpl
engine) throws Exception {
+ MyRoleMessageExchangeImpl mex = (MyRoleMessageExchangeImpl)
engine.createMessageExchange(new GUID().toString(), e.getService(), e.getOperation());
+ mex.getDAO().setCreateTime(e.getCreateTime().getTime());
+
+ MessageImpl m2 = (MessageImpl) mex.createMessage(new QName("replayer",
"replayer"));
+ assign(m2._dao, e.getIn());
+ mex.getDAO().setRequest(m2._dao);
+ mex.getDAO().setStatus(Status.REQUEST.toString());
+ return mex;
+ }
+
+ public void updateMyRoleMex(MyRoleMessageExchangeImpl m) {
+ m.getDAO().setProcess(_dao.getProcess());
+ m.getDAO().setInstance(_dao);
+ }
+
+ public static void assign(MessageDAO m, XmlObject o) throws Exception {
+ NodeList nodes = DOMUtils.parse(o.newInputStream(new
XmlOptions().setSaveOuter())).getDocumentElement().getChildNodes();
+ for (int i = 0; i < nodes.getLength(); i++) {
+ Node n = nodes.item(i);
+ if (n instanceof Element) {
+ m.setData((Element) n);
+ }
+ }
+ }
+
+ public void handleIncomingRequest(final MyRoleMessageExchangeImpl mex, final Date
currentEventDateTime) {
+ __log.debug("handleIncomingRequest for mock communication " + mex);
+
+ setCurrentEventDateTime(currentEventDateTime);
+
+ _bpelProcess.invokeProcess(mex, new BpelProcess.InvokeHandler() {
+ public boolean invoke(PartnerLinkMyRoleImpl target, RoutingInfo routing,
boolean createInstance) {
+ if (routing.messageRoute == null && createInstance) {
+ // No route but we can create a new instance
+ throw new IllegalStateException("Mock type M mex caused creation
of new instance " + mex);
+ } else if (routing.messageRoute != null) {
+ if
(!routing.messageRoute.getTargetInstance().getInstanceId().equals(_dao.getInstanceId()))
{
+ throw new IllegalStateException("Routed target instance is
not equal to replayed instance");
+ }
+ // Found a route, hitting it
+ inputMsgMatch(routing.messageRoute.getGroupId(),
routing.messageRoute.getIndex(), mex);
+
+ // Kill the route so some new message does not get routed to
+ // same process instance.
+ routing.correlator.removeRoutes(routing.messageRoute.getGroupId(),
_dao);
+
+ execute();
+ return true;
+ }
+ return false;
+ }
+ });
+
+ }
+
+}
Added:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/replayer/ReplayerContext.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/replayer/ReplayerContext.java
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/replayer/ReplayerContext.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,327 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.ode.bpel.engine.replayer;
+
+import java.util.ArrayList;
+import java.util.Date;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.concurrent.Callable;
+
+import javax.xml.namespace.QName;
+import javax.xml.xquery.XQConnection;
+import javax.xml.xquery.XQConstants;
+import javax.xml.xquery.XQDataSource;
+import javax.xml.xquery.XQPreparedExpression;
+import javax.xml.xquery.XQResultSequence;
+
+import net.sf.saxon.xqj.SaxonXQConnection;
+import net.sf.saxon.xqj.SaxonXQDataSource;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+import org.apache.ode.bpel.dao.ProcessDAO;
+import org.apache.ode.bpel.dao.ProcessInstanceDAO;
+import org.apache.ode.bpel.engine.BpelEngineImpl;
+import org.apache.ode.bpel.engine.BpelProcess;
+import org.apache.ode.bpel.engine.MyRoleMessageExchangeImpl;
+import org.apache.ode.bpel.engine.PartnerLinkMyRoleImpl;
+import org.apache.ode.bpel.engine.PartnerLinkMyRoleImpl.RoutingInfo;
+import org.apache.ode.bpel.iapi.MessageExchange.Status;
+import org.apache.ode.bpel.pmapi.CommunicationType;
+import org.apache.ode.bpel.pmapi.ExchangeType;
+import org.apache.ode.bpel.pmapi.MockQueryRequestDocument;
+import org.apache.ode.bpel.pmapi.MockQueryResponseDocument;
+import org.apache.ode.bpel.pmapi.ResponseType;
+import org.apache.ode.bpel.pmapi.CommunicationType.Exchange;
+import org.apache.ode.bpel.pmapi.CommunicationType.ServiceConfig;
+import org.apache.ode.bpel.runtime.PROCESS;
+import org.apache.ode.utils.DOMUtils;
+import org.apache.xmlbeans.XmlAnySimpleType;
+import org.apache.xmlbeans.XmlObject;
+import org.apache.xmlbeans.XmlOptions;
+import org.w3c.dom.Element;
+import org.w3c.dom.Node;
+
+/**
+ * Context holding replayer state (eg. invoke answers) for single instance during
replaying.
+ *
+ * @author Rafal Rusin
+ *
+ */
+public class ReplayerContext {
+ private static final Log __log = LogFactory.getLog(ReplayerContext.class);
+
+ public ReplayerScheduler scheduler;
+
+ public BpelEngineImpl bpelEngine;
+ public ReplayerBpelRuntimeContextImpl runtimeContext;
+
+ public Map<QName, ServiceConfig> servicesConfig = new HashMap<QName,
ServiceConfig>();
+ public CommunicationType replayerConfig;
+
+ public final Date replayStartDate;
+
+ public Answers answers = new Answers();
+
+ public class Answers {
+ public Map<String, AnswersForKey> answersMap = new HashMap<String,
AnswersForKey>();
+
+ public String getAnswersKey(QName service, String operation) {
+ return service.toString() + ";" + operation;
+ }
+
+ public void add(Exchange e) {
+ ServiceConfig cfg = getServiceConfig(e.getService());
+ if (cfg.getReplayType().isSetMock()) {
+ String key = getAnswersKey(e.getService(), e.getOperation());
+ AnswersForKey v = answersMap.get(key);
+ if (v == null) {
+ v = new AnswersForKey();
+ answersMap.put(key, v);
+ }
+ v.answers.add(e);
+ }
+ }
+
+ public AnswerResult fetchAnswer(QName service, String operation, Element
outgoingMessage, Date currentEventDateTime) {
+ __log.debug("fetching answer for " + service + " " +
operation);
+
+ ServiceConfig cfg = getServiceConfig(service);
+
+ if (cfg.getReplayType().isSetMock()) {
+ String key = getAnswersKey(service, operation);
+ AnswersForKey v = answersMap.get(key);
+ Exchange e = v == null ? null : v.answerPos < v.answers.size() ?
v.answers.get(v.answerPos) : null;
+ if (e == null) {
+ throw new IllegalStateException("answer for " + service +
" " + operation + " at time " + currentEventDateTime + " not
found, outgoing message was " + DOMUtils.domToString(outgoingMessage));
+ }
+ v.answerPos++;
+ __log.debug("fetched " + e);
+ return new AnswerResult(false, e);
+ } else if (cfg.getReplayType().isSetMockQuery()) {
+ return new AnswerResult(false, fetchMockQuery(service, operation,
outgoingMessage, cfg));
+ } else if (cfg.getReplayType().isSetLive()) {
+ return new AnswerResult(true, null);
+ } else assert(false);
+ return null;
+ }
+
+ public void remainingExchanges(List<Exchange> e) {
+ for (AnswersForKey v : answersMap.values()) {
+ v.remainingExchanges(e);
+ }
+ }
+
+ private Exchange fetchMockQuery(QName service, String operation, Element
outgoingMessage, org.apache.ode.bpel.pmapi.CommunicationType.ServiceConfig serviceConfig)
{
+ try {
+ MockQueryRequestDocument request =
MockQueryRequestDocument.Factory.newInstance();
+
request.addNewMockQueryRequest().addNewIn().set(XmlObject.Factory.parse(outgoingMessage));
+ String xquery = serviceConfig.getReplayType().getMockQuery();
+
+ XQDataSource xqds = new SaxonXQDataSource();
+ XQConnection xqconn = xqds.getConnection();
+
+ net.sf.saxon.Configuration configuration = ((SaxonXQConnection)
xqconn).getConfiguration();
+ configuration.setHostLanguage(net.sf.saxon.Configuration.XQUERY);
+// XQStaticContext staticEnv = xqconn.getStaticContext();
+ XQPreparedExpression exp = xqconn.prepareExpression(xquery);
+ Node requestNode = DOMUtils.parse(request.newXMLStreamReader());
+ if (__log.isDebugEnabled()) {
+ __log.debug("request " + request.toString());
+ }
+ exp.bindItem(XQConstants.CONTEXT_ITEM,
xqconn.createItemFromNode(requestNode, xqconn.createNodeType()));
+ XQResultSequence result = exp.executeQuery();
+ MockQueryResponseDocument response =
MockQueryResponseDocument.Factory.parse(result.getSequenceAsStream());
+ {
+ XmlOptions opts = new XmlOptions();
+ List<Object> errors = new ArrayList<Object>();
+ opts.setErrorListener(errors);
+ if (!response.validate(opts)) {
+ __log.error("MockQuery response doesn't validate.
Errors: " + errors + " Request: " + request.toString() + " Response:
" + response.toString(), new Exception());
+ throw new IllegalStateException("MockQuery response
doesn't validate.");
+ }
+ }
+ ResponseType response2 = response.getMockQueryResponse();
+
+ if (__log.isDebugEnabled()) {
+ __log.debug("mockQuery result " + response);
+ }
+
+
+ Exchange answer = Exchange.Factory.newInstance();
+ {
+ if (response2.isSetOut()) {
+ answer.setOut(response2.getOut());
+ }
+ if (response2.isSetFault()) {
+ answer.setFault(response2.getFault());
+ }
+ if (response2.isSetFailure()) {
+ answer.setFailure(response2.getFailure());
+ }
+ }
+
+ return answer;
+ } catch (Exception e) {
+ __log.error("", e);
+ __log.error(e.getCause());
+ throw new IllegalStateException(e.getMessage());
+ }
+ }
+ }
+
+ public static class AnswersForKey {
+ List<Exchange> answers = new ArrayList<Exchange>();
+ int answerPos = 0;
+
+ public boolean isCompleted() {
+ return !(answerPos < answers.size());
+ }
+
+ public void remainingExchanges(List<Exchange> e) {
+ for (int i = answerPos; i < answers.size(); i++) {
+ e.add(answers.get(i));
+ }
+ }
+
+ @Override
+ public String toString() {
+ return new Integer(answerPos).toString() + " / " + answers.size();
+ }
+ }
+
+ private void scheduleInvoke(final Exchange e, final MyRoleMessageExchangeImpl mex) {
+ final Date time = e.getCreateTime().getTime();
+ scheduler.scheduleReplayerJob(new Callable<Void>() {
+ public Void call() throws Exception {
+ __log.debug("call " + e);
+ mex.getDAO().setStatus(Status.ASYNC.toString());
+ runtimeContext.handleIncomingRequest(mex, time);
+ return null;
+ }
+ }, time, runtimeContext);
+ }
+
+ public void init(final CommunicationType r, ReplayerScheduler scheduler) throws
Exception {
+ this.scheduler = scheduler;
+
+ replayerConfig = r;
+
+ for (ServiceConfig s : r.getServiceConfigList()) {
+ servicesConfig.put(s.getService(), s);
+ }
+
+ final List<Exchange> exchangeList = r.getExchangeList();
+
+ for (int i = 1; i < exchangeList.size(); i++) {
+ Exchange e = exchangeList.get(i);
+ // We skip failures, because INVOKE_CHECK job is not handled by
+ // replayer
+ if (e.getType() == ExchangeType.P && !e.isSetFailure()) {
+ answers.add(e);
+ }
+ }
+
+ {
+ final Exchange e = exchangeList.get(0);
+
+ final Date time = e.getCreateTime().getTime();
+ scheduler.scheduleReplayerJob(new Callable<Void>() {
+ public Void call() throws Exception {
+ __log.debug("initial call " + e);
+
+ final BpelProcess p =
bpelEngine.getNewestProcessByType(r.getProcessType());
+ final ProcessDAO processDAO = p.getProcessDAO();
+ final MyRoleMessageExchangeImpl mex =
ReplayerBpelRuntimeContextImpl.createMyRoleMex(e, bpelEngine);
+
+ p.invokeProcess(mex,
+ // time,
+ new BpelProcess.InvokeHandler() {
+ public boolean invoke(PartnerLinkMyRoleImpl target,
RoutingInfo routing, boolean createInstance) {
+ if (routing.messageRoute == null &&
createInstance) {
+ ProcessInstanceDAO newInstance =
processDAO.createInstance(routing.correlator);
+
+ runtimeContext = new
ReplayerBpelRuntimeContextImpl(p, newInstance, new PROCESS(p.getOProcess()), mex,
+ // time,
+ ReplayerContext.this);
+ runtimeContext.setCurrentEventDateTime(time);
+ runtimeContext.updateMyRoleMex(mex);
+ // first receive is matched to provided
+ // mex
+ runtimeContext.execute();
+ return true;
+ } else if (routing.messageRoute != null) {
+ throw new
IllegalStateException("Instantiating mex causes invocation of existing instance
" + mex);
+ }
+ return false;
+ }
+ });
+
+ for (int i = 1; i < exchangeList.size(); i++) {
+ Exchange e2 = exchangeList.get(i);
+ if (e2.getType() == ExchangeType.M) {
+ MyRoleMessageExchangeImpl mex2 =
ReplayerBpelRuntimeContextImpl.createMyRoleMex(e2, bpelEngine);
+ runtimeContext.updateMyRoleMex(mex2);
+ scheduleInvoke(e2, mex2);
+ }
+ }
+ return null;
+ }
+ }, time, null);
+ }
+
+ }
+
+ public ReplayerContext(Date replayStartDate) {
+ super();
+ this.replayStartDate = replayStartDate;
+ }
+
+ public ServiceConfig getServiceConfig(QName service) {
+ ServiceConfig c = servicesConfig.get(service);
+ if (c == null) {
+ c = ServiceConfig.Factory.newInstance();
+ c.setService(service);
+ c.addNewReplayType().setMock(XmlAnySimpleType.Factory.newInstance());
+ return c;
+ } else return c;
+ }
+
+ public void checkRollbackOnFault() {
+ if (replayerConfig.getRollbackOnFault()) {
+ RuntimeException e = new RuntimeException("Process instance run into
fault.");
+ if (__log.isDebugEnabled()) {
+ __log.debug("", e);
+ }
+ throw e;
+ }
+ }
+
+ public static class AnswerResult {
+ public final boolean isLive;
+ public final Exchange e;
+ public AnswerResult(boolean isLive, Exchange e) {
+ super();
+ this.isLive = isLive;
+ this.e = e;
+ }
+ }
+}
Added:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/replayer/ReplayerScheduler.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/replayer/ReplayerScheduler.java
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/replayer/ReplayerScheduler.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,159 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.ode.bpel.engine.replayer;
+
+import java.util.Date;
+import java.util.Map;
+import java.util.PriorityQueue;
+import java.util.concurrent.Callable;
+import java.util.concurrent.Future;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+import org.apache.ode.bpel.dao.BpelDAOConnection;
+import org.apache.ode.bpel.iapi.ContextException;
+import org.apache.ode.bpel.iapi.Scheduler;
+
+/**
+ * Manages events invocation in sorted order during replaying.
+ *
+ * @author Rafal Rusin
+ *
+ */
+public class ReplayerScheduler implements Scheduler {
+ private static final Log __log = LogFactory.getLog(ReplayerScheduler.class);
+
+ public Replayer replayer;
+
+ public static ThreadLocal<TaskElement> currentTaskElement = new
ThreadLocal<TaskElement>();
+
+ private PriorityQueue<TaskElement> taskQueue = new
PriorityQueue<TaskElement>();
+
+ private static class TaskElement implements Comparable<TaskElement> {
+ public final Date when;
+ public final Callable<Object> action;
+ public final ReplayerBpelRuntimeContextImpl runtimeContext;
+
+ public TaskElement(Date when, Callable<Object> action,
ReplayerBpelRuntimeContextImpl runtimeContext) {
+ super();
+ this.when = when;
+ this.action = action;
+ this.runtimeContext = runtimeContext;
+ }
+
+ public int compareTo(TaskElement o) {
+ return when.compareTo(o.when);
+ }
+ }
+
+ public void scheduleReplayerJob(Callable action, Date when,
ReplayerBpelRuntimeContextImpl runtimeContext) {
+ taskQueue.add(new TaskElement(when, action, runtimeContext));
+ }
+
+ public void cancelJob(String jobId) throws ContextException {
+ throw new IllegalStateException();
+ }
+
+ public <T> T execTransaction(Callable<T> transaction) throws Exception,
ContextException {
+ throw new IllegalStateException();
+ }
+
+ public <T> T execTransaction(Callable<T> transaction, int timeout) throws
Exception, ContextException {
+ throw new IllegalStateException();
+ }
+
+ public boolean isTransacted() {
+ return true;
+ }
+
+ public void registerSynchronizer(Synchronizer synch) throws ContextException {
+ throw new IllegalStateException();
+ }
+
+ public void setJobProcessor(JobProcessor processor) throws ContextException {
+ throw new IllegalStateException();
+ }
+
+ public void setRollbackOnly() throws Exception {
+ throw new IllegalStateException();
+ }
+
+ public void shutdown() {
+ }
+
+ public void startReplaying(Replayer replayer) throws Exception {
+ this.replayer = replayer;
+ while (!taskQueue.isEmpty()) {
+ TaskElement taskElement = taskQueue.remove();
+
+ try {
+ currentTaskElement.set(taskElement);
+ __log.debug("executing action at time " + taskElement.when);
+ if (taskElement.runtimeContext != null) {
+
taskElement.runtimeContext.setCurrentEventDateTime(taskElement.when);
+ }
+ taskElement.action.call();
+ } finally {
+ currentTaskElement.set(null);
+ }
+ }
+ }
+
+ public void stop() {
+ }
+
+ public void start() {
+ }
+
+ public <T> Future<T> execIsolatedTransaction(Callable<T>
transaction) throws Exception, ContextException {
+ return null;
+ }
+
+ public String scheduleMapSerializableRunnable(MapSerializableRunnable runnable, Date
when) throws ContextException {
+ return null;
+ }
+
+ public String schedulePersistedJob(final Map<String, Object> jobDetail, final
Date when1) throws ContextException {
+ final Date when = when1 == null ? currentTaskElement.get().when : when1;
+ __log.debug("schedulePersistedJob " + jobDetail + " " + when,
new Exception());
+ scheduleReplayerJob(new Callable<Void>() {
+ public Void call() throws Exception {
+ replayer.handleWorkEvent(jobDetail, when);
+ return null;
+ }
+ }, when, null);
+
+ return null;
+ }
+
+ public void setPolledRunnableProcesser(JobProcessor polledRunnableProcessor) {
+ }
+
+ public String scheduleVolatileJob(boolean transacted, Map<String, Object>
jobDetail, Date when) throws ContextException {
+ // TODO Auto-generated method stub
+ __log.debug("scheduleVolatileJob");
+ return null;
+ }
+
+ public String scheduleVolatileJob(boolean transacted, Map<String, Object>
jobDetail) throws ContextException {
+ // TODO Auto-generated method stub
+ __log.debug("scheduleVolatileJob");
+ return null;
+ }
+}
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/extvar/jdbc/JdbcExternalVariableModule.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/extvar/jdbc/JdbcExternalVariableModule.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/extvar/jdbc/JdbcExternalVariableModule.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -109,13 +109,17 @@
throw new ExternalVariableModuleException("No valid data source
configuration for JDBC external varible " + evarId);
}
- Connection conn;
+ Connection conn = null;
DatabaseMetaData metaData;
try {
conn = ds.getConnection();
- conn.setAutoCommit(false);
metaData = conn.getMetaData();
} catch (Exception ex) {
+ try {
+ if (conn != null) conn.close();
+ } catch (SQLException e) {
+ // ignore
+ }
throw new ExternalVariableModuleException("Unable to open database
connection for external variable " + evarId, ex);
}
@@ -217,13 +221,7 @@
throw new ExternalVariableModuleException("External variable "
+ evarId + " did not have any <column> elements!");
_vars.put(evarId, dbev);
-
- conn.commit();
} catch (SQLException se) {
- try {
- conn.rollback();
- } catch (SQLException e) {
- }
throw new ExternalVariableModuleException("SQL Error", se);
} finally {
try {
@@ -355,7 +353,11 @@
return stmt.executeUpdate();
} finally {
if (stmt != null) stmt.close();
- conn.close();
+ try {
+ conn.close();
+ } catch (SQLException e) {
+ // ignore
+ }
}
}
@@ -526,7 +528,11 @@
}
} finally {
if (stmt != null) stmt.close();
- conn.close();
+ try {
+ conn.close();
+ } catch (SQLException e) {
+ // ignore
+ }
}
return ret;
@@ -586,7 +592,11 @@
return keys;
} finally {
if (stmt != null) stmt.close();
- conn.close();
+ try {
+ conn.close();
+ } catch (SQLException e) {
+ // ignore
+ }
}
}
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/memdao/CorrelatorDaoImpl.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/memdao/CorrelatorDaoImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/memdao/CorrelatorDaoImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -134,7 +134,6 @@
});
}
-
public boolean checkRoute(CorrelationKey ckey) {
return true;
}
@@ -183,4 +182,8 @@
}
}
+ public boolean checkRoute(CorrelationKeySet correlationKeySet) {
+ return true;
+ }
+
}
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/memdao/MessageExchangeDAOImpl.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/memdao/MessageExchangeDAOImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/memdao/MessageExchangeDAOImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -36,160 +36,164 @@
public class MessageExchangeDAOImpl extends DaoBaseImpl implements MessageExchangeDAO {
private String messageExchangeId;
- private MessageDAO response;
- private Date createTime;
- private MessageDAO request;
- private String operation;
- private QName portType;
- private String status;
- private int partnerLinkModelId;
- private String correlationId;
- private String pattern;
- private Element ePR;
- private Element callbackEPR;
- private String channel;
- private boolean propagateTransactionFlag;
- private QName fault;
+ private MessageDAO response;
+ private Date createTime;
+ private MessageDAO request;
+ private String operation;
+ private QName portType;
+ private String status;
+ private int partnerLinkModelId;
+ private String correlationId;
+ private String pattern;
+ private Element ePR;
+ private Element callbackEPR;
+ private String channel;
+ private boolean propagateTransactionFlag;
+ private QName fault;
private String faultExplanation;
private String correlationStatus;
- private ProcessDAO process;
- private ProcessInstanceDAO instance;
- private char direction;
- private QName callee;
- private Properties properties = new Properties();
+ private ProcessDAO process;
+ private ProcessInstanceDAO instance;
+ private char direction;
+ private QName callee;
+ private Properties properties = new Properties();
private PartnerLinkDAOImpl _plink;
private String pipedMessageExchangeId;
private int subscriberCount;
- public MessageExchangeDAOImpl(char direction, String messageEchangeId){
- this.direction = direction;
- this.messageExchangeId = messageEchangeId;
+ public MessageExchangeDAOImpl(char direction, String messageEchangeId){
+ this.direction = direction;
+ this.messageExchangeId = messageEchangeId;
}
-
- public String getMessageExchangeId() {
- return messageExchangeId;
- }
+
+ public String getMessageExchangeId() {
+ return messageExchangeId;
+ }
- public MessageDAO getResponse() {
- return response;
- }
+ public MessageDAO getResponse() {
+ return response;
+ }
- public Date getCreateTime() {
- return createTime;
- }
+ public Date getCreateTime() {
+ return createTime;
+ }
- public MessageDAO getRequest() {
- return request;
- }
+ public void setCreateTime(Date d) {
+ createTime = d;
+ }
- public String getOperation() {
- return operation;
- }
+ public MessageDAO getRequest() {
+ return request;
+ }
- public QName getPortType() {
- return portType;
- }
+ public String getOperation() {
+ return operation;
+ }
- public void setPortType(QName porttype) {
- this.portType = porttype;
+ public QName getPortType() {
+ return portType;
+ }
- }
+ public void setPortType(QName porttype) {
+ this.portType = porttype;
- public void setStatus(String status) {
- this.status = status;
+ }
- }
+ public void setStatus(String status) {
+ this.status = status;
- public String getStatus() {
- return status;
- }
+ }
- public MessageDAO createMessage(QName type) {
- MessageDAO messageDAO = new MessageDAOImpl(this);
- messageDAO.setType(type);
- return messageDAO;
- }
+ public String getStatus() {
+ return status;
+ }
- public void setRequest(MessageDAO msg) {
- this.request = msg;
+ public MessageDAO createMessage(QName type) {
+ MessageDAO messageDAO = new MessageDAOImpl(this);
+ messageDAO.setType(type);
+ return messageDAO;
+ }
- }
+ public void setRequest(MessageDAO msg) {
+ this.request = msg;
- public void setResponse(MessageDAO msg) {
- this.response = msg;
+ }
- }
+ public void setResponse(MessageDAO msg) {
+ this.response = msg;
- public int getPartnerLinkModelId() {
- return partnerLinkModelId;
- }
+ }
- public void setPartnerLinkModelId(int modelId) {
- this.partnerLinkModelId = modelId;
+ public int getPartnerLinkModelId() {
+ return partnerLinkModelId;
+ }
- }
+ public void setPartnerLinkModelId(int modelId) {
+ this.partnerLinkModelId = modelId;
- public String getCorrelationId() {
- return correlationId;
- }
+ }
- public void setCorrelationId(String correlationId) {
- this.correlationId = correlationId;
+ public String getCorrelationId() {
+ return correlationId;
+ }
- }
+ public void setCorrelationId(String correlationId) {
+ this.correlationId = correlationId;
- public void setPattern(String string) {
- this.pattern = string;
+ }
- }
+ public void setPattern(String string) {
+ this.pattern = string;
- public void setOperation(String opname) {
- this.operation = opname;
+ }
- }
+ public void setOperation(String opname) {
+ this.operation = opname;
- public void setEPR(Element epr) {
- this.ePR = epr;
+ }
- }
+ public void setEPR(Element epr) {
+ this.ePR = epr;
- public Element getEPR() {
- return ePR;
- }
+ }
- public void setCallbackEPR(Element epr) {
- this.callbackEPR = epr;
+ public Element getEPR() {
+ return ePR;
+ }
- }
+ public void setCallbackEPR(Element epr) {
+ this.callbackEPR = epr;
- public Element getCallbackEPR() {
- return callbackEPR;
- }
+ }
- public String getPattern() {
- return pattern;
- }
+ public Element getCallbackEPR() {
+ return callbackEPR;
+ }
- public String getChannel() {
- return channel;
- }
+ public String getPattern() {
+ return pattern;
+ }
- public void setChannel(String string) {
- this.channel = string;
- }
+ public String getChannel() {
+ return channel;
+ }
- public boolean getPropagateTransactionFlag() {
- return propagateTransactionFlag;
- }
+ public void setChannel(String string) {
+ this.channel = string;
+ }
- public QName getFault() {
- return fault;
- }
+ public boolean getPropagateTransactionFlag() {
+ return propagateTransactionFlag;
+ }
- public void setFault(QName faultType) {
- this.fault = faultType;
- }
+ public QName getFault() {
+ return fault;
+ }
+ public void setFault(QName faultType) {
+ this.fault = faultType;
+ }
+
public String getFaultExplanation() {
return faultExplanation;
}
@@ -201,51 +205,51 @@
public void setCorrelationStatus(String cstatus) {
- this.correlationStatus = cstatus;
- }
+ this.correlationStatus = cstatus;
+ }
- public String getCorrelationStatus() {
- return correlationStatus;
- }
+ public String getCorrelationStatus() {
+ return correlationStatus;
+ }
- public ProcessDAO getProcess() {
- return process;
- }
+ public ProcessDAO getProcess() {
+ return process;
+ }
- public void setProcess(ProcessDAO process) {
- this.process = process;
+ public void setProcess(ProcessDAO process) {
+ this.process = process;
- }
+ }
- public void setInstance(ProcessInstanceDAO dao) {
- this.instance = dao;
+ public void setInstance(ProcessInstanceDAO dao) {
+ this.instance = dao;
- }
+ }
- public ProcessInstanceDAO getInstance() {
- return instance;
- }
+ public ProcessInstanceDAO getInstance() {
+ return instance;
+ }
- public char getDirection() {
- return direction;
- }
+ public char getDirection() {
+ return direction;
+ }
- public QName getCallee() {
- return callee;
- }
+ public QName getCallee() {
+ return callee;
+ }
- public void setCallee(QName callee) {
- this.callee = callee;
+ public void setCallee(QName callee) {
+ this.callee = callee;
- }
+ }
- public String getProperty(String key) {
- return properties.getProperty(key);
- }
+ public String getProperty(String key) {
+ return properties.getProperty(key);
+ }
- public void setProperty(String key, String value) {
- properties.setProperty(key,value);
- }
+ public void setProperty(String key, String value) {
+ properties.setProperty(key,value);
+ }
public void setPartnerLink(PartnerLinkDAO plinkDAO) {
_plink = (PartnerLinkDAOImpl) plinkDAO;
@@ -272,18 +276,18 @@
this.pipedMessageExchangeId = pipedMessageExchangeId;
}
- public int getSubscriberCount() {
- return subscriberCount;
- }
-
- public void setSubscriberCount(int subscriberCount) {
- this.subscriberCount = subscriberCount;
- }
+ public int getSubscriberCount() {
+ return subscriberCount;
+ }
+
+ public void setSubscriberCount(int subscriberCount) {
+ this.subscriberCount = subscriberCount;
+ }
- public void incrementSubscriberCount() {
- ++subscriberCount;
- }
-
+ public void incrementSubscriberCount() {
+ ++subscriberCount;
+ }
+
public void release(boolean doClean) {
instance = null;
process = null;
@@ -294,7 +298,7 @@
}
public void releasePremieMessages() {
- // do nothing; early messages are deleted during
CorrelatorDaoImpl().dequeueMessage()
+ // do nothing; early messages are deleted during
CorrelatorDaoImpl().dequeueMessage()
}
public String toString() {
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/memdao/ProcessInstanceDaoImpl.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/memdao/ProcessInstanceDaoImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/memdao/ProcessInstanceDaoImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -280,6 +280,10 @@
}
public void delete(Set<CLEANUP_CATEGORY> cleanupCategories) {
+ delete(cleanupCategories, true);
+ }
+
+ public void delete(Set<CLEANUP_CATEGORY> cleanupCategories, boolean
deleteMyRoleMex) {
_processDao._instances.remove(_instanceId);
}
@@ -407,4 +411,8 @@
public String toString() {
return "mem.instance(type=" + _processDao.getType() + " iid="
+ _instanceId + ")";
}
+
+ public Collection<String> getMessageExchangeIds() {
+ return _messageExchanges.keySet();
+ }
}
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/memdao/ProcessManagementDaoImpl.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/memdao/ProcessManagementDaoImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/memdao/ProcessManagementDaoImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -21,11 +21,16 @@
import java.util.Collection;
import java.util.Date;
+import java.util.HashMap;
+import java.util.Map;
+import java.util.Set;
+import javax.xml.namespace.QName;
import org.apache.ode.bpel.common.InstanceFilter;
import org.apache.ode.bpel.dao.BpelDAOConnection;
import org.apache.ode.bpel.dao.ProcessInstanceDAO;
import org.apache.ode.bpel.dao.ProcessManagementDAO;
+import org.apache.ode.bpel.dao.ProcessManagementDAO.InstanceSummaryKey;
public class ProcessManagementDaoImpl extends DaoBaseImpl implements ProcessManagementDAO
{
public Object[] findFailedCountAndLastFailedDateForProcessId(BpelDAOConnection conn,
String status, String processId) {
@@ -49,4 +54,19 @@
public void prefetchActivityFailureCounts(Collection<ProcessInstanceDAO>
instances) {
// do nothing
}
+
+ public int countInstancesByPidAndString(BpelDAOConnection conn, QName pid, String
status) {
+ InstanceFilter instanceFilter = new InstanceFilter("status=" + status +
" pid="+ pid);
+
+ // TODO: this is grossly inefficient
+ return conn.instanceQuery(instanceFilter).size();
+ }
+
+ public Map<InstanceSummaryKey, Long> countInstancesSummary(Set<String>
pids) {
+ return new HashMap<InstanceSummaryKey, Long>();
+ }
+
+ public Map<String, FailedSummaryValue>
findFailedCountAndLastFailedDateForProcessIds(Set<String> pids) {
+ return new HashMap<String, FailedSummaryValue>();
+ }
}
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/ACTIVITYGUARD.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/ACTIVITYGUARD.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/ACTIVITYGUARD.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -29,6 +29,7 @@
import org.apache.ode.bpel.explang.EvaluationException;
import org.apache.ode.bpel.o.OActivity;
import org.apache.ode.bpel.o.OExpression;
+import org.apache.ode.bpel.o.OInvoke;
import org.apache.ode.bpel.o.OLink;
import org.apache.ode.bpel.o.OScope;
import org.apache.ode.bpel.o.OFailureHandling;
@@ -237,6 +238,15 @@
// Implicit scope can tell the difference between cancelled and
completed.
_self.parent.cancelled();
}
+
+ private OFailureHandling getFailureHandling() {
+ if (_oactivity instanceof OInvoke) {
+ OInvoke _oinvoke = (OInvoke) _oactivity;
+ OFailureHandling f =
getBpelRuntimeContext().getConfigForPartnerLink(_oinvoke.partnerLink).failureHandling;
+ if (f != null) return f;
+ }
+ return _oactivity.getFailureHandling();
+ }
public void failure(String reason, Element data) {
if (_failure == null)
@@ -245,9 +255,9 @@
_failure.reason = reason;
_failure.data = data;
- OFailureHandling failureHandling = _oactivity.getFailureHandling();
- if (failureHandling != null &&
failureHandling.faultOnFailure) {
- // No attempt to retry or enter activity recovery state, simply
fault.
+ OFailureHandling failureHandling = getFailureHandling();
+ if (failureHandling != null && failureHandling.faultOnFailure
&& _failure.retryCount >= failureHandling.retryFor) {
+ //Fault after retries (may be 0)
if (__log.isDebugEnabled())
__log.debug("ActivityRecovery: Activity " +
_self.aId + " faulting on failure");
FaultData faultData =
createFault(OFailureHandling.FAILURE_FAULT_NAME, _oactivity, reason);
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/ASSIGN.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/ASSIGN.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/ASSIGN.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -57,6 +57,8 @@
import java.io.IOException;
import java.net.URI;
+import java.util.Calendar;
+import java.util.Date;
import java.util.List;
/**
@@ -83,23 +85,23 @@
try {
copy(aCopy);
} catch (FaultException fault) {
- if (aCopy.ignoreMissingFromData) {
- if
(fault.getQName().equals(getOAsssign().getOwner().constants.qnSelectionFailure)
&&
- (fault.getCause() != null &&
"ignoreMissingFromData".equals(fault.getCause().getMessage()))) {
- continue;
- }
- }
- if (aCopy.ignoreUninitializedFromVariable) {
- if
(fault.getQName().equals(getOAsssign().getOwner().constants.qnUninitializedVariable)
&&
- (fault.getCause() == null ||
!"throwUninitializedToVariable".equals(fault.getCause().getMessage()))) {
- continue;
- }
- }
+ if (aCopy.ignoreMissingFromData) {
+ if
(fault.getQName().equals(getOAsssign().getOwner().constants.qnSelectionFailure)
&&
+ (fault.getCause() != null &&
"ignoreMissingFromData".equals(fault.getCause().getMessage()))) {
+ continue;
+ }
+ }
+ if (aCopy.ignoreUninitializedFromVariable) {
+ if
(fault.getQName().equals(getOAsssign().getOwner().constants.qnUninitializedVariable)
&&
+ (fault.getCause() == null ||
!"throwUninitializedToVariable".equals(fault.getCause().getMessage()))) {
+ continue;
+ }
+ }
faultData = createFault(fault.getQName(), aCopy, fault
.getMessage());
break;
} catch (ExternalVariableModuleException e) {
- __log.error("Exception while initializing external variable", e);
+ __log.error("Exception while initializing external variable",
e);
_self.parent.failure(e.toString(), null);
return;
}
@@ -157,7 +159,7 @@
return lval;
}
- /**
+ /**
* Get the r-value. There are several possibilities:
* <ul>
* <li>a message is selected - an element representing the whole message is
@@ -237,15 +239,13 @@
}
retVal = (Node) l.get(0);
} else if (from instanceof OAssign.Literal) {
+ String literal = ((OAssign.Literal) from).getXmlLiteral();
Element literalRoot;
- try {
- literalRoot = ((OAssign.Literal) from).getXmlLiteral().getDocumentElement();
- } catch (Exception e) {
- String msg = __msgs.msgEvalException(from.toString(), e.getMessage());
- if (__log.isDebugEnabled()) __log.debug(from + ": " + msg);
- if (e.getCause() instanceof FaultException) throw
(FaultException)e.getCause();
- throw new
FaultException(getOAsssign().getOwner().constants.qnSelectionFailure, msg);
- }
+ try {
+ literalRoot = DOMUtils.stringToDOM(literal);
+ } catch (Exception e) {
+ throw new RuntimeException("XML literal parsing failed " +
literal, e);
+ }
assert literalRoot.getLocalName().equals("literal");
// We'd like a single text node...
@@ -341,7 +341,7 @@
return retVal;
}
- private void copy(OAssign.Copy ocopy) throws FaultException,
ExternalVariableModuleException {
+ private void copy(OAssign.Copy ocopy) throws FaultException,
ExternalVariableModuleException {
if (__log.isDebugEnabled())
__log.debug("Assign.copy(" + ocopy + ")");
@@ -410,7 +410,7 @@
lvalue));
} else if (ocopy.to instanceof OAssign.LValueExpression) {
LValueExpression lexpr = (LValueExpression) ocopy.to;
- lexpr.setInsertMissingToData(ocopy.insertMissingToData);
+ lexpr.setInsertMissingToData(ocopy.insertMissingToData);
lvaluePtr = evalQuery(lvalue, null, lexpr.expression,
new EvaluationContextProxy(lexpr.getVariable(), lvalue));
if (__log.isDebugEnabled())
@@ -455,20 +455,20 @@
sendEvent(se);
}
- @Override
- Node fetchVariableData(VariableInstance variable, boolean forWriting)
- throws FaultException {
- try {
- return super.fetchVariableData(variable, forWriting);
- } catch (FaultException fe) {
- if (forWriting) {
- fe = new FaultException(fe.getQName(), fe.getMessage(), new
Throwable("throwUninitializedToVariable"));
- }
- throw fe;
- }
- }
-
- private void replaceEndpointRefence(PartnerLinkInstance plval, Node rvalue) throws
FaultException {
+ @Override
+ Node fetchVariableData(VariableInstance variable, boolean forWriting)
+ throws FaultException {
+ try {
+ return super.fetchVariableData(variable, forWriting);
+ } catch (FaultException fe) {
+ if (forWriting) {
+ fe = new FaultException(fe.getQName(), fe.getMessage(), new
Throwable("throwUninitializedToVariable"));
+ }
+ throw fe;
+ }
+ }
+
+ private void replaceEndpointRefence(PartnerLinkInstance plval, Node rvalue) throws
FaultException {
if (rvalue.getNodeType() == Node.ATTRIBUTE_NODE){
rvalue = rvalue.getOwnerDocument().createTextNode(((Attr) rvalue).getValue());
}
@@ -630,13 +630,13 @@
if (expression != null) {
// Neat little trick....
try {
- data = ec.evaluateQuery(data, expression);
- } catch (EvaluationException e) {
+ data = ec.evaluateQuery(data, expression);
+ } catch (EvaluationException e) {
String msg = __msgs.msgEvalException(expression.toString(),
e.getMessage());
if (__log.isDebugEnabled()) __log.debug(expression + ": " +
msg);
if (e.getCause() instanceof FaultException) throw
(FaultException)e.getCause();
throw new
FaultException(getOAsssign().getOwner().constants.qnSubLanguageExecutionFault, msg);
- }
+ }
}
return data;
@@ -667,7 +667,7 @@
} else
return _ctx.readVariable(variable, part);
- } /**
+ } /**
* @see
org.apache.ode.bpel.explang.EvaluationContext#readMessageProperty(org.apache.ode.bpel.o.OScope.Variable,
* org.apache.ode.bpel.o.OProcess.OProperty)
*/
@@ -718,17 +718,21 @@
return false;
}
- public URI getBaseResourceURI() {
- return _ctx.getBaseResourceURI();
- }
+ public URI getBaseResourceURI() {
+ return _ctx.getBaseResourceURI();
+ }
- public Node getPropertyValue(QName propertyName) {
- return _ctx.getPropertyValue(propertyName);
- }
+ public Node getPropertyValue(QName propertyName) {
+ return _ctx.getPropertyValue(propertyName);
+ }
- public QName getProcessQName() {
- return _ctx.getProcessQName();
- }
+ public QName getProcessQName() {
+ return _ctx.getProcessQName();
+ }
+
+ public Date getCurrentEventDateTime() {
+ return Calendar.getInstance().getTime();
+ }
}
}
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/BpelRuntimeContext.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/BpelRuntimeContext.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/BpelRuntimeContext.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -20,7 +20,6 @@
import java.util.Collection;
import java.util.Date;
-import java.util.Map;
import java.net.URI;
import javax.wsdl.Operation;
@@ -39,6 +38,7 @@
import org.apache.ode.bpel.runtime.channels.PickResponseChannel;
import org.apache.ode.bpel.runtime.channels.TimerResponseChannel;
import org.apache.ode.bpel.evar.ExternalVariableModuleException;
+import org.apache.ode.bpel.iapi.ProcessConf.PartnerRoleConfig;
import org.w3c.dom.Element;
import org.w3c.dom.Node;
@@ -110,6 +110,13 @@
boolean isPartnerRoleEndpointInitialized(PartnerLinkInstance pLink);
/**
+ * Retrieve failure handling info for invoke
+ * @param pLink
+ * @return
+ */
+ PartnerRoleConfig getConfigForPartnerLink(OPartnerLink pLink);
+
+ /**
* Fetches our session id associated with the partner link instance. This will
always return a
* non-null value.
* @param pLink partner link
@@ -268,32 +275,37 @@
/**
* Read an external variable.
*/
- Node readExtVar(Variable variable, Node reference) throws
ExternalVariableModuleException;
-
- /**
- * Write an external variable.
- */
- ValueReferencePair writeExtVar(Variable variable, Node reference, Node value) throws
ExternalVariableModuleException ;
-
- public class ValueReferencePair {
- public Node value;
- public Node reference;
- }
-
- /**
- * Retrieves the base URI that this BPEL Process instance is running relative to.
- *
- * @return URI - the URI representing the absolute physical file path location that this
process is defined within.
- */
- URI getBaseResourceURI();
-
- /**
- * Retrieves the property value that has been defined for this BPEL Process type.
- *
- * @return propertyValue - the value corresponding to the process property name.
- */
- Node getProcessProperty(QName propertyName);
+ Node readExtVar(Variable variable, Node reference) throws
ExternalVariableModuleException;
+
+ /**
+ * Write an external variable.
+ */
+ ValueReferencePair writeExtVar(Variable variable, Node reference, Node value) throws
ExternalVariableModuleException ;
+
+ public class ValueReferencePair {
+ public Node value;
+ public Node reference;
+ }
+
+ /**
+ * Retrieves the base URI that this BPEL Process instance is running relative to.
+ *
+ * @return URI - the URI representing the absolute physical file path location that
this process is defined within.
+ */
+ URI getBaseResourceURI();
+
+ /**
+ * Retrieves the property value that has been defined for this BPEL Process type.
+ *
+ * @return propertyValue - the value corresponding to the process property name.
+ */
+ Node getProcessProperty(QName propertyName);
- QName getProcessQName();
+ QName getProcessQName();
+ void processOutstandingRequest(PartnerLinkInstance partnerLink, String opName, String
bpelMexId, String odeMexId) throws FaultException;
+
+ Date getCurrentEventDateTime();
+
+ ClassLoader getProcessClassLoader();
}
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/EH_ALARM.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/EH_ALARM.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/EH_ALARM.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -32,6 +32,7 @@
import org.apache.ode.bpel.runtime.channels.TerminationChannelListener;
import org.apache.ode.bpel.runtime.channels.TimerResponseChannel;
import org.apache.ode.bpel.runtime.channels.TimerResponseChannelListener;
+import org.apache.ode.jacob.ChannelListener;
import org.apache.ode.jacob.SynchChannel;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
@@ -122,7 +123,7 @@
/**
* Concretion constructor.
- * @param alarm date at which time to fire
+ * @param alarm date at which time to fire. If null, then we wait forever (for
control channels handling)
*/
WAIT(Calendar alarm) {
_alarm = alarm;
@@ -131,10 +132,28 @@
public void run() {
Calendar now = Calendar.getInstance();
- if (now.before(_alarm)) {
+ Set<ChannelListener> listeners = new
EventHandlerControlChannelListener(_cc) {
+ private static final long serialVersionUID = -7750428941445331236L;
+
+ public void stop() {
+ _psc.completed(null, _comps);
+ }
+
+ }.or(new TerminationChannelListener(_tc) {
+ private static final long serialVersionUID = 6100105997983514609L;
+
+ public void terminate() {
+ _psc.completed(null, _comps);
+ }
+ });
+
+ if (_alarm == null) {
+ object(false, listeners);
+ } else if (now.before(_alarm)) {
TimerResponseChannel trc = newChannel(TimerResponseChannel.class);
getBpelRuntimeContext().registerTimer(trc,_alarm.getTime());
- object(false,new TimerResponseChannelListener(trc){
+
+ listeners.add(new TimerResponseChannelListener(trc){
private static final long serialVersionUID = 1110683632756756017L;
public void onTimeout() {
@@ -145,20 +164,8 @@
public void onCancel() {
_psc.completed(null, _comps);
}
- }.or(new EventHandlerControlChannelListener(_cc) {
- private static final long serialVersionUID = -7750428941445331236L;
-
- public void stop() {
- _psc.completed(null, _comps);
- }
-
- }.or(new TerminationChannelListener(_tc) {
- private static final long serialVersionUID = 6100105997983514609L;
-
- public void terminate() {
- _psc.completed(null, _comps);
- }
- })));
+ });
+ object(false, listeners);
} else /* now is later then alarm time */ {
// If the alarm has passed we fire the nested activity
ActivityInfo child = new ActivityInfo(genMonotonic(),
@@ -226,7 +233,12 @@
}
instance(new WAIT(next));
} else {
- _psc.completed(faultData, _comps);
+ if (faultData != null) {
+ //propagate completion into bounding scope only if we got
fault during processing onAlarm
+ _psc.completed(faultData, _comps);
+ } else {
+ instance(new WAIT(null));
+ }
}
}
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/EH_EVENT.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/EH_EVENT.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/EH_EVENT.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -280,6 +280,12 @@
getBpelRuntimeContext().initializePartnersSessionId(ehScopeFrame.resolve(_oevent.partnerLink),
partnersSessionId);
}
+
+
getBpelRuntimeContext().cancelOutstandingRequests(_pickResponseChannel.export());
+ // this request is now waiting for a reply
+
getBpelRuntimeContext().processOutstandingRequest(_scopeFrame.resolve(_oevent.partnerLink),
+ _oevent.operation.getName(),
_oevent.messageExchangeId, mexId);
+
} catch (FaultException e) {
__log.error(e);
if (_fault == null) {
@@ -290,8 +296,6 @@
return;
}
-
-
// load 'onMessage' activity; we'll do this even
if a stop/terminate has been
// requested becasue we cannot undo the receipt of the
message at this point.
ActivityInfo child = new ActivityInfo(genMonotonic(),
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/ExprEvaluationContextImpl.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/ExprEvaluationContextImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/ExprEvaluationContextImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -19,6 +19,7 @@
package org.apache.ode.bpel.runtime;
import java.net.URI;
+import java.util.Date;
import java.util.Map;
import javax.xml.namespace.QName;
@@ -46,112 +47,115 @@
* variables, link statuses, and the like.
*/
public class ExprEvaluationContextImpl implements EvaluationContext {
- private static final Log __log = LogFactory
- .getLog(ExprEvaluationContextImpl.class);
+ private static final Log __log = LogFactory
+ .getLog(ExprEvaluationContextImpl.class);
- private BpelRuntimeContext _native;
+ private BpelRuntimeContext _native;
- private ScopeFrame _scopeInstance;
+ private ScopeFrame _scopeInstance;
- private Map<OLink, Boolean> _linkVals;
+ private Map<OLink, Boolean> _linkVals;
- private Node _root;
+ private Node _root;
- public ExprEvaluationContextImpl(ScopeFrame scopeInstace,
- BpelRuntimeContext ntv) {
- _native = ntv;
- _scopeInstance = scopeInstace;
- }
+ public ExprEvaluationContextImpl(ScopeFrame scopeInstace,
+ BpelRuntimeContext ntv) {
+ _native = ntv;
+ _scopeInstance = scopeInstace;
+ }
- public ExprEvaluationContextImpl(ScopeFrame scopeInstace,
- BpelRuntimeContext ntv, Node root) {
- this(scopeInstace, ntv);
- _root = root;
- }
+ public ExprEvaluationContextImpl(ScopeFrame scopeInstace,
+ BpelRuntimeContext ntv, Node root) {
+ this(scopeInstace, ntv);
+ _root = root;
+ }
- public ExprEvaluationContextImpl(ScopeFrame scopeInstnce,
- BpelRuntimeContext ntv, Map<OLink, Boolean> linkVals) {
- this(scopeInstnce, ntv);
- _linkVals = linkVals;
- }
+ public ExprEvaluationContextImpl(ScopeFrame scopeInstnce,
+ BpelRuntimeContext ntv, Map<OLink, Boolean> linkVals) {
+ this(scopeInstnce, ntv);
+ _linkVals = linkVals;
+ }
- public Node readVariable(OScope.Variable variable, OMessageVarType.Part part)
- throws FaultException {
- if (__log.isTraceEnabled())
- __log.trace("readVariable(" + variable + "," + part +
")");
+ public Node readVariable(OScope.Variable variable, OMessageVarType.Part part)
+ throws FaultException {
+ if (__log.isTraceEnabled())
+ __log.trace("readVariable(" + variable + "," + part +
")");
- // TODO: check for null _scopeInstance
+ // TODO: check for null _scopeInstance
- Node ret;
- if (variable.type instanceof OConstantVarType) {
- ret = ((OConstantVarType) variable.type).getValue();
- } else {
- VariableInstance varInstance = _scopeInstance.resolve(variable);
- if (varInstance == null)
- return null;
- VariableReadEvent vre = new VariableReadEvent();
- vre.setVarName(varInstance.declaration.name);
- sendEvent(vre);
- ret = _scopeInstance.fetchVariableData(_native,varInstance, part, false);
- }
- return ret;
- }
+ Node ret;
+ if (variable.type instanceof OConstantVarType) {
+ ret = ((OConstantVarType) variable.type).getValue();
+ } else {
+ VariableInstance varInstance = _scopeInstance.resolve(variable);
+ if (varInstance == null)
+ return null;
+ VariableReadEvent vre = new VariableReadEvent();
+ vre.setVarName(varInstance.declaration.name);
+ sendEvent(vre);
+ ret = _scopeInstance.fetchVariableData(_native,varInstance, part, false);
+ }
+ return ret;
+ }
- public Node evaluateQuery(Node root, OExpression expr)
- throws FaultException, EvaluationException {
- return _native.getExpLangRuntime()
- .evaluateNode(
- expr,
- new ExprEvaluationContextImpl(_scopeInstance,
- _native, root));
- }
+ public Node evaluateQuery(Node root, OExpression expr)
+ throws FaultException, EvaluationException {
+ return _native.getExpLangRuntime()
+ .evaluateNode(
+ expr,
+ new ExprEvaluationContextImpl(_scopeInstance,
+ _native, root));
+ }
- public String readMessageProperty(OScope.Variable variable,
- OProcess.OProperty property) throws FaultException {
- VariableInstance varInstance = _scopeInstance.resolve(variable);
- return _native.readProperty(varInstance, property);
- }
+ public String readMessageProperty(OScope.Variable variable,
+ OProcess.OProperty property) throws FaultException {
+ VariableInstance varInstance = _scopeInstance.resolve(variable);
+ return _native.readProperty(varInstance, property);
+ }
- public boolean isLinkActive(OLink olink) throws FaultException {
- return _linkVals.get(olink);
- }
+ public boolean isLinkActive(OLink olink) throws FaultException {
+ return _linkVals.get(olink);
+ }
- public String toString() {
- return "{ExprEvaluationContextImpl scopeInstance=" + _scopeInstance
- + ", activeLinks=" + _linkVals + "}";
- }
+ public String toString() {
+ return "{ExprEvaluationContextImpl scopeInstance=" + _scopeInstance
+ + ", activeLinks=" + _linkVals + "}";
+ }
- public Node getRootNode() {
- return _root;
- }
+ public Node getRootNode() {
+ return _root;
+ }
- public Node getPartData(Element message, Part part) throws FaultException {
- return _scopeInstance.getPartData(message, part);
- }
+ public Node getPartData(Element message, Part part) throws FaultException {
+ return _scopeInstance.getPartData(message, part);
+ }
- public Long getProcessId() {
- return _native.getPid();
- }
+ public Long getProcessId() {
+ return _native.getPid();
+ }
- public boolean narrowTypes() {
- return true;
- }
+ public boolean narrowTypes() {
+ return true;
+ }
- private void sendEvent(ScopeEvent se) {
- _scopeInstance.fillEventInfo(se);
- _native.sendEvent(se);
- }
+ private void sendEvent(ScopeEvent se) {
+ _scopeInstance.fillEventInfo(se);
+ _native.sendEvent(se);
+ }
- public URI getBaseResourceURI() {
- return _native.getBaseResourceURI();
- }
-
- public Node getPropertyValue(QName propertyName) {
- return _native.getProcessProperty(propertyName);
- }
+ public URI getBaseResourceURI() {
+ return _native.getBaseResourceURI();
+ }
+
+ public Node getPropertyValue(QName propertyName) {
+ return _native.getProcessProperty(propertyName);
+ }
- public QName getProcessQName() {
- return _native.getProcessQName();
- }
+ public QName getProcessQName() {
+ return _native.getProcessQName();
+ }
+ public Date getCurrentEventDateTime() {
+ return _native.getCurrentEventDateTime();
+ }
}
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/INVOKE.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/INVOKE.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/INVOKE.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -184,10 +184,10 @@
// and either retry or indicate failure condition.
// admin to resume the process.
String reason =
getBpelRuntimeContext().getPartnerFaultExplanation(mexId);
- Element msg = getBpelRuntimeContext().getPartnerResponse(mexId);
__log.error("Failure during invoke: " + reason);
try {
- _self.parent.failure(reason, msg);
+ Element el =
DOMUtils.stringToDOM("<invokeFailure><![CDATA["+reason+"]]></invokeFailure>");
+ _self.parent.failure(reason, el);
} catch (Exception e) {
_self.parent.failure(reason, null);
}
@@ -229,51 +229,4 @@
return (Element) outboundMsg;
} else return null;
}
-
- @SuppressWarnings("unused")
- // TODO: does somebody need this method??
- private void requireRecovery() {
- if (__log.isDebugEnabled())
- __log.debug("ActivityRecovery: Invoke activity " + _self.aId +
" requires recovery");
- sendEvent(new ActivityFailureEvent(_failureReason));
- final ActivityRecoveryChannel recoveryChannel =
newChannel(ActivityRecoveryChannel.class);
- getBpelRuntimeContext().registerActivityForRecovery(recoveryChannel, _self.aId,
_failureReason, _lastFailure, _failureData,
- new String[] { "retry", "cancel", "fault"
}, _invoked - 1);
- object(false, new ActivityRecoveryChannelListener(recoveryChannel) {
- private static final long serialVersionUID = 8397883882810521685L;
- public void retry() {
- if (__log.isDebugEnabled())
- __log.debug("ActivityRecovery: Retrying invoke activity " +
_self.aId + " (user initiated)");
- sendEvent(new ActivityRecoveryEvent("retry"));
- getBpelRuntimeContext().unregisterActivityForRecovery(recoveryChannel);
- instance(INVOKE.this);
- }
- public void cancel() {
- if (__log.isDebugEnabled())
- __log.debug("ActivityRecovery: Cancelling invoke activity "
+ _self.aId + " (user initiated)");
- sendEvent(new ActivityRecoveryEvent("cancel"));
- getBpelRuntimeContext().unregisterActivityForRecovery(recoveryChannel);
- _self.parent.cancelled();
- }
- public void fault(FaultData faultData) {
- if (__log.isDebugEnabled())
- __log.debug("ActivityRecovery: Faulting invoke activity " +
_self.aId + " (user initiated)");
- sendEvent(new ActivityRecoveryEvent("fault"));
- getBpelRuntimeContext().unregisterActivityForRecovery(recoveryChannel);
- if (faultData == null)
- faultData = createFault(OFailureHandling.FAILURE_FAULT_NAME, _self.o,
_failureReason);
- _self.parent.completed(faultData, CompensationHandler.emptySet());
- }
- }.or(new TerminationChannelListener(_self.self) {
- private static final long serialVersionUID = 2148587381204858397L;
-
- public void terminate() {
- if (__log.isDebugEnabled())
- __log.debug("ActivityRecovery: Cancelling invoke activity "
+ _self.aId + " (terminated by scope)");
- getBpelRuntimeContext().unregisterActivityForRecovery(recoveryChannel);
- _self.parent.completed(null, CompensationHandler.emptySet());
- }
- }));
- }
-
}
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/PICK.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/PICK.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/PICK.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -296,10 +296,7 @@
dpe(_alarm.activity);
}
- if (_opick.onMessages.size() > 1 &&
onMessage.operation.getOutput() == null) {
- // Releasing other onMessage that could be two-ways with an
oustanding request
-
getBpelRuntimeContext().cancelOutstandingRequests(_pickResponseChannel.export());
- }
+
getBpelRuntimeContext().cancelOutstandingRequests(_pickResponseChannel.export());
FaultData fault;
initVariable(mexId, onMessage);
@@ -336,6 +333,10 @@
_scopeFrame.resolve(onMessage.partnerLink),
partnersSessionId);
}
+ // this request is now waiting for a reply
+
getBpelRuntimeContext().processOutstandingRequest(_scopeFrame.resolve(onMessage.partnerLink),
+ onMessage.operation.getName(),
onMessage.messageExchangeId, mexId);
+
} catch (FaultException e) {
__log.error(e);
fault = createFault(e.getQName(), onMessage);
@@ -344,6 +345,7 @@
return;
}
+
// load 'onMessage' activity
// Because we are done with all the DPE, we can simply
// re-use our control
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/PropertyAliasEvaluationContext.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/PropertyAliasEvaluationContext.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/PropertyAliasEvaluationContext.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -19,6 +19,8 @@
package org.apache.ode.bpel.runtime;
import java.net.URI;
+import java.util.Calendar;
+import java.util.Date;
import org.apache.ode.bpel.common.FaultException;
import org.apache.ode.bpel.explang.EvaluationContext;
@@ -81,9 +83,9 @@
throw new InvalidProcessException("Process execution information not
available in this context.");
}
- public QName getProcessQName() {
+ public QName getProcessQName() {
throw new InvalidProcessException("Process execution information not
available in this context.");
- }
+ }
public Node getPartData(Element message, Part part) throws FaultException {
// TODO Auto-generated method stub
@@ -95,11 +97,15 @@
}
public URI getBaseResourceURI() {
- return null;
+ return null;
}
- public Node getPropertyValue(QName propertyName) {
- return null;
- }
+ public Node getPropertyValue(QName propertyName) {
+ return null;
+ }
+ public Date getCurrentEventDateTime() {
+ return null;
+ }
+
}
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/WAIT.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/WAIT.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/WAIT.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -61,7 +61,7 @@
}
- if(dueDate.getTime() > System.currentTimeMillis()){
+ if(dueDate.getTime() >
getBpelRuntimeContext().getCurrentEventDateTime().getTime()) {
final TimerResponseChannel timerChannel =
newChannel(TimerResponseChannel.class);
getBpelRuntimeContext().registerTimer(timerChannel, dueDate);
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/elang/xpath20/runtime/MockCompilerContext.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/elang/xpath20/runtime/MockCompilerContext.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/elang/xpath20/runtime/MockCompilerContext.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -44,6 +44,7 @@
import org.apache.ode.bpel.o.OPartnerLink;
import org.apache.ode.bpel.o.OProcess;
import org.apache.ode.bpel.o.OScope;
+import org.apache.ode.bpel.o.OVarType;
import org.apache.ode.bpel.o.OXsdTypeVarType;
import org.apache.ode.bpel.o.OXslSheet;
import org.apache.ode.bpel.o.OMessageVarType.Part;
@@ -218,4 +219,16 @@
// TODO Auto-generated method stub
return null;
}
+ public OExpression compileExpr(Expression expr, OVarType rootNodeType,
+ Object requestedResultType, Object[] resultType)
+ throws CompilationException {
+ // TODO Auto-generated method stub
+ return null;
+ }
+ public OLValueExpression compileLValueExpr(Expression expr,
+ OVarType rootNodeType, Object requestedResultType,
+ Object[] resultType) throws CompilationException {
+ // TODO Auto-generated method stub
+ return null;
+ }
}
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/elang/xpath20/runtime/XPath20ExpressionRuntimeTest.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/elang/xpath20/runtime/XPath20ExpressionRuntimeTest.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/elang/xpath20/runtime/XPath20ExpressionRuntimeTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -38,6 +38,7 @@
import javax.xml.namespace.QName;
import java.net.URI;
+import java.util.Date;
import java.util.HashMap;
import java.util.Map;
@@ -156,14 +157,18 @@
}
public URI getBaseResourceURI() {
- return null;
+ return null;
}
- public Node getPropertyValue(QName propertyName) {
- return null;
- }
+ public Node getPropertyValue(QName propertyName) {
+ return null;
+ }
- public QName getProcessQName() {
- return null;
- }
+ public QName getProcessQName() {
+ return null;
+ }
+
+ public Date getCurrentEventDateTime() {
+ return null;
+ }
}
Added:
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/elang/xpath20/runtime/XsdTypesTest.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/elang/xpath20/runtime/XsdTypesTest.java
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/elang/xpath20/runtime/XsdTypesTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,45 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.ode.bpel.elang.xpath20.runtime;
+
+import javax.xml.namespace.QName;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+import org.apache.ode.utils.DOMUtils;
+
+import junit.framework.TestCase;
+
+public class XsdTypesTest extends TestCase {
+ private static Log __log = LogFactory.getLog(XsdTypesTest.class);
+
+ public void testDateTime() throws Exception {
+ Object o =
JaxpVariableResolver.getSimpleContent(DOMUtils.stringToDOM("<temporary-simple-type-wrapper>2010-01-25T15:38:54.82Z</temporary-simple-type-wrapper>"),
QName.valueOf("{http://www.w3.org/2001/XMLSchema}dateTime"));
+ __log.debug(o);
+ assertTrue(o.toString().contains("2010-01-25T15:38:54.82Z"));
+ }
+
+ public void testEmptyDateTime() throws Exception {
+ Object o =
JaxpVariableResolver.getSimpleContent(DOMUtils.stringToDOM("<temporary-simple-type-wrapper></temporary-simple-type-wrapper>"),
QName.valueOf("{http://www.w3.org/2001/XMLSchema}dateTime"));
+ __log.debug(o);
+ assertTrue(o.toString().equals(""));
+ }
+
+}
Added:
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/engine/MyRoleMessageExchangeImplTest.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/engine/MyRoleMessageExchangeImplTest.java
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/engine/MyRoleMessageExchangeImplTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,91 @@
+package org.apache.ode.bpel.engine;
+
+import java.util.Map;
+import java.util.Properties;
+import java.util.concurrent.TimeUnit;
+import java.util.concurrent.TimeoutException;
+
+import javax.transaction.TransactionManager;
+
+import org.apache.geronimo.transaction.manager.GeronimoTransactionManager;
+import org.apache.ode.bpel.dao.MessageExchangeDAO;
+import org.apache.ode.bpel.engine.MyRoleMessageExchangeImpl.ResponseCallback;
+import org.apache.ode.scheduler.simple.SimpleScheduler;
+import org.jmock.Mock;
+import org.jmock.MockObjectTestCase;
+
+public class MyRoleMessageExchangeImplTest extends MockObjectTestCase {
+ private Mock mexDao;
+
+ private TestMyRoleMessageExchangeImpl myRoleMexImpl;
+ Contexts contexts;
+ BpelEngineImpl engine;
+ TransactionManager _txm;
+
+ public void testResponseReceived() throws Exception {
+
mexDao.expects(exactly(3)).method("getCorrelationId").will(returnValue("corrId"));
+
+ final boolean[] responded = new boolean[1];
+ myRoleMexImpl.callbacks().put("corrId", new ResponseCallback() {
+ synchronized boolean responseReceived() {
+ responded[0] = true;
+ return true;
+ }
+
+ synchronized void waitResponse(long timeout) {
+ }
+ });
+
+ _txm.begin();
+ myRoleMexImpl.responseReceived();
+ _txm.rollback();
+
+ _txm.begin();
+ myRoleMexImpl.responseReceived();
+ _txm.rollback();
+
+ _txm.begin();
+ myRoleMexImpl.responseReceived();
+ _txm.commit();
+
+ assertTrue(responded[0]);
+ }
+
+ public void testResponseTimeout() throws Exception {
+
mexDao.expects(atLeastOnce()).method("getCorrelationId").will(returnValue("corrId"));
+ myRoleMexImpl.callbacks().put("corrId", new
MyRoleMessageExchangeImpl.ResponseCallback());
+
+ _txm.begin();
+ myRoleMexImpl.responseReceived();
+ _txm.rollback();
+
+ try {
+ new MyRoleMessageExchangeImpl.ResponseFuture("corrId").get(10,
TimeUnit.MILLISECONDS);
+ fail("Should throw a TimeoutException!!");
+ } catch( TimeoutException te ) {}
+ }
+
+ protected void setUp() throws Exception {
+ _txm = new GeronimoTransactionManager();
+
+ mexDao = new Mock(MessageExchangeDAO.class);
+ SimpleScheduler scheduler = new SimpleScheduler("node", null, new
Properties());
+ scheduler.setTransactionManager(_txm);
+
+ contexts = new Contexts();
+ contexts.scheduler = scheduler;
+ engine = new BpelEngineImpl(contexts);
+
+ myRoleMexImpl = new TestMyRoleMessageExchangeImpl();
+ }
+
+ class TestMyRoleMessageExchangeImpl extends MyRoleMessageExchangeImpl {
+ public TestMyRoleMessageExchangeImpl() {
+ super(null, engine, (MessageExchangeDAO)mexDao.proxy());
+ }
+
+ public Map<String, ResponseCallback> callbacks() {
+ return _waitingCallbacks;
+ }
+ }
+}
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/runtime/ActivityRecoveryTest.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/runtime/ActivityRecoveryTest.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/runtime/ActivityRecoveryTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -19,12 +19,14 @@
package org.apache.ode.bpel.runtime;
import org.apache.ode.bpel.engine.BpelManagementFacadeImpl;
+import org.apache.ode.bpel.engine.BpelServerImpl;
import org.apache.ode.bpel.iapi.Message;
import org.apache.ode.bpel.iapi.MessageExchange;
import org.apache.ode.bpel.iapi.MessageExchangeContext;
import org.apache.ode.bpel.iapi.PartnerRoleMessageExchange;
import org.apache.ode.bpel.o.OFailureHandling;
import org.apache.ode.bpel.pmapi.BpelManagementFacade;
+import org.apache.ode.bpel.pmapi.ProcessInfoDocument;
import org.apache.ode.bpel.pmapi.TActivityInfo;
import org.apache.ode.bpel.pmapi.TActivityStatus;
import org.apache.ode.bpel.pmapi.TFailureInfo;
@@ -54,7 +56,12 @@
* Test activity recovery and failure handling.
*/
public class ActivityRecoveryTest extends MockObjectTestCase {
-
+ // the maximum ammout of time to wait for an instance to reach a
+ // desired status or for an activity to become available for recovery
+ static final int MAX_WAIT = 10000;
+ // poll interval
+ static final int DELAY = 100;
+
static final String NAMESPACE = "http://ode.apache.org/bpel/unit-test";
static final String[] ACTIONS = new String[]{ "retry", "cancel",
"fault" };
MockBpelServer _server;
@@ -63,6 +70,10 @@
QName _processId;
private Mock _testService;
+ static {
+ // disable deferred process instance cleanup for faster testing
+
System.setProperty(BpelServerImpl.DEFERRED_PROCESS_INSTANCE_CLEANUP_DISABLED_NAME,
"true");
+ }
/**
* The process calls the failing service, simulated by a call to invoke.
@@ -74,14 +85,13 @@
public void completed();
}
-
public void testInvokeSucceeds() throws Exception {
// Since the service invocation succeeds, the process completes.
_testService.expects(once()).method("invoke").will(returnValue(true));
_testService.expects(once()).method("completed").after("invoke");
execute("FailureToRecovery");
- assertTrue(lastInstance().getStatus() == TInstanceStatus.COMPLETED);
+ assertNotNull(lastInstance(TInstanceStatus.COMPLETED));
assertNoFailures();
}
@@ -92,7 +102,7 @@
_testService.expects(once()).method("completed").after("invoke");
execute("FailureToRecovery");
- assertTrue(lastInstance().getStatus() == TInstanceStatus.COMPLETED);
+ assertNotNull(lastInstance(TInstanceStatus.COMPLETED));
assertNoFailures();
}
@@ -105,7 +115,7 @@
execute("FailureToRecovery");
recover("retry");
recover("retry");
- assertTrue(lastInstance().getStatus() == TInstanceStatus.COMPLETED);
+ assertNotNull(lastInstance(TInstanceStatus.COMPLETED));
assertNoFailures();
}
@@ -118,8 +128,8 @@
execute("FailureToRecovery");
recover("retry");
recover("fault");
- assertTrue(lastInstance().getStatus() == TInstanceStatus.FAILED);
-
assertTrue(OFailureHandling.FAILURE_FAULT_NAME.equals(lastInstance().getFaultInfo().getName()));
+ assertNotNull(lastInstance(TInstanceStatus.FAILED));
+
assertTrue(OFailureHandling.FAILURE_FAULT_NAME.equals(lastInstance(null).getFaultInfo().getName()));
assertNoFailures();
}
@@ -132,7 +142,7 @@
execute("FailureToCancel");
recover("retry");
recover("cancel");
- assertTrue(lastInstance().getStatus() == TInstanceStatus.COMPLETED);
+ assertNotNull(lastInstance(TInstanceStatus.COMPLETED));
assertNoFailures();
}
@@ -145,17 +155,28 @@
assertRecovery(1, ACTIONS);
}
-// public void testImmediateFailureAndFault() throws Exception {
-// // This process responds to failure with a fault.
-//
_testService.expects(exactly(1)).method("invoke").will(returnValue(false));
-//
_testService.expects(never()).method("completed").after("invoke");
-//
-// execute("FailureToFault");
-// assertTrue(lastInstance().getStatus() == TInstanceStatus.FAILED);
-//
assertTrue(OFailureHandling.FAILURE_FAULT_NAME.equals(lastInstance().getFaultInfo().getName()));
-// assertNoFailures();
-// }
+ public void testImmediateFailureAndFault() throws Exception {
+ // This process responds to failure with a fault.
+
_testService.expects(exactly(1)).method("invoke").will(returnValue(false));
+
_testService.expects(never()).method("completed").after("invoke");
+ execute("FailureToFault");
+ assertNotNull(lastInstance(TInstanceStatus.FAILED));
+ assertEquals(OFailureHandling.FAILURE_FAULT_NAME,
lastInstance(TInstanceStatus.FAILED).getFaultInfo().getName());
+ assertNoFailures();
+ }
+
+ public void testImmediateFailureAndFault2() throws Exception {
+ // This process responds to failure with a fault.
+
_testService.expects(exactly(1)).method("invoke").will(returnValue(false));
+
_testService.expects(never()).method("completed").after("invoke");
+
+ execute("FailureToFault2");
+ assertNotNull(lastInstance(TInstanceStatus.FAILED));
+ assertEquals(OFailureHandling.FAILURE_FAULT_NAME,
lastInstance(TInstanceStatus.FAILED).getFaultInfo().getName());
+ assertNoFailures();
+ }
+
public void testFailureHandlingInheritence() throws Exception {
// Since the invocation is repeated 3 times, the process completes after
// the third (successful) invocation.
@@ -163,7 +184,7 @@
_testService.expects(once()).method("completed").after("invoke");
execute("FailureInheritence");
- assertTrue(lastInstance().getStatus() == TInstanceStatus.COMPLETED);
+ assertNotNull(lastInstance(TInstanceStatus.COMPLETED));
assertNoFailures();
}
@@ -294,35 +315,75 @@
_processQName = new QName(NAMESPACE, process);
_processId = new QName(NAMESPACE, process + "-1");
_server.invoke(_processQName, "instantiate",
DOMUtils.newDocument().createElementNS(NAMESPACE, "tns:RequestElement"));
- _server.waitForBlocking();
}
- protected void assertNoFailures() {
- TFailuresInfo failures = lastInstance().getFailures();
+ protected void assertNoFailures() throws Exception {
+ TFailuresInfo failures = lastInstance(null).getFailures();
assertTrue(failures == null || failures.getCount() == 0);
failures =
_management.getProcessInfo(_processId).getProcessInfo().getInstanceSummary().getFailures();
assertTrue(failures == null || failures.getCount() == 0);
}
- protected TInstanceInfo lastInstance() {
- TInstanceInfoList instances = _management.listInstances("",
"", 1000).getInstanceInfoList();
- return instances.getInstanceInfoArray(instances.sizeOfInstanceInfoArray() - 1);
+ /**
+ * Blocks until the last instance reaches the desired status or throws an
+ * exception if MAX_WAIT is exceeded.
+ *
+ * @param expected
+ * @throws Exception
+ */
+ protected TInstanceInfo lastInstance(TInstanceStatus.Enum expected) throws Exception
{
+ int counter = 0;
+ do {
+ TInstanceInfo info = getInstanceInfo();
+ if (info != null && (expected == null || info.getStatus() == expected)) {
+ return info;
+ }
+ if (counter * DELAY > MAX_WAIT) {
+ throw new Exception("Timed out wait for instance to reach "+expected+
+ " status. Actual status: "+(info==null?"missing instance" :
info.getStatus()));
+ }
+ counter++;
+ Thread.sleep(DELAY);
+ } while (true);
}
+ /**
+ * get the instance info for the last instance
+ */
+ private TInstanceInfo getInstanceInfo() {
+ TInstanceInfoList instances = _management.listInstances("", "",
1000).getInstanceInfoList();
+ int size = instances.sizeOfInstanceInfoArray();
+ if (size > 0) {
+ return instances.getInstanceInfoArray(instances.sizeOfInstanceInfoArray() - 1);
+ }
+ return null;
+ }
/**
* Asserts that the process has one activity in the recovery state.
+ * @throws Exception
*/
- protected void assertRecovery(int invoked, String[] actions) {
+ protected void assertRecovery(int invoked, String[] actions) throws Exception {
// Process is still active, none of the completed states.
- assertTrue(lastInstance().getStatus() == TInstanceStatus.ACTIVE);
+ assertNotNull(lastInstance(TInstanceStatus.ACTIVE));
// Tests here will only generate one failure.
- TFailuresInfo failures = lastInstance().getFailures();
- assertTrue(failures != null && failures.getCount() == 1);
- failures =
_management.getProcessInfo(_processId).getProcessInfo().getInstanceSummary().getFailures();
- assertTrue(failures != null && failures.getCount() == 1);
+ TInstanceInfo instance = lastInstance(null);
+ int count = 30;
+ int sleep = 0;
+ while (true) {
+ count--;
+ if (count <= 0) throw new AssertionError("No failures info, which are
required");
+ Thread.sleep(sleep);
+ sleep = 1000;
+ TFailuresInfo failures = instance.getFailures();
+ if (!(failures != null && failures.getCount() == 1)) continue;
+ ProcessInfoDocument m = _management.getProcessInfo(_processId);
+ if (!m.getProcessInfo().isSetInstanceSummary()) continue;
+ failures = m.getProcessInfo().getInstanceSummary().getFailures();
+ if (!(failures != null && failures.getCount() == 1)) continue;
+ break;
+ }
// Look for individual activities inside the process instance.
- @SuppressWarnings("unused")
- ArrayList<TActivityInfo> recoveries = getRecoveriesInScope(lastInstance(),
null, null);
+ ArrayList<TActivityInfo> recoveries = getRecoveriesInScope(instance, null,
null);
assertTrue(recoveries.size() == 1);
TFailureInfo failure = recoveries.get(0).getFailure();
assertTrue(failure.getRetries() == invoked - 1);
@@ -339,19 +400,41 @@
* Performs the specified recovery action. Also asserts that there is one
* recovery channel for the activity in question.
*/
- protected void recover(String action) {
- ArrayList<TActivityInfo> recoveries = getRecoveriesInScope(lastInstance(),
null, null);
+ protected void recover(String action) throws Exception {
+ ArrayList<TActivityInfo> recoveries = getRecoveries();
assertTrue(recoveries.size() == 1);
TActivityInfo activity = recoveries.get(0);
assertNotNull(activity);
- _management.recoverActivity(Long.valueOf(lastInstance().getIid()),
Long.valueOf(activity.getAiid()), action);
+ _management.recoverActivity(Long.valueOf(getInstanceInfo().getIid()),
Long.valueOf(activity.getAiid()), action);
_server.waitForBlocking();
}
+ /**
+ * Blocks for until there are recoveries available or throws an exception
+ * if MAX_WAIT exceeded
+ */
+ private ArrayList<TActivityInfo> getRecoveries() throws Exception {
+ TInstanceInfo instance = null;
+ int counter = 0;
+ do {
+ instance = getInstanceInfo();
+ if (instance != null) {
+ ArrayList<TActivityInfo> recoveries = getRecoveriesInScope(instance, null,
null);
+ if (recoveries.size() > 0) {
+ return recoveries;
+ }
+ }
+ if (counter * DELAY > MAX_WAIT) {
+ throw new Exception("Timed out wait for recovery activities");
+ }
+ Thread.sleep(DELAY);
+ counter++;
+ } while (true);
+ }
protected ArrayList<TActivityInfo> getRecoveriesInScope(TInstanceInfo instance,
TScopeInfo scope,
-
ArrayList<TActivityInfo> recoveries) {
+
ArrayList<TActivityInfo> recoveries) throws Exception {
if (scope == null)
- scope =
_management.getScopeInfoWithActivity(lastInstance().getRootScope().getSiid(),
true).getScopeInfo();
+ scope =
_management.getScopeInfoWithActivity(instance.getRootScope().getSiid(),
true).getScopeInfo();
if (recoveries == null)
recoveries = new ArrayList<TActivityInfo>();
TScopeInfo.Activities activities = scope.getActivities();
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/runtime/CoreBpelTest.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/runtime/CoreBpelTest.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/runtime/CoreBpelTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -35,6 +35,7 @@
import org.apache.ode.bpel.evt.ProcessInstanceEvent;
import org.apache.ode.bpel.o.OCatch;
import org.apache.ode.bpel.o.OEmpty;
+import org.apache.ode.bpel.o.OFailureHandling;
import org.apache.ode.bpel.o.OFaultHandler;
import org.apache.ode.bpel.o.OFlow;
import org.apache.ode.bpel.o.OMessageVarType;
@@ -53,6 +54,7 @@
import org.apache.ode.jacob.vpu.ExecutionQueueImpl;
import org.apache.ode.jacob.vpu.JacobVPU;
import org.apache.ode.bpel.evar.ExternalVariableModuleException;
+import org.apache.ode.bpel.iapi.ProcessConf.PartnerRoleConfig;
import org.w3c.dom.Element;
import org.w3c.dom.Node;
@@ -100,8 +102,7 @@
return null;
}
- public Node fetchVariableData(VariableInstance var, OMessageVarType.Part partname,
boolean forWriting)
- throws FaultException {
+ public Node fetchVariableData(VariableInstance var, OMessageVarType.Part partname,
boolean forWriting) throws FaultException {
return null;
}
@@ -138,19 +139,16 @@
_fault = faultData;
}
- public void select(PickResponseChannel response, Date timeout, boolean
createInstnace, Selector[] selectors)
- throws FaultException {
+ public void select(PickResponseChannel response, Date timeout, boolean
createInstnace, Selector[] selectors) throws FaultException {
}
- public void cancelOutstandingRequests(String channelId) {
+ public void cancelOutstandingRequests(String channelId) {
}
- public void reply(PartnerLinkInstance plink, String opName, String mexId, Element
msg, QName fault)
- throws FaultException {
+ public void reply(PartnerLinkInstance plink, String opName, String mexId, Element
msg, QName fault) throws FaultException {
}
- public String invoke(int aid, PartnerLinkInstance partnerLinkInstance, Operation
operation, Element outboundMsg,
- InvokeResponseChannel invokeResponseChannel) {
+ public String invoke(int aid, PartnerLinkInstance partnerLinkInstance, Operation
operation, Element outboundMsg, InvokeResponseChannel invokeResponseChannel) {
return null;
}
@@ -170,7 +168,7 @@
public void initializePartnerLinks(Long parentScopeId, Collection<OPartnerLink>
partnerLinks) {
}
-
+
public void testEmptyProcess() {
OProcess proc = new OProcess("2.0");
proc.procesScope = new OScope(proc, null);
@@ -399,8 +397,7 @@
return null;
}
- public void registerActivityForRecovery(ActivityRecoveryChannel channel, long
activityId, String reason,
- Date dateTime, Element data, String[]
actions, int retries) {
+ public void registerActivityForRecovery(ActivityRecoveryChannel channel, long
activityId, String reason, Date dateTime, Element data, String[] actions, int retries) {
}
public void unregisterActivityForRecovery(ActivityRecoveryChannel channel) {
@@ -410,52 +407,69 @@
}
public String getPartnerFaultExplanation(String mexid) {
- return null;
+ return null;
}
public void releasePartnerMex(String mexId, boolean instanceSucceeded) {
// TODO Auto-generated method stub
-
+
}
public void initializeExternalVariable(VariableInstance instance, HashMap<String,
String> keymap) {
// TODO Auto-generated method stub
-
+
}
- public Node readExtVar(Variable variable, Node reference) throws
ExternalVariableModuleException {
- // TODO Auto-generated method stub
- return null;
- }
+ public Node readExtVar(Variable variable, Node reference) throws
ExternalVariableModuleException {
+ // TODO Auto-generated method stub
+ return null;
+ }
- public Node readVariable(Long scopeInstanceId, String varname, boolean forWriting)
throws FaultException {
- // TODO Auto-generated method stub
- return null;
- }
+ public Node readVariable(Long scopeInstanceId, String varname, boolean forWriting)
throws FaultException {
+ // TODO Auto-generated method stub
+ return null;
+ }
- public ValueReferencePair writeExtVar(Variable variable, Node reference, Node value)
throws ExternalVariableModuleException {
- // TODO Auto-generated method stub
- return null;
- }
+ public ValueReferencePair writeExtVar(Variable variable, Node reference, Node value)
throws ExternalVariableModuleException {
+ // TODO Auto-generated method stub
+ return null;
+ }
- public Node writeVariable(VariableInstance var, Node changes) {
- // TODO Auto-generated method stub
- return null;
- }
-
- public URI getBaseResourceURI() {
- // TODO Auto-generated method stub
- return null;
- }
+ public Node writeVariable(VariableInstance var, Node changes) {
+ // TODO Auto-generated method stub
+ return null;
+ }
- public Node getProcessProperty(QName propertyName) {
- // TODO Auto-generated method stub
- return null;
- }
+ public URI getBaseResourceURI() {
+ // TODO Auto-generated method stub
+ return null;
+ }
- public QName getProcessQName() {
- // TODO Auto-generated method stub
- return null;
- }
+ public Node getProcessProperty(QName propertyName) {
+ // TODO Auto-generated method stub
+ return null;
+ }
+ public QName getProcessQName() {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ public Date getCurrentEventDateTime() {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ public ClassLoader getProcessClassLoader() {
+ return getClass().getClassLoader();
+ }
+
+ public void processOutstandingRequest(PartnerLinkInstance partnerLink,
+ String opName, String mexId, String mexRef) {
+ // TODO Auto-generated method stub
+ }
+
+ public PartnerRoleConfig getConfigForPartnerLink(OPartnerLink pLink) {
+ return new PartnerRoleConfig(null, true);
+ }
}
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/runtime/MockBpelServer.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/runtime/MockBpelServer.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/runtime/MockBpelServer.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -18,6 +18,15 @@
*/
package org.apache.ode.bpel.runtime;
+import org.apache.derby.jdbc.EmbeddedXADataSource;
+import org.apache.geronimo.connector.outbound.GenericConnectionManager;
+import org.apache.geronimo.connector.outbound.connectionmanagerconfig.LocalTransactions;
+import org.apache.geronimo.connector.outbound.connectionmanagerconfig.PoolingSupport;
+import org.apache.geronimo.connector.outbound.connectionmanagerconfig.SinglePool;
+import
org.apache.geronimo.connector.outbound.connectionmanagerconfig.TransactionSupport;
+import org.apache.geronimo.connector.outbound.connectiontracking.ConnectionTracker;
+import
org.apache.geronimo.connector.outbound.connectiontracking.ConnectionTrackingCoordinator;
+import org.apache.geronimo.transaction.manager.RecoverableTransactionManager;
import org.apache.ode.bpel.dao.BpelDAOConnectionFactory;
import org.apache.ode.bpel.dao.BpelDAOConnectionFactoryJDBC;
import org.apache.ode.bpel.engine.BpelServerImpl;
@@ -43,9 +52,11 @@
import org.apache.ode.utils.DOMUtils;
import org.apache.ode.utils.GUID;
import org.hsqldb.jdbc.jdbcDataSource;
+import org.tranql.connector.derby.EmbeddedLocalMCF;
import org.w3c.dom.Document;
import org.w3c.dom.Element;
+import javax.resource.spi.ConnectionManager;
import javax.sql.DataSource;
import javax.transaction.TransactionManager;
import javax.wsdl.PortType;
@@ -79,13 +90,13 @@
@SuppressWarnings("unchecked")
HashMap _endpoints = new HashMap();
- public MockBpelServer() {
+ public MockBpelServer() {
try {
_server = new BpelServerImpl();
createTransactionManager();
createDataSource();
+ createScheduler();
createDAOConnection();
- createScheduler();
if (_daoCF == null)
throw new RuntimeException("No DAO");
_server.setDaoConnectionFactory(_daoCF);
@@ -93,7 +104,9 @@
if (_scheduler == null)
throw new RuntimeException("No scheduler");
createEndpointReferenceContext();
- _store = new ProcessStoreImpl(_eprContext, _dataSource,"jpa", new
OdeConfigProperties(new Properties(), ""), true);
+ Properties storeProps = new Properties();
+ storeProps.setProperty("hibernate.hbm2ddl.auto",
"update");
+ _store = new ProcessStoreImpl(_eprContext, _dataSource,"hib", new
OdeConfigProperties(storeProps, ""), true);
_server.setScheduler(_scheduler);
_server.setEndpointReferenceContext(_eprContext);
_server.setMessageExchangeContext(createMessageExchangeContext());
@@ -169,12 +182,45 @@
}
protected DataSource createDataSource() throws Exception {
- jdbcDataSource hsqlds = new jdbcDataSource();
- hsqlds.setDatabase("jdbc:hsqldb:mem:" + new GUID().toString());
- hsqlds.setUser("sa");
- hsqlds.setPassword("");
- _dataSource = hsqlds;
- return _dataSource;
+ TransactionSupport transactionSupport = LocalTransactions.INSTANCE;
+ ConnectionTracker connectionTracker = new ConnectionTrackingCoordinator();
+
+ PoolingSupport poolingSupport = new SinglePool(
+ 10,
+ 0,
+ 1000,
+ 1,
+ true,
+ false,
+ false);
+
+ ConnectionManager connectionManager = new GenericConnectionManager(
+ transactionSupport,
+ poolingSupport,
+ null,
+ connectionTracker,
+ (RecoverableTransactionManager) _txManager,
+ getClass().getName(),
+ getClass().getClassLoader());
+
+
+ EmbeddedLocalMCF mcf = new org.tranql.connector.derby.EmbeddedLocalMCF();
+ mcf.setCreateDatabase(true);
+ mcf.setDatabaseName("target/testdb");
+ mcf.setUserName("sa");
+ mcf.setPassword("");
+ _dataSource = (DataSource) mcf.createConnectionFactory(connectionManager);
+ return _dataSource;
+
+
+// d = org.tranql.connector.jdbc.JDBCDriverMCF();
+// EmbeddedXADataSource ds = new EmbeddedXADataSource();
+// ds.setCreateDatabase("create");
+// ds.setDatabaseName("target/testdb");
+// ds.setUser("sa");
+// ds.setPassword("");
+// _dataSource = ds;
+// return _dataSource;
}
protected Scheduler createScheduler() throws Exception {
@@ -194,15 +240,23 @@
if (_dataSource == null)
throw new RuntimeException("No data source");
- BpelDAOConnectionFactoryJDBC daoCF = new BPELDAOConnectionFactoryImpl();
+//
+// BpelDAOConnectionFactoryJDBC daoCF = new BPELDAOConnectionFactoryImpl();
+// daoCF.setDataSource(_dataSource);
+// daoCF.setTransactionManager(_txManager);
+// Properties props = new Properties();
+// props.put("openjpa.Log", "log4j");
+// props.put("openjpa.jdbc.SynchronizeMappings",
"buildSchema(ForeignKeys=false)");
+// daoCF.init(props);
+// _daoCF = daoCF;
+ org.apache.ode.daohib.bpel.BpelDAOConnectionFactoryImpl daoCF = new
org.apache.ode.daohib.bpel.BpelDAOConnectionFactoryImpl();
daoCF.setDataSource(_dataSource);
daoCF.setTransactionManager(_txManager);
Properties props = new Properties();
- props.put("openjpa.Log", "log4j");
- props.put("openjpa.jdbc.SynchronizeMappings",
"buildSchema(ForeignKeys=false)");
+ props.setProperty("hibernate.hbm2ddl.auto", "update");
daoCF.init(props);
+
_daoCF = daoCF;
-
return _daoCF;
}
@@ -300,9 +354,13 @@
runnable.run();
return new GUID().toString();
}
-
+
public String scheduleVolatileJob(boolean transacted, Map<String,Object>
jobDetail) throws ContextException {
- String jobId = _scheduler.scheduleVolatileJob(transacted, jobDetail);
+ return scheduleVolatileJob(transacted, jobDetail, null);
+ }
+
+ public String scheduleVolatileJob(boolean transacted, Map<String, Object>
jobDetail, Date when) throws ContextException {
+ String jobId = _scheduler.scheduleVolatileJob(transacted, jobDetail, when);
_nextSchedule = System.currentTimeMillis();
return jobId;
}
@@ -312,8 +370,12 @@
}
public <T> T execTransaction(Callable<T> transaction) throws
Exception, ContextException {
- return _scheduler.execTransaction(transaction);
+ return _scheduler.execTransaction(transaction, 0);
}
+
+ public <T> T execTransaction(Callable<T> transaction, int timeout)
throws Exception, ContextException {
+ return _scheduler.execTransaction(transaction, timeout);
+ }
public void beginTransaction() throws Exception {
_scheduler.beginTransaction();
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/runtime/ProcessManagementTest.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/runtime/ProcessManagementTest.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/test/java/org/apache/ode/bpel/runtime/ProcessManagementTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -44,7 +44,7 @@
public void testFilterProcessesByName() throws Exception {
List<TProcessInfo> pilist =
_management.listProcesses(null,null).getProcessInfoList().getProcessInfoList();
- assertEquals(5,pilist.size());
+ assertEquals(6,pilist.size());
pilist =
_management.listProcesses("name=FailureInh*",null).getProcessInfoList().getProcessInfoList();
assertEquals(1,pilist.size());
@@ -56,10 +56,10 @@
assertEquals(0,pilist.size());
pilist =
_management.listProcesses("namespace="+NAMESPACE,null).getProcessInfoList().getProcessInfoList();
- assertEquals(5,pilist.size());
+ assertEquals(6,pilist.size());
pilist =
_management.listProcesses("namespace=http:*",null).getProcessInfoList().getProcessInfoList();
- assertEquals(5,pilist.size());
+ assertEquals(6,pilist.size());
pilist =
_management.listProcesses("namespace=foo:*",null).getProcessInfoList().getProcessInfoList();
assertEquals(0,pilist.size());
@@ -88,7 +88,7 @@
public void testListProcessCustom() {
List<TProcessInfo> pilist =
_management.listProcessesCustom(null,"name",
ProcessInfoCustomizer.ALL).getProcessInfoList().getProcessInfoList();
- assertEquals(5,pilist.size());
+ assertEquals(6,pilist.size());
}
protected void setUp() throws Exception {
Modified: branches/ODE/ODE-1.x/bpel-runtime/src/test/resources/log4j.properties
===================================================================
--- branches/ODE/ODE-1.x/bpel-runtime/src/test/resources/log4j.properties 2010-04-14
15:43:12 UTC (rev 619)
+++ branches/ODE/ODE-1.x/bpel-runtime/src/test/resources/log4j.properties 2010-04-14
18:25:55 UTC (rev 620)
@@ -1,34 +1,35 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+#
http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+# implied.
+#
+# See the License for the specific language governing permissions and
+# limitations under the License.
#
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements. See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
#
-#
http://www.apache.org/licenses/LICENSE-2.0
+
#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
+# The logging properties used during tests..
#
+#log4j.rootLogger=DEBUG, file
+log4j.rootLogger=INFO, file
-# Set root logger level to WARN and its only appender to CONSOLE
-log4j.rootLogger=WARN, CONSOLE
+log4j.appender.file=org.apache.log4j.FileAppender
+log4j.appender.file.File=target/test/test.log
+log4j.appender.file.layout=org.apache.log4j.PatternLayout
+log4j.appender.file.layout.ConversionPattern=%d{MM-dd@HH:mm:ss} %-5p (%13F:%L) %3x - %m%n
-# log4j properties to work with commandline tools.
-log4j.category.org.mortbay=ERROR
-log4j.category.org.hibernate.type=WARN
-log4j.category.org.objectweb=ERROR
-log4j.category.org.apache.ode.axis2=DEBUG
-log4j.category.org.apache.ode.axis2.hooks.SessionInHandler=INFO
-log4j.category.org.apache.ode.bpel.engine=INFO
-log4j.category.org.apache.ode.daohib.bpel.CorrelatorDaoImpl=DEBUG
-log4j.category.org.apache.ode.bpel.epr=INFO
+#log4j.category.org.apache.ode=DEBUG
+#log4j.category.org.hibernate.jdbc.AbstractBatcher=DEBUG
+#log4j.category.org.org.hibernate.SQL=DEBUG
-# Console appender
-log4j.appender.CONSOLE=org.apache.log4j.ConsoleAppender
-log4j.appender.CONSOLE.layout=org.apache.log4j.PatternLayout
-log4j.appender.CONSOLE.layout.ConversionPattern=%p - %C{1}.%M(%L) | %m%n
Modified: branches/ODE/ODE-1.x/bpel-runtime/src/test/resources/recovery/deploy.xml
===================================================================
--- branches/ODE/ODE-1.x/bpel-runtime/src/test/resources/recovery/deploy.xml 2010-04-14
15:43:12 UTC (rev 619)
+++ branches/ODE/ODE-1.x/bpel-runtime/src/test/resources/recovery/deploy.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -47,6 +47,22 @@
</invoke>
</process>
+ <process name="pns:FailureToFault2">
+ <active>true</active>
+ <provide partnerLink="instantiatingPartnerLink">
+ <service name="wns:FailureToFault2" port="soap"/>
+ </provide>
+ <invoke partnerLink="failingPartnerLink">
+ <service name="wns:FailingService" port="soap"/>
+ <ext:failureHandling
xmlns:ext="http://ode.apache.org/activityRecovery">
+ <ext:faultOnFailure>true</ext:faultOnFailure>
+ </ext:failureHandling>
+ </invoke>
+ <invoke partnerLink="instantiatingPartnerLink">
+ <service name="wns:ResponseService" port="soap"/>
+ </invoke>
+ </process>
+
<process name="pns:FailureNoRetry">
<active>true</active>
<provide partnerLink="instantiatingPartnerLink">
Modified:
branches/ODE/ODE-1.x/bpel-runtime/src/test/resources/recovery/failure-to-fault.bpel
===================================================================
---
branches/ODE/ODE-1.x/bpel-runtime/src/test/resources/recovery/failure-to-fault.bpel 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/test/resources/recovery/failure-to-fault.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -49,33 +49,22 @@
operation="instantiate"
variable="request"
createInstance="yes"/>
- <flow>
- <links>
- <link name="successfulInvoke"/>
- </links>
- <invoke name="invoke"
- partnerLink="failingPartnerLink"
- portType="tns:FailingPortType"
- operation="invoke"
- inputVariable="request"
- outputVariable="response">
- <sources>
- <source linkName="successfulInvoke"/>
- </sources>
- <ext:failureHandling>
- <ext:faultOnFailure>true</ext:faultOnFailure>
- </ext:failureHandling>
- </invoke>
- <invoke name="response"
- partnerLink="instantiatingPartnerLink"
- portType="tns:ResponsePortType"
- operation="respond"
- inputVariable="response">
- <targets>
- <target linkName="successfulInvoke"/>
- </targets>
- </invoke>
- </flow>
+ <invoke name="invoke"
+ partnerLink="failingPartnerLink"
+ portType="tns:FailingPortType"
+ operation="invoke"
+ inputVariable="request"
+ outputVariable="response">
+ <ext:failureHandling>
+ <ext:faultOnFailure>true</ext:faultOnFailure>
+ </ext:failureHandling>
+ </invoke>
+ <invoke name="response"
+ partnerLink="instantiatingPartnerLink"
+ portType="tns:ResponsePortType"
+ operation="respond"
+ inputVariable="response">
+ </invoke>
</sequence>
</process>
Added:
branches/ODE/ODE-1.x/bpel-runtime/src/test/resources/recovery/failure-to-fault2.bpel
===================================================================
--- branches/ODE/ODE-1.x/bpel-runtime/src/test/resources/recovery/failure-to-fault2.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-runtime/src/test/resources/recovery/failure-to-fault2.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<process name="FailureToFault2"
+
targetNamespace="http://ode.apache.org/bpel/unit-test"
+
xmlns="http://schemas.xmlsoap.org/ws/2004/03/business-process/"
+
xmlns:tns="http://ode.apache.org/bpel/unit-test"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+
xmlns:ext="http://ode.apache.org/activityRecovery">
+
+ <import location="services.wsdl"
+
namespace="http://ode.apache.org/bpel/unit-test"
+
importType="http://schemas.xmlsoap.org/wsdl/"/>
+
+ <partnerLinks>
+ <partnerLink name="instantiatingPartnerLink"
+ partnerLinkType="tns:InstantiatingPartnerLinkType"
+ myRole="me" partnerRole="partner"
initializePartnerRole="yes"/>
+ <partnerLink name="failingPartnerLink"
+ partnerLinkType="tns:FailingPartnerLinkType"
+ partnerRole="partner"
initializePartnerRole="yes"/>
+ </partnerLinks>
+
+ <variables>
+ <variable name="request" messageType="tns:Request"/>
+ <variable name="response" messageType="tns:Response"/>
+ </variables>
+
+ <sequence>
+ <receive name="start"
+ partnerLink="instantiatingPartnerLink"
+ portType="tns:InstantiatingPortType"
+ operation="instantiate"
+ variable="request"
+ createInstance="yes"/>
+ <flow>
+ <links>
+ <link name="successfulInvoke"/>
+ </links>
+ <invoke name="invoke"
+ partnerLink="failingPartnerLink"
+ portType="tns:FailingPortType"
+ operation="invoke"
+ inputVariable="request"
+ outputVariable="response">
+ <sources>
+ <source linkName="successfulInvoke"/>
+ </sources>
+ </invoke>
+ <invoke name="response"
+ partnerLink="instantiatingPartnerLink"
+ portType="tns:ResponsePortType"
+ operation="respond"
+ inputVariable="response">
+ <targets>
+ <target linkName="successfulInvoke"/>
+ </targets>
+ </invoke>
+ </flow>
+ </sequence>
+
+</process>
Added: branches/ODE/ODE-1.x/bpel-schemas/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/bpel-schemas/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/bpel-schemas/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,71 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-schemas</artifactId>
+ <name>ODE :: BPEL Schemas</name>
+
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.xmlbeans</groupId>
+ <artifactId>xmlbeans</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>xmlbeans-maven-plugin</artifactId>
+ <configuration>
+ <schemaDirectory>src/main/xsd</schemaDirectory>
+
<sourceGenerationDirectory>target/generated/xmlbeans</sourceGenerationDirectory>
+ <xmlConfigs>
+ <xmlConfig
implementation="java.io.File">src/main/xsd/dd.xsdconfig</xmlConfig>
+ <xmlConfig
implementation="java.io.File">src/main/xsd/pmapi.xsdconfig</xmlConfig>
+ <xmlConfig
implementation="java.io.File">src/main/xsd/schedules.xsdconfig</xmlConfig>
+ </xmlConfigs>
+ <javaSource>1.5</javaSource>
+ </configuration>
+ <executions>
+ <execution>
+ <goals>
+ <goal>xmlbeans</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+
+</project>
Added: branches/ODE/ODE-1.x/bpel-schemas/src/main/xsd/activityRecovery.xsd
===================================================================
--- branches/ODE/ODE-1.x/bpel-schemas/src/main/xsd/activityRecovery.xsd
(rev 0)
+++ branches/ODE/ODE-1.x/bpel-schemas/src/main/xsd/activityRecovery.xsd 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<schema
xmlns="http://www.w3.org/2001/XMLSchema"
targetNamespace="http://ode.apache.org/activityRecovery"
xmlns:ext="http://ode.apache.org/activityRecovery"
elementFormDefault="qualified">
+ <element name="failureHandling">
+ <complexType>
+ <all>
+ <element name="retryFor" type="int"
minOccurs="0"></element>
+ <element name="retryDelay" type="int"
minOccurs="0"></element>
+ <element name="faultOnFailure" type="boolean"
minOccurs="0"></element>
+ </all>
+ </complexType>
+ </element>
+</schema>
\ No newline at end of file
Modified: branches/ODE/ODE-1.x/bpel-schemas/src/main/xsd/dd.xsd
===================================================================
--- branches/ODE/ODE-1.x/bpel-schemas/src/main/xsd/dd.xsd 2010-04-14 15:43:12 UTC (rev
619)
+++ branches/ODE/ODE-1.x/bpel-schemas/src/main/xsd/dd.xsd 2010-04-14 18:25:55 UTC (rev
620)
@@ -19,10 +19,13 @@
-->
<xs:schema
xmlns:xs="http://www.w3.org/2001/XMLSchema"
+
xmlns:ext="http://ode.apache.org/activityRecovery"
targetNamespace="http://www.apache.org/ode/schemas/dd/2007/03"
xmlns:dd="http://www.apache.org/ode/schemas/dd/2007/03"
elementFormDefault="qualified">
+ <xs:import
namespace="http://ode.apache.org/activityRecovery"
schemaLocation="activityRecovery.xsd"></xs:import>
+
<xs:element name="deploy" id="deploy"
type="dd:tDeployment">
</xs:element>
@@ -123,15 +126,17 @@
</xs:complexType>
<xs:complexType name="tInvoke">
- <xs:choice>
+ <xs:sequence>
<xs:element name="service" minOccurs="1"
maxOccurs="1" type="dd:tService"/>
<xs:element name="binding" minOccurs="0"
maxOccurs="1">
<xs:complexType>
<xs:attribute name="name" type="xs:QName"
use="required"/>
</xs:complexType>
</xs:element>
- </xs:choice>
+ <xs:element ref="ext:failureHandling"
minOccurs="0"/>
+ </xs:sequence>
<xs:attribute name="partnerLink" type="xs:string"
use="required"/>
+ <xs:attribute name="usePeer2Peer" type="xs:boolean"
use="optional" default="true"/>
</xs:complexType>
<xs:complexType name="tService">
@@ -163,7 +168,7 @@
<xs:complexType name="tEnableEventList">
<xs:sequence>
- <xs:element name="enable-event" minOccurs="1"
maxOccurs="unbounded" type="xs:string"/>
+ <xs:element name="enable-event" minOccurs="0"
maxOccurs="unbounded" type="xs:string"/>
</xs:sequence>
</xs:complexType>
@@ -179,7 +184,7 @@
<xs:complexContent>
<xs:extension base="dd:tEnableEventList">
<xs:sequence>
- <xs:element name="scope-events" minOccurs="1"
maxOccurs="unbounded" type="dd:tScopeEvents"/>
+ <xs:element name="scope-events" minOccurs="0"
maxOccurs="unbounded" type="dd:tScopeEvents"/>
</xs:sequence>
<xs:attribute name="generate" use="optional">
<xs:simpleType>
Modified: branches/ODE/ODE-1.x/bpel-schemas/src/main/xsd/pmapi.xsd
===================================================================
--- branches/ODE/ODE-1.x/bpel-schemas/src/main/xsd/pmapi.xsd 2010-04-14 15:43:12 UTC (rev
619)
+++ branches/ODE/ODE-1.x/bpel-schemas/src/main/xsd/pmapi.xsd 2010-04-14 18:25:55 UTC (rev
620)
@@ -33,6 +33,127 @@
<element name="event-info" type="pmapi:tEventInfo"/>
<element name="event-info-list"
type="pmapi:tEventInfoList"/>
+ <simpleType name="ExchangeType">
+ <restriction base="string">
+ <enumeration value="M"/>
+ <enumeration value="P"/>
+ </restriction>
+ </simpleType>
+
+ <xs:complexType name="ReplayType">
+ <xs:choice>
+ <xs:element name="mock"
type="anySimpleType"></xs:element>
+ <xs:element name="mockQuery"
type="string"></xs:element>
+ <xs:element name="live"
type="anySimpleType"></xs:element>
+ </xs:choice>
+ </xs:complexType>
+
+ <xs:element name="mockQueryRequest">
+ <xs:complexType>
+ <xs:sequence>
+ <element name="createTime" type="dateTime"/>
+ <element name="service" type="QName"/>
+ <element name="operation" type="string"/>
+ <element name="in" type="anyType"/>
+ <xs:element name="pattern">
+ <xs:simpleType>
+ <restriction base="string">
+ <enumeration value="IN_ONLY"/>
+ <enumeration value="IN_OUT"/>
+ </restriction>
+ </xs:simpleType>
+ </xs:element>
+ </xs:sequence>
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="mockQueryResponse"
type="pmapi:ResponseType"/>
+
+ <xs:complexType name="ResponseType">
+ <choice>
+ <element name="out" type="anyType" />
+ <element name="fault" type="pmapi:FaultType" />
+ <element name="failure" type="pmapi:FailureType"
/>
+ </choice>
+ </xs:complexType>
+
+ <complexType name="GetCommunication">
+ <xs:sequence>
+ <xs:element name="iid" type="long"
maxOccurs="unbounded"></xs:element>
+ </xs:sequence>
+ </complexType>
+
+ <xs:complexType name="GetCommunicationResponse">
+ <xs:sequence>
+ <element name="restoreInstance" minOccurs="0"
maxOccurs="unbounded" type="pmapi:CommunicationType"/>
+ </xs:sequence>
+ </xs:complexType>
+
+ <element name="getCommunicationResponse"
type="pmapi:GetCommunicationResponse"/>
+
+ <complexType name="FaultType">
+ <sequence>
+ <element name="type" type="QName" />
+ <element name="explanation" type="string" />
+ <element name="message" type="anyType" />
+ </sequence>
+ </complexType>
+
+ <complexType name="FailureType">
+ <sequence>
+ <element name="explanation" type="string" />
+ </sequence>
+ </complexType>
+
+ <complexType name="CommunicationType">
+ <sequence>
+ <element name="processType" type="QName" />
+ <element name="rollbackOnFault" type="boolean"
minOccurs="0" default="true"/>
+
+ <element name="serviceConfig"
maxOccurs="unbounded">
+ <complexType>
+ <sequence>
+ <element name="service" type="QName"
/>
+ <xs:element name="replayType"
type="pmapi:ReplayType"/>
+ </sequence>
+ </complexType>
+ </element>
+
+ <element name="exchange" maxOccurs="unbounded">
+ <complexType>
+ <sequence>
+ <element name="type"
type="pmapi:ExchangeType" />
+ <element name="createTime" type="dateTime"
/>
+ <element name="service" type="QName"
/>
+ <element name="operation" type="string"
/>
+ <element name="in" type="anyType" />
+ <choice> <!-- ResponseType -->
+ <element name="out"
type="anyType"/>
+ <element name="fault"
type="pmapi:FaultType"/>
+ <element name="failure"
type="pmapi:FailureType"/>
+ </choice>
+ </sequence>
+ </complexType>
+ </element>
+ </sequence>
+ </complexType>
+
+ <complexType name="Replay">
+ <sequence>
+ <element name="upgradeInstance" minOccurs="0"
maxOccurs="unbounded" type="long"/>
+ <element name="replaceInstance" minOccurs="0"
maxOccurs="unbounded" type="long"/>
+ <element name="restoreInstance" minOccurs="0"
maxOccurs="unbounded" type="pmapi:CommunicationType"/>
+ </sequence>
+ </complexType>
+
+ <complexType name="ReplayResponse">
+ <sequence>
+ <element name="restoredIID" type="long"
minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+
+ <element name="replayResponse"
type="pmapi:ReplayResponse"/>
+
<complexType name="tProcessInfo">
<annotation>
<documentation>Information about a BPEL process.</documentation>
Added: branches/ODE/ODE-1.x/bpel-scripts/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/bpel-scripts/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/bpel-scripts/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,33 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-scripts</artifactId>
+ <name>ODE :: BPEL Test Script Files</name>
+ <packaging>jar</packaging>
+ <modelVersion>4.0.0</modelVersion>
+
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+</project>
Added:
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/circularReference/CircularReference.bpel
===================================================================
---
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/circularReference/CircularReference.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/circularReference/CircularReference.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<bpel:process
xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
+
xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop"
+
xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
+
xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+
xmlns:ode="http://www.apache.org/ode/type/extension"
+
xmlns:this="http://example.com/CircularReference1"
+
xmlns:xml="http://www.w3.org/XML/1998/namespace"
+
xmlns:atomic="http://ode.apache.org/atomicScope"
+ queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
+ expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
+ name="CircularReference"
+
targetNamespace="http://example.com/CircularReference">
+ <bpel:import
namespace="http://example.com/CircularReference1"
location="CircularReference1.wsdl"
importType="http://schemas.xmlsoap.org/wsdl/"/>
+ <bpel:partnerLinks>
+ <bpel:partnerLink name="pnlk"
+ partnerLinkType="this:pnlkt"
+ myRole="pnlkt_role"/>
+ </bpel:partnerLinks>
+ <bpel:variables>
+ <bpel:variable name="start"
messageType="this:EventStartMessageRequest"/>
+ </bpel:variables>
+
+ <bpel:sequence>
+ <bpel:receive portType="this:portType"
+ operation="EventStartMessage" variable="start"
+ createInstance="yes" name="start" partnerLink="pnlk"
/>
+ </bpel:sequence>
+</bpel:process>
\ No newline at end of file
Added:
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/circularReference/CircularReference1.wsdl
===================================================================
---
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/circularReference/CircularReference1.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/circularReference/CircularReference1.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,50 @@
+<?xml version='1.0' encoding='utf-8'?>
+<wsdl:definitions
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
+xmlns:xs="http://www.w3.org/2001/XMLSchema"
+xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop"
+xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+xmlns:xml="http://www.w3.org/XML/1998/namespace"
+xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+xmlns:this="http://example.com/CircularReference1"
+xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+targetNamespace="http://example.com/CircularReference1">
+ <wsdl:types>
+ <xs:schema elementFormDefault="qualified"
targetNamespace="urn:targetnm">
+ <xs:element name="EventStartMessageRequest"
type="xs:string"/>
+ <xs:element name="EventStartMessageResponse"
type="xs:string"/>
+ </xs:schema>
+ </wsdl:types>
+ <wsdl:import
namespace="http://example.com/CircularReference2"
location="CircularReference2.wsdl"/>
+ <wsdl:message name="EventStartMessageRequest">
+ <wsdl:part name="body"
element="this:EventStartMessageRequest"/>
+ </wsdl:message>
+ <wsdl:message name="EventStartMessageResponse">
+ <wsdl:part name="body"
element="this:EventStartMessageResponse"/>
+ </wsdl:message>
+ <pnlk:partnerLinkType name="pnlkt">
+ <pnlk:role name="pnlkt_role"
portType="this:portType"/>
+ </pnlk:partnerLinkType>
+ <wsdl:portType name="portType">
+ <wsdl:operation name="EventStartMessage">
+ <wsdl:input message="this:EventStartMessageRequest"
name="EventStartMessage"/>
+ <wsdl:output message="this:EventStartMessageResponse"
name="EventStartMessageResponse"/>
+ </wsdl:operation>
+ </wsdl:portType>
+ <wsdl:binding name="binding" type="this:portType">
+ <soap:binding style="document"
transport="http://schemas.xmlsoap.org/soap/http"/>
+ <wsdl:operation name="EventStartMessage">
+ <soap:operation style="document"
soapAction="http://www.example.com/eventStartMessage"/>
+ <wsdl:input name="EventStartMessage">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="EventStartMessageResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ </wsdl:operation>
+ </wsdl:binding>
+ <wsdl:service name="service">
+ <wsdl:port name="servicePort" binding="this:binding">
+ <soap:address
location="http://example.com/hello"/>
+ </wsdl:port>
+ </wsdl:service>
+</wsdl:definitions>
\ No newline at end of file
Added:
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/circularReference/CircularReference2.wsdl
===================================================================
---
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/circularReference/CircularReference2.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/circularReference/CircularReference2.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,47 @@
+<?xml version='1.0' encoding='utf-8'?>
+<wsdl:definitions
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
+xmlns:xs="http://www.w3.org/2001/XMLSchema"
+xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop"
+xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+xmlns:xml="http://www.w3.org/XML/1998/namespace"
+xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+xmlns:this="http://example.com/CircularReference2"
+xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+targetNamespace="http://example.com/CircularReference2">
+ <wsdl:types>
+ <xs:schema elementFormDefault="qualified"
targetNamespace="urn:targetnm">
+ <xs:element name="EventStartMessageRequest1"
type="xs:string"/>
+ <xs:element name="EventStartMessageResponse1"
type="xs:string"/>
+ </xs:schema>
+ </wsdl:types>
+ <wsdl:import
namespace="http://example.com/CircularReference1"
location="CircularReference1.wsdl"/>
+ <wsdl:message name="EventStartMessageRequest1">
+ <wsdl:part name="body"
element="this:EventStartMessageRequest1"/>
+ </wsdl:message>
+ <wsdl:message name="EventStartMessageResponse1">
+ <wsdl:part name="body"
element="this:EventStartMessageResponse1"/>
+ </wsdl:message>
+ <wsdl:portType name="portType1">
+ <wsdl:operation name="EventStartMessage1">
+ <wsdl:input message="this:EventStartMessageRequest1"
name="EventStartMessage1"/>
+ <wsdl:output message="this:EventStartMessageResponse1"
name="EventStartMessageResponse1"/>
+ </wsdl:operation>
+ </wsdl:portType>
+ <wsdl:binding name="binding1" type="this:portType1">
+ <soap:binding style="document"
transport="http://schemas.xmlsoap.org/soap/http"/>
+ <wsdl:operation name="EventStartMessage1">
+ <soap:operation style="document"
soapAction="http://www.example.com/eventStartMessage"/>
+ <wsdl:input name="EventStartMessage1">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="EventStartMessageResponse1">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ </wsdl:operation>
+ </wsdl:binding>
+ <wsdl:service name="service1">
+ <wsdl:port name="servicePort" binding="this:binding1">
+ <soap:address
location="http://example.com/hello"/>
+ </wsdl:port>
+ </wsdl:service>
+</wsdl:definitions>
\ No newline at end of file
Modified:
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/xsd-import/helloworld-Server.bpel
===================================================================
---
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/xsd-import/helloworld-Server.bpel 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/xsd-import/helloworld-Server.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -16,55 +16,55 @@
~ specific language governing permissions and limitations
~ under the License.
-->
-
-<bpel:process
xmlns:bpel="http://schemas.xmlsoap.org/ws/2004/03/business-process/&...
xmlns:pnlk="http://schemas.xmlsoap.org/ws/2004/03/partner-link/"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:Client="http://example.com/helloworld/Client"
xmlns:this="http://example.com/helloworld/Server"
xmlns:tns="http://www.example.org/message"
xmlns:diag="http://example.com/helloworld"
xmlns:bpmn="http://www.intalio.com/bpms"
queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
bpmn:label="Server" bpmn:id="_eAYxsEo7EdyemZotQ08t3A"
name="Server"
targetNamespace="http://example.com/helloworld/Server">
- <bpel:import
namespace="http://example.com/helloworld"
location="helloworld.wsdl"
importType="http://schemas.xmlsoap.org/wsdl/"/>
- <bpel:import
namespace="http://example.com/helloworld/Server"
location="helloworld-Server.wsdl"
importType="http://schemas.xmlsoap.org/wsdl/"/>
- <bpel:import
namespace="http://www.example.org/message"
location="message.xsd"
importType="http://www.w3.org/2001/XMLSchema"></bpel:impo...
- <bpel:partnerLinks>
- <bpel:partnerLink name="serverAndClientPlkVar"
partnerLinkType="diag:ServerAndClient"
myRole="Server_for_Client"/>
- </bpel:partnerLinks>
- <bpel:variables>
- <bpel:variable name="thisReceiveRequestMsg"
messageType="this:receiveRequest"/>
- <bpel:variable name="thisReceiveResponseMsg"
messageType="this:receiveResponse"/>
- <bpel:variable name="Data" type="tns:Data"/>
- </bpel:variables>
- <bpel:sequence>
- <bpel:receive partnerLink="serverAndClientPlkVar"
portType="this:ForClient" operation="receive"
variable="thisReceiveRequestMsg" createInstance="yes"
bpmn:label="receive"
bpmn:id="_evn2QEo7EdyemZotQ08t3A"></bpel:receive>
- <bpel:assign name="init-variables-Server">
- <bpel:copy bpmn:label="$thisReceiveResponseMsg
out:_gfFowEo7EdyemZotQ08t3A">
- <bpel:from>
- <bpel:literal>
-<this:receiveResponse>
-</this:receiveResponse>
- </bpel:literal>
- </bpel:from>
- <bpel:to>$thisReceiveResponseMsg.body</bpel:to>
- </bpel:copy>
- <bpel:copy bpmn:label="$Data">
- <bpel:from>
- <bpel:literal>
- </bpel:literal>
- </bpel:from>
- <bpel:to>$Data</bpel:to>
- </bpel:copy>
- </bpel:assign>
- <bpel:assign bpmn:label="invoke"
bpmn:id="_FrsFcEpAEdySiIWBetfiFA">
- <bpel:copy>
- <bpel:from>"test"</bpel:from>
- <bpel:to>$Data/tns:Name</bpel:to>
- </bpel:copy>
- <bpel:copy>
- <bpel:from>"world"</bpel:from>
- <bpel:to>$Data/tns:Age</bpel:to>
- </bpel:copy>
- </bpel:assign>
- <bpel:assign bpmn:label="result"
bpmn:id="_fz4IkEo7EdyemZotQ08t3A">
- <bpel:copy>
- <bpel:from>concat($Data/tns:Name, $Data/tns:Age)</bpel:from>
- <bpel:to>$thisReceiveResponseMsg.body</bpel:to>
- </bpel:copy>
- </bpel:assign>
- <bpel:reply partnerLink="serverAndClientPlkVar"
portType="this:ForClient" operation="receive"
variable="thisReceiveResponseMsg" bpmn:label="result"
bpmn:id="_fz4IkEo7EdyemZotQ08t3A"></bpel:reply>
- </bpel:sequence>
+
+<bpel:process
xmlns:bpel="http://schemas.xmlsoap.org/ws/2004/03/business-process/&...
xmlns:pnlk="http://schemas.xmlsoap.org/ws/2004/03/partner-link/"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:Client="http://example.com/helloworld/Client"
xmlns:this="http://example.com/helloworld/Server"
xmlns:tns="http://www.example.org/message"
xmlns:diag="http://example.com/helloworld"
xmlns:bpmn="http://www.intalio.com/bpms"
queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
bpmn:label="Server" bpmn:id="_eAYxsEo7EdyemZotQ08t3A"
name="Server"
targetNamespace="http://example.com/helloworld/Server">
+ <bpel:import
namespace="http://example.com/helloworld"
location="helloworld.wsdl"
importType="http://schemas.xmlsoap.org/wsdl/"/>
+ <bpel:import
namespace="http://example.com/helloworld/Server"
location="helloworld-Server.wsdl"
importType="http://schemas.xmlsoap.org/wsdl/"/>
+ <bpel:import
namespace="http://www.example.org/message"
location="message.xsd"
importType="http://www.w3.org/2001/XMLSchema"></bpel:impo...
+ <bpel:partnerLinks>
+ <bpel:partnerLink name="serverAndClientPlkVar"
partnerLinkType="diag:ServerAndClient"
myRole="Server_for_Client"/>
+ </bpel:partnerLinks>
+ <bpel:variables>
+ <bpel:variable name="thisReceiveRequestMsg"
messageType="this:receiveRequest"/>
+ <bpel:variable name="thisReceiveResponseMsg"
messageType="this:receiveResponse"/>
+ <bpel:variable name="Data" type="tns:Data"/>
+ </bpel:variables>
+ <bpel:sequence>
+ <bpel:receive partnerLink="serverAndClientPlkVar"
portType="this:ForClient" operation="receive"
variable="thisReceiveRequestMsg" createInstance="yes"
bpmn:label="receive"
bpmn:id="_evn2QEo7EdyemZotQ08t3A"></bpel:receive>
+ <bpel:assign name="init-variables-Server">
+ <bpel:copy bpmn:label="$thisReceiveResponseMsg
out:_gfFowEo7EdyemZotQ08t3A">
+ <bpel:from>
+ <bpel:literal>
+<this:receiveResponse>
+</this:receiveResponse>
+ </bpel:literal>
+ </bpel:from>
+ <bpel:to>$thisReceiveResponseMsg.body</bpel:to>
+ </bpel:copy>
+ <bpel:copy bpmn:label="$Data">
+ <bpel:from>
+ <bpel:literal>
+ </bpel:literal>
+ </bpel:from>
+ <bpel:to>$Data</bpel:to>
+ </bpel:copy>
+ </bpel:assign>
+ <bpel:assign bpmn:label="invoke"
bpmn:id="_FrsFcEpAEdySiIWBetfiFA">
+ <bpel:copy>
+ <bpel:from>"test"</bpel:from>
+ <bpel:to>$Data/tns:Name</bpel:to>
+ </bpel:copy>
+ <bpel:copy>
+ <bpel:from>"world"</bpel:from>
+ <bpel:to>$Data/tns:Age</bpel:to>
+ </bpel:copy>
+ </bpel:assign>
+ <bpel:assign bpmn:label="result"
bpmn:id="_fz4IkEo7EdyemZotQ08t3A">
+ <bpel:copy>
+ <bpel:from>concat($Data/tns:Name, $Data/tns:Age)</bpel:from>
+ <bpel:to>$thisReceiveResponseMsg.body</bpel:to>
+ </bpel:copy>
+ </bpel:assign>
+ <bpel:reply partnerLink="serverAndClientPlkVar"
portType="this:ForClient" operation="receive"
variable="thisReceiveResponseMsg" bpmn:label="result"
bpmn:id="_fz4IkEo7EdyemZotQ08t3A"></bpel:reply>
+ </bpel:sequence>
</bpel:process>
\ No newline at end of file
Modified:
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/xsd-import/helloworld-Server.wsdl
===================================================================
---
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/xsd-import/helloworld-Server.wsdl 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/xsd-import/helloworld-Server.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -16,41 +16,41 @@
~ specific language governing permissions and limitations
~ under the License.
-->
-
-<wsdl:definitions
xmlns:tns="http://www.example.org/message"
xmlns:Client="http://example.com/helloworld/Client"
xmlns:diag="http://example.com/helloworld"
xmlns:bpel="http://schemas.xmlsoap.org/ws/2004/03/business-process/&...
xmlns:pnlk="http://schemas.xmlsoap.org/ws/2004/03/partner-link/"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:this="http://example.com/helloworld/Server"
targetNamespace="http://example.com/helloworld/Server">
- <wsdl:types>
- <xs:schema elementFormDefault="qualified"
targetNamespace="http://example.com/helloworld/Server">
- <xs:element name="receiveRequest"
type="xs:string"/>
- <xs:element name="receiveResponse"
type="xs:string"/>
- </xs:schema>
- </wsdl:types>
- <wsdl:message name="receiveRequest">
- <wsdl:part name="body" element="this:receiveRequest"/>
- </wsdl:message>
- <wsdl:message name="receiveResponse">
- <wsdl:part name="body"
element="this:receiveResponse"/>
- </wsdl:message>
- <wsdl:portType name="ForClient">
- <wsdl:operation name="receive">
- <wsdl:input message="this:receiveRequest"
name="receive"/>
- <wsdl:output message="this:receiveResponse"
name="receiveResponse"/>
- </wsdl:operation>
- </wsdl:portType>
- <wsdl:binding name="CanonicBindingForClient"
type="this:ForClient">
- <soap:binding style="document"
transport="http://schemas.xmlsoap.org/soap/http"/>
- <wsdl:operation name="receive">
- <soap:operation style="document"
soapAction="http://example.com/helloworld/Server/ForClient/receive&q...
- <wsdl:input>
- <soap:body use="literal"/>
- </wsdl:input>
- <wsdl:output>
- <soap:body use="literal"/>
- </wsdl:output>
- </wsdl:operation>
- </wsdl:binding>
- <wsdl:service name="CanonicServiceForClient">
- <wsdl:port name="canonicPort"
binding="this:CanonicBindingForClient">
- <soap:address
location="http://localhost:8080/ode/processes/HelloWorld/helloworld/Server/Client"/>
- </wsdl:port>
- </wsdl:service>
+
+<wsdl:definitions
xmlns:tns="http://www.example.org/message"
xmlns:Client="http://example.com/helloworld/Client"
xmlns:diag="http://example.com/helloworld"
xmlns:bpel="http://schemas.xmlsoap.org/ws/2004/03/business-process/&...
xmlns:pnlk="http://schemas.xmlsoap.org/ws/2004/03/partner-link/"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:this="http://example.com/helloworld/Server"
targetNamespace="http://example.com/helloworld/Server">
+ <wsdl:types>
+ <xs:schema elementFormDefault="qualified"
targetNamespace="http://example.com/helloworld/Server">
+ <xs:element name="receiveRequest"
type="xs:string"/>
+ <xs:element name="receiveResponse"
type="xs:string"/>
+ </xs:schema>
+ </wsdl:types>
+ <wsdl:message name="receiveRequest">
+ <wsdl:part name="body" element="this:receiveRequest"/>
+ </wsdl:message>
+ <wsdl:message name="receiveResponse">
+ <wsdl:part name="body"
element="this:receiveResponse"/>
+ </wsdl:message>
+ <wsdl:portType name="ForClient">
+ <wsdl:operation name="receive">
+ <wsdl:input message="this:receiveRequest"
name="receive"/>
+ <wsdl:output message="this:receiveResponse"
name="receiveResponse"/>
+ </wsdl:operation>
+ </wsdl:portType>
+ <wsdl:binding name="CanonicBindingForClient"
type="this:ForClient">
+ <soap:binding style="document"
transport="http://schemas.xmlsoap.org/soap/http"/>
+ <wsdl:operation name="receive">
+ <soap:operation style="document"
soapAction="http://example.com/helloworld/Server/ForClient/receive&q...
+ <wsdl:input>
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output>
+ <soap:body use="literal"/>
+ </wsdl:output>
+ </wsdl:operation>
+ </wsdl:binding>
+ <wsdl:service name="CanonicServiceForClient">
+ <wsdl:port name="canonicPort"
binding="this:CanonicBindingForClient">
+ <soap:address
location="http://localhost:8080/ode/processes/HelloWorld/helloworld/Server/Client"/>
+ </wsdl:port>
+ </wsdl:service>
</wsdl:definitions>
\ No newline at end of file
Modified:
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/xsd-import/helloworld.wsdl
===================================================================
---
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/xsd-import/helloworld.wsdl 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/xsd-import/helloworld.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -16,10 +16,10 @@
~ specific language governing permissions and limitations
~ under the License.
-->
-
-<wsdl:definitions
xmlns:tns="http://www.example.org/message"
xmlns:bpdm="http://www.intalio/designer/business-process-data-modeling"
xmlns:Client="http://example.com/helloworld/Client"
xmlns:diag="http://example.com/helloworld"
xmlns:bpel="http://schemas.xmlsoap.org/ws/2004/03/business-process/&...
xmlns:pnlk="http://schemas.xmlsoap.org/ws/2004/03/partner-link/"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns:Server="http://example.com/helloworld/Server"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
targetNamespace="http://example.com/helloworld">
- <wsdl:import
namespace="http://example.com/helloworld/Server"
location="helloworld-Server.wsdl"/>
- <pnlk:partnerLinkType name="ServerAndClient">
- <pnlk:role name="Server_for_Client"
portType="Server:ForClient"/>
- </pnlk:partnerLinkType>
+
+<wsdl:definitions
xmlns:tns="http://www.example.org/message"
xmlns:bpdm="http://www.intalio/designer/business-process-data-modeling"
xmlns:Client="http://example.com/helloworld/Client"
xmlns:diag="http://example.com/helloworld"
xmlns:bpel="http://schemas.xmlsoap.org/ws/2004/03/business-process/&...
xmlns:pnlk="http://schemas.xmlsoap.org/ws/2004/03/partner-link/"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns:Server="http://example.com/helloworld/Server"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
targetNamespace="http://example.com/helloworld">
+ <wsdl:import
namespace="http://example.com/helloworld/Server"
location="helloworld-Server.wsdl"/>
+ <pnlk:partnerLinkType name="ServerAndClient">
+ <pnlk:role name="Server_for_Client"
portType="Server:ForClient"/>
+ </pnlk:partnerLinkType>
</wsdl:definitions>
\ No newline at end of file
Modified:
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/xsd-import/message.xsd
===================================================================
---
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/xsd-import/message.xsd 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-scripts/src/main/resources/2.0/good/xsd-import/message.xsd 2010-04-14
18:25:55 UTC (rev 620)
@@ -26,5 +26,5 @@
<element name="Name" type="string"></element>
<element name="Age" type="string"></element>
</sequence>
- </complexType>
+ </complexType>
</schema>
\ No newline at end of file
Added: branches/ODE/ODE-1.x/bpel-store/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/bpel-store/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/bpel-store/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,218 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-store</artifactId>
+ <name>ODE :: Process Store</name>
+ <packaging>jar</packaging>
+ <modelVersion>4.0.0</modelVersion>
+
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-compiler</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-dao</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-schemas</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-epr</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-dao-hibernate</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-dao-jpa</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-utils</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-logging</groupId>
+ <artifactId>commons-logging</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.hibernate</groupId>
+ <artifactId>hibernate</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>javax.persistence</groupId>
+ <artifactId>persistence-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-stax-api_1.0_spec</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>hsqldb</groupId>
+ <artifactId>hsqldb</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.xmlbeans</groupId>
+ <artifactId>xmlbeans</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>xerces</groupId>
+ <artifactId>xercesImpl</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>wsdl4j</groupId>
+ <artifactId>wsdl4j</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>commons-collections</groupId>
+ <artifactId>commons-collections</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>commons-lang</groupId>
+ <artifactId>commons-lang</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-j2ee-connector_1.5_spec</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-jta_1.1_spec</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>log4j</groupId>
+ <artifactId>log4j</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>jaxen</groupId>
+ <artifactId>jaxen</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>dom4j</groupId>
+ <artifactId>dom4j</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>xalan</groupId>
+ <artifactId>xalan</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-log4j12</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.openjpa</groupId>
+ <artifactId>openjpa</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>net.sourceforge.serp</groupId>
+ <artifactId>serp</artifactId>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <artifactId>maven-antrun-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>openjpa-enhancer</id>
+ <phase>process-classes</phase>
+ <goals>
+ <goal>run</goal>
+ </goals>
+ <configuration>
+ <tasks>
+ <property name="maven.runtime.classpath"
refid="maven.test.classpath"/>
+ <path id="classpath">
+ <pathelement path="${maven.runtime.classpath}"/>
+ </path>
+ <taskdef name="openjpac"
classname="org.apache.openjpa.ant.PCEnhancerTask"
classpathref="classpath"/>
+ <openjpac>
+ <fileset dir="${basedir}/src/main">
+ <include name="**/*.java" />
+ </fileset>
+ <classpath>
+ <pathelement location="${basedir}/target/classes"/>
+ <pathelement path="${maven.runtime.classpath}"/>
+ </classpath>
+ </openjpac>
+ </tasks>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>xdoclet-maven-plugin</artifactId>
+ <executions>
+ <execution>
+ <phase>generate-sources</phase>
+ <goals>
+ <goal>xdoclet</goal>
+ </goals>
+
+ <configuration>
+ <tasks>
+ <hibernatedoclet excludedTags="@version,@author,@todo"
verbose="true"
+ destdir="${project.build.outputDirectory}"
force="true">
+ <hibernate version="3.0"/>
+ <fileset dir="${project.build.sourceDirectory}"
includes="org/apache/ode/store/hib/*.java"/>
+ </hibernatedoclet>
+ </tasks>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+</project>
Modified:
branches/ODE/ODE-1.x/bpel-store/src/main/java/org/apache/ode/store/DeploymentUnitDir.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-store/src/main/java/org/apache/ode/store/DeploymentUnitDir.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-store/src/main/java/org/apache/ode/store/DeploymentUnitDir.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -39,6 +39,7 @@
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.apache.ode.bpel.compiler.BpelC;
+import org.apache.ode.bpel.compiler.BpelCompiler;
import org.apache.ode.bpel.compiler.DefaultResourceFinder;
import org.apache.ode.bpel.compiler.WSDLLocatorImpl;
import org.apache.ode.bpel.compiler.wsdl.Definition4BPEL;
@@ -139,7 +140,14 @@
if (bpels.size() == 0)
throw new IllegalArgumentException("Directory " +
_duDirectory.getName() + " does not contain any process!");
for (File bpel : bpels) {
- compile(bpel);
+ String b = bpel.getAbsolutePath();
+ File cbp = new File(b.substring(0,b.lastIndexOf(".bpel")) +
".cbp");
+ if (!cbp.exists()) {
+ __log.debug("compiling " + bpel);
+ compile(bpel);
+ } else {
+ __log.debug("skipping compilation of " + bpel + " cbp found:
" + cbp);
+ }
}
}
@@ -178,7 +186,7 @@
InternPool.runBlock(new InternableBlock() {
public void run() {
try {
- bpelc.compile(bpelFile);
+ bpelc.compile(bpelFile, getVersion());
} catch (IOException e) {
__log.error("Compile error in " + bpelFile, e);
}
@@ -376,6 +384,13 @@
public long getVersion() {
return _version;
}
+
+ /**
+ * @return Static DU version number generated from DU name. -1 when package
doesn't use versioning.
+ */
+ public long getStaticVersion() {
+ return BpelCompiler.getVersion(getName());
+ }
public void setVersion(long version) {
_version = version;
Modified:
branches/ODE/ODE-1.x/bpel-store/src/main/java/org/apache/ode/store/ProcessConfImpl.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-store/src/main/java/org/apache/ode/store/ProcessConfImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-store/src/main/java/org/apache/ode/store/ProcessConfImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -33,6 +33,7 @@
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
+import org.apache.ode.activityRecovery.FailureHandlingDocument.FailureHandling;
import org.apache.ode.bpel.dd.TCleanup;
import org.apache.ode.bpel.dd.TDeployment;
import org.apache.ode.bpel.dd.TInvoke;
@@ -49,6 +50,8 @@
import org.apache.ode.bpel.iapi.ProcessState;
import org.apache.ode.bpel.iapi.EndpointReferenceContext;
import org.apache.ode.bpel.iapi.EndpointReference;
+import org.apache.ode.bpel.iapi.ProcessConf.PartnerRoleConfig;
+import org.apache.ode.bpel.o.OFailureHandling;
import org.apache.ode.store.DeploymentUnitDir.CBPInfo;
import org.apache.ode.utils.CronExpression;
import org.apache.ode.utils.DOMUtils;
@@ -72,6 +75,7 @@
private File _configDir;
private final Map<QName, Node> _props;
private final HashMap<String, Endpoint> _partnerRoleInitialValues = new
HashMap<String, Endpoint>();
+ private final HashMap<String, PartnerRoleConfig> _partnerRoleConfig = new
HashMap<String, PartnerRoleConfig>();
private final HashMap<String, Endpoint> _myRoleEndpoints = new
HashMap<String, Endpoint>();
private final ArrayList<QName> _sharedServices = new ArrayList<QName>();
@@ -93,9 +97,11 @@
private EndpointReferenceContext eprContext;
private final ProcessCleanupConfImpl processCleanupConfImpl;
+
+ private final boolean generateProcessEventsAll;
ProcessConfImpl(QName pid, QName type, long version, DeploymentUnitDir du,
TDeployment.Process pinfo, Date deployDate,
- Map<QName, Node> props, ProcessState pstate,
EndpointReferenceContext eprContext, File configDir) {
+ Map<QName, Node> props, ProcessState pstate,
EndpointReferenceContext eprContext, File configDir, boolean generateProcessEventsAll) {
_pid = pid;
_version = version;
_du = du;
@@ -106,6 +112,7 @@
_state = pstate;
_type = type;
_inMemory = _pinfo.isSetInMemory() && _pinfo.getInMemory();
+ this.generateProcessEventsAll = generateProcessEventsAll;
this.eprContext = eprContext;
propertiesWatchDog = new WatchDog<Map<File, Long>,
PropertiesObserver>(new PropertiesMutable(), new PropertiesObserver());
@@ -164,6 +171,22 @@
__log.debug("Processing <invoke> element for process " +
_pinfo.getName() + ": partnerlink " + plinkName + " --> "
+ service);
_partnerRoleInitialValues.put(plinkName, new Endpoint(service.getName(),
service.getPort()));
+
+ {
+ OFailureHandling g = null;
+
+ if (invoke.isSetFailureHandling()) {
+ FailureHandling f = invoke.getFailureHandling();
+ g = new OFailureHandling();
+ if (f.isSetFaultOnFailure()) g.faultOnFailure =
f.getFaultOnFailure();
+ if (f.isSetRetryDelay()) g.retryDelay = f.getRetryDelay();
+ if (f.isSetRetryFor()) g.retryFor = f.getRetryFor();
+ }
+
+ PartnerRoleConfig c = new PartnerRoleConfig(g,
invoke.getUsePeer2Peer());
+ __log.debug("PartnerRoleConfig for " + plinkName + "
" + c.failureHandling + " usePeer2Peer: " + c.usePeer2Peer);
+ _partnerRoleConfig.put(plinkName, c);
+ }
}
}
@@ -283,6 +306,10 @@
return Collections.unmodifiableMap(_partnerRoleInitialValues);
}
+ public Map<String, PartnerRoleConfig> getPartnerRoleConfig() {
+ return Collections.unmodifiableMap(_partnerRoleConfig);
+ }
+
public Map<String, Endpoint> getProvideEndpoints() {
return Collections.unmodifiableMap(_myRoleEndpoints);
}
@@ -361,11 +388,13 @@
TProcessEvents processEvents = _pinfo.getProcessEvents();
// No filtering, using defaults
if (processEvents == null) {
- HashSet<BpelEvent.TYPE> all = new HashSet<BpelEvent.TYPE>();
- for (BpelEvent.TYPE t : BpelEvent.TYPE.values()) {
- if (!t.equals(BpelEvent.TYPE.scopeHandling)) all.add(t);
+ if (generateProcessEventsAll) {
+ HashSet<BpelEvent.TYPE> all = new HashSet<BpelEvent.TYPE>();
+ for (BpelEvent.TYPE t : BpelEvent.TYPE.values()) {
+ if (!t.equals(BpelEvent.TYPE.scopeHandling)) all.add(t);
+ }
+ _events.put(null, all);
}
- _events.put(null, all);
return;
}
@@ -379,7 +408,7 @@
}
// Events filtered at the process level
- if (processEvents.getEnableEventList() != null) {
+ if (processEvents.getEnableEventList() != null &&
!processEvents.getEnableEventList().isEmpty()) {
List<String> enabled = processEvents.getEnableEventList();
HashSet<BpelEvent.TYPE> evtSet = new HashSet<BpelEvent.TYPE>();
for (String enEvt : enabled) {
@@ -428,7 +457,7 @@
// do it manually to save resources (instead of using a thread)
propertiesWatchDog.check();
final Map prop = propertiesWatchDog.getObserver().get().getProperties(service,
port);
- if(!map.isEmpty() && __log.isDebugEnabled()) {
+ if(!prop.isEmpty() && __log.isDebugEnabled()) {
StringBuilder msg = new StringBuilder("Properties for ");
if(service!=null) msg.append("service ").append(service);
if(port!=null) msg.append(", port ").append(port);
Modified:
branches/ODE/ODE-1.x/bpel-store/src/main/java/org/apache/ode/store/ProcessStoreImpl.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-store/src/main/java/org/apache/ode/store/ProcessStoreImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-store/src/main/java/org/apache/ode/store/ProcessStoreImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -23,18 +23,12 @@
import org.apache.ode.bpel.compiler.api.CompilationException;
import org.apache.ode.bpel.dd.DeployDocument;
import org.apache.ode.bpel.dd.TDeployment;
-import org.apache.ode.bpel.iapi.ContextException;
-import org.apache.ode.bpel.iapi.ProcessConf;
-import org.apache.ode.bpel.iapi.ProcessState;
-import org.apache.ode.bpel.iapi.ProcessStore;
-import org.apache.ode.bpel.iapi.ProcessStoreEvent;
-import org.apache.ode.bpel.iapi.ProcessStoreListener;
-import org.apache.ode.bpel.iapi.EndpointReferenceContext;
+import org.apache.ode.bpel.iapi.*;
+import org.apache.ode.il.config.OdeConfigProperties;
import org.apache.ode.store.DeploymentUnitDir.CBPInfo;
import org.apache.ode.utils.DOMUtils;
import org.apache.ode.utils.GUID;
import org.apache.ode.utils.msg.MessageBundle;
-import org.apache.ode.il.config.OdeConfigProperties;
import org.hsqldb.jdbc.jdbcDataSource;
import org.w3c.dom.Document;
import org.w3c.dom.Element;
@@ -46,13 +40,11 @@
import java.io.IOException;
import java.sql.SQLException;
import java.util.*;
-import java.util.concurrent.CopyOnWriteArrayList;
-import java.util.concurrent.ExecutorService;
-import java.util.concurrent.Executors;
-import java.util.concurrent.Future;
-import java.util.concurrent.ThreadFactory;
+import java.util.concurrent.*;
import java.util.concurrent.locks.ReadWriteLock;
import java.util.concurrent.locks.ReentrantReadWriteLock;
+import java.util.regex.Matcher;
+import java.util.regex.Pattern;
/**
* <p>
@@ -89,6 +81,8 @@
private ConfStoreConnectionFactory _cf;
private EndpointReferenceContext eprContext;
+
+ private boolean generateProcessEventsAll;
protected File _deployDir;
@@ -113,6 +107,7 @@
public ProcessStoreImpl(EndpointReferenceContext eprContext, DataSource ds, String
persistenceType, OdeConfigProperties props, boolean createDatamodel) {
this.eprContext = eprContext;
+ this.generateProcessEventsAll =
props.getProperty("generateProcessEvents",
"all").equals("all");
if (ds != null) {
// ugly hack
if (persistenceType.toLowerCase().indexOf("hib") != -1) {
@@ -165,14 +160,18 @@
/**
* Deploys a process.
*/
+ public Collection<QName> deploy(final File deploymentUnitDirectory, boolean
autoincrementVersion) {
+ return deploy(deploymentUnitDirectory, true, null, autoincrementVersion);
+ }
+
public Collection<QName> deploy(final File deploymentUnitDirectory) {
- return deploy(deploymentUnitDirectory, true, null);
+ return deploy(deploymentUnitDirectory, true, null, true);
}
/**
* Deploys a process.
*/
- public Collection<QName> deploy(final File deploymentUnitDirectory, boolean
activate, String duName) {
+ public Collection<QName> deploy(final File deploymentUnitDirectory, boolean
activate, String duName, boolean autoincrementVersion) {
__log.info(__msgs.msgDeployStarting(deploymentUnitDirectory));
final Date deployDate = new Date();
@@ -183,6 +182,20 @@
// Override the package name if given from the parameter
du.setName(duName);
}
+
+ long version;
+ if (autoincrementVersion || du.getStaticVersion() == -1) {
+ // Process and DU use a monotonically increased single version number by
default.
+ version = exec(new Callable<Long>() {
+ public Long call(ConfStoreConnection conn) {
+ return conn.getNextVersion();
+ }
+ });
+ } else {
+ version = du.getStaticVersion();
+ }
+ du.setVersion(version);
+
try {
du.compile();
} catch (CompilationException ce) {
@@ -197,12 +210,6 @@
Collection<QName> deployed;
_rw.writeLock().lock();
- // Process and DU use a monotonically increased single version number.
- long version = exec(new Callable<Long>() {
- public Long call(ConfStoreConnection conn) {
- return conn.getNextVersion();
- }
- });
try {
if (_deploymentUnits.containsKey(du.getName())) {
@@ -211,16 +218,11 @@
throw new ContextException(errmsg);
}
- du.setVersion(version);
+ retirePreviousPackageVersions(du);
for (TDeployment.Process processDD : dd.getDeploy().getProcessList()) {
QName pid = toPid(processDD.getName(), version);
- // Retires older version if we can find one
- DeploymentUnitDir oldDU = findOldDU(du.getName());
- if (oldDU != null)
- setRetiredPackage(oldDU.getName(), true);
-
if (_processes.containsKey(pid)) {
String errmsg = __msgs.msgDeployFailDuplicatePID(processDD.getName(),
du.getName());
__log.error(errmsg);
@@ -237,7 +239,7 @@
}
ProcessConfImpl pconf = new ProcessConfImpl(pid, processDD.getName(),
version, du, processDD, deployDate,
- calcInitialProperties(processDD), calcInitialState(processDD),
eprContext, _configDir);
+ calcInitialProperties(processDD), calcInitialState(processDD),
eprContext, _configDir, generateProcessEventsAll);
processes.add(pconf);
}
@@ -296,7 +298,7 @@
}
});
-
+
// We want the events to be fired outside of the bounds of the writelock.
try {
for (ProcessConfImpl process : processes) {
@@ -315,6 +317,36 @@
return deployed;
}
+ /**
+ * Retire all the other versions of the same DU:
+ * first take the DU name and insert version regexp,
+ * than try to match the this string against names of already deployed DUs.
+ * For instance if we are deploying DU
"AbsenceRequest-2/AbsenceRequest.ode" and
+ * there's already version 2 than regexp
+ * "AbsenceRequest([-\\.](\d)+)?/AbsenceRequest.ode" will be matched
against
+ * "AbsenceRequest-2/AbsenceRequest.ode" and setRetirePackage() will be
called accordingly.
+ */
+ private void retirePreviousPackageVersions(DeploymentUnitDir du) {
+ //retire all the other versions of the same DU
+ String[] nameParts = du.getName().split("/");
+ /* Replace the version number (if any) with regexp to match any version number
*/
+ nameParts[0] = nameParts[0].replaceAll("([-\\Q.\\E](\\d)+)?\\z",
"");
+ nameParts[0] += "([-\\Q.\\E](\\d)+)?";
+ StringBuilder duNameRegExp = new StringBuilder(du.getName().length() * 2);
+ for (int i = 0, n = nameParts.length; i < n; i++) {
+ if (i > 0) duNameRegExp.append("/");
+ duNameRegExp.append(nameParts[i]);
+ }
+
+ Pattern duNamePattern = Pattern.compile(duNameRegExp.toString());
+ for (String deployedDUname : _deploymentUnits.keySet()) {
+ Matcher matcher = duNamePattern.matcher(deployedDUname);
+ if (matcher.matches()) {
+ setRetiredPackage(deployedDUname, true);
+ }
+ }
+ }
+
public Collection<QName> undeploy(final File dir) {
return undeploy(dir.getName());
}
@@ -341,17 +373,12 @@
if (du != null) {
undeployed = toPids(du.getProcessNames(), du.getVersion());
}
- } finally {
- _rw.writeLock().unlock();
- }
-
- for (QName pn : undeployed) {
- fireEvent(new ProcessStoreEvent(ProcessStoreEvent.Type.UNDEPLOYED, pn,
du.getName()));
- __log.info(__msgs.msgProcessUndeployed(pn));
- }
-
- _rw.writeLock().lock();
- try {
+
+ for (QName pn : undeployed) {
+ fireEvent(new ProcessStoreEvent(ProcessStoreEvent.Type.UNDEPLOYED, pn,
du.getName()));
+ __log.info(__msgs.msgProcessUndeployed(pn));
+ }
+
_processes.keySet().removeAll(undeployed);
} finally {
_rw.writeLock().unlock();
@@ -497,6 +524,18 @@
}
});
+ // Dispatch DISABLED, RETIRED and ACTIVE events in that order
+ Collections.sort(loaded, new Comparator<ProcessConf>() {
+ public int compare(ProcessConf o1, ProcessConf o2) {
+ return stateValue(o1.getState()) - stateValue(o2.getState());
+ }
+ int stateValue(ProcessState state) {
+ if (ProcessState.DISABLED.equals(state)) return 0;
+ if (ProcessState.RETIRED.equals(state)) return 1;
+ if (ProcessState.ACTIVE.equals(state)) return 2;
+ throw new IllegalStateException("Unexpected process state:
"+state);
+ }
+ });
for (ProcessConfImpl p : loaded) {
try {
fireStateChange(p.getProcessId(), p.getState(),
p.getDeploymentUnit().getName());
@@ -657,7 +696,7 @@
// TODO: update the props based on the values in the DB.
ProcessConfImpl pconf = new ProcessConfImpl(p.getPID(), p.getType(),
p.getVersion(), dud, pinfo, dudao
- .getDeployDate(), props, p.getState(), eprContext, _configDir);
+ .getDeployDate(), props, p.getState(), eprContext, _configDir,
generateProcessEventsAll);
version = p.getVersion();
_processes.put(pconf.getProcessId(), pconf);
@@ -678,8 +717,14 @@
if (f.exists())
return f;
f = new File(_deployDir, dudao.getName());
- if (f.exists())
+ if (f.exists()) {
+ try {
+ dudao.setDeploymentUnitDir(f.getCanonicalPath());
+ } catch (IOException e) {
+ __log.warn("Could not update deployment unit directory for " +
dudao.getName(), e);
+ }
return f;
+ }
return null;
}
@@ -804,23 +849,6 @@
return new QName(processType.getNamespaceURI(), processType.getLocalPart() +
"-" + version);
}
- private DeploymentUnitDir findOldDU(String newName) {
- DeploymentUnitDir old = null;
- int dashIdx = newName.lastIndexOf("-");
- if (dashIdx > 0 && dashIdx + 1 < newName.length()) {
- String radical = newName.substring(0, dashIdx);
- int newVersion = -1;
- try {
- newVersion =
Integer.parseInt(newName.substring(newName.lastIndexOf("-") + 1));
- } catch (NumberFormatException e) {
- // Swallowing, if we can't parse then we just can't find an old
version
- }
- while (old == null && newVersion >= 0)
- old = _deploymentUnits.get(radical + "-" + (newVersion--));
- }
- return old;
- }
-
private class SimpleThreadFactory implements ThreadFactory {
int threadNumber = 0;
public Thread newThread(Runnable r) {
Modified:
branches/ODE/ODE-1.x/bpel-store/src/main/java/org/apache/ode/store/jpa/DbConfStoreConnectionFactory.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-store/src/main/java/org/apache/ode/store/jpa/DbConfStoreConnectionFactory.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-store/src/main/java/org/apache/ode/store/jpa/DbConfStoreConnectionFactory.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -49,7 +49,7 @@
initTxMgr(txFactoryClassName);
HashMap<String, Object> propMap = new HashMap<String,Object>();
- propMap.put("openjpa.Log", "log4j");
+ propMap.put("openjpa.Log", "commons");
propMap.put("openjpa.ManagedRuntime", new JpaTxMgrProvider(_txMgr));
propMap.put("openjpa.ConnectionFactory", _ds);
propMap.put("openjpa.ConnectionFactoryMode", "managed");
Added: branches/ODE/ODE-1.x/bpel-test/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/bpel-test/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/bpel-test/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,169 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-test</artifactId>
+ <name>ODE :: BPEL Tests</name>
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-compiler</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-dao</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-store</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-utils</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-epr</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-dao-jpa</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-runtime</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jacob</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-schemas</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-scripts</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-scheduler-simple</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>commons-collections</groupId>
+ <artifactId>commons-collections</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-logging</groupId>
+ <artifactId>commons-logging</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-httpclient</groupId>
+ <artifactId>commons-httpclient</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-lang</groupId>
+ <artifactId>commons-lang</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>jaxen</groupId>
+ <artifactId>jaxen</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-jta_1.1_spec</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-stax-api_1.0_spec</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>javax.persistence</groupId>
+ <artifactId>persistence-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>wsdl4j</groupId>
+ <artifactId>wsdl4j</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.xmlbeans</groupId>
+ <artifactId>xmlbeans</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon-xpath</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon-dom</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon-xqj</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>xerces</groupId>
+ <artifactId>xercesImpl</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <artifactId>maven-surefire-plugin</artifactId>
+ <configuration>
+ <!-- FIXME: temporary skip it, 3 failed test cases (2 in JDK6, 3 in JDK5):
testIMA, testRetireOld, testIsolated**-->
+ <excludes>
+ <!--
+ <exclude>**/MessageRouting20Test.java</exclude>
+ <exclude>**/VersionedRedeployTest.java</exclude>
+ <exclude>**/StructuredActivities20Test.java</exclude>
+ -->
+ </excludes>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+</project>
Modified:
branches/ODE/ODE-1.x/bpel-test/src/main/java/org/apache/ode/test/BPELTestAbstract.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/main/java/org/apache/ode/test/BPELTestAbstract.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/main/java/org/apache/ode/test/BPELTestAbstract.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -234,11 +234,14 @@
final QName serviceId = new
QName(testProps.getProperty("namespace"),
testProps.getProperty("service"));
final String operation = testProps.getProperty("operation");
+ Boolean sequential =
Boolean.parseBoolean(testProps.getProperty("sequential", "false"));
+
+ Invocation last = null;
for (int i = 1; testProps.getProperty("request" + i) != null; i++)
{
final String in = testProps.getProperty("request" + i);
final String responsePattern = testProps.getProperty("response"
+ i);
- addInvoke(testPropsFile + "#" + i, serviceId, operation, in,
responsePattern);
+ last = addInvoke(testPropsFile + "#" + i, serviceId, operation,
in, responsePattern, sequential ? last : null);
}
propsFileCnt++;
testPropsFile = new File(deployDir, "test" + propsFileCnt +
".properties");
@@ -246,8 +249,13 @@
}
protected Invocation addInvoke(String id, QName target, String operation, String
request, String responsePattern) throws Exception {
+ return addInvoke(id, target, operation, request, responsePattern, null);
+ }
+
+ protected Invocation addInvoke(String id, QName target, String operation, String
request, String responsePattern, Invocation synchronizeWith)
+ throws Exception {
- Invocation inv = new Invocation(id);
+ Invocation inv = new Invocation(id, synchronizeWith);
inv.target = target;
inv.operation = operation;
inv.request = DOMUtils.stringToDOM(request);
@@ -486,6 +494,12 @@
/** Identifier (for reporting). */
public String id;
+ /** for sync invocations */
+ public Invocation synchronizeWith;
+
+ /** checking completion */
+ public boolean done = false;
+
/** Name of the operation to invoke. */
public String operation;
@@ -528,8 +542,9 @@
QName requestType;
- public Invocation(String id) {
+ public Invocation(String id, Invocation synchronizeWith) {
this.id = id;
+ this.synchronizeWith = synchronizeWith;
}
public String toString() {
@@ -546,6 +561,17 @@
}
public void run() {
+ try {
+ run2();
+ } finally {
+ synchronized (_invocation) {
+ _invocation.done = true;
+ _invocation.notify();
+ }
+ }
+ }
+
+ public void run2() {
final MyRoleMessageExchange mex;
final Future<MessageExchange.Status> running;
@@ -554,6 +580,19 @@
Thread.sleep(_invocation.invokeDelayMs);
} catch (Exception ex) {
}
+
+ if (_invocation.synchronizeWith != null) {
+ synchronized (_invocation.synchronizeWith) {
+ while (!_invocation.synchronizeWith.done) {
+ try {
+ _invocation.synchronizeWith.wait(_invocation.maximumWaitMs);
+ } catch (InterruptedException e) {
+ failure(_invocation, "timed out waiting in
sequence", e);
+ return;
+ }
+ }
+ }
+ }
scheduler.beginTransaction();
try {
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/java/org/apache/ode/test/MessageRouting20Test.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/java/org/apache/ode/test/MessageRouting20Test.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/java/org/apache/ode/test/MessageRouting20Test.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -127,5 +127,8 @@
@Test public void testConcurrentSyncMex() throws Throwable {
go("/bpel/2.0/TestConcurrentSyncMex");
}
-
+
+ @Test public void testIMA() throws Throwable {
+ go("/bpel/2.0/TestIMA");
+ }
}
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/java/org/apache/ode/test/PubSubTest.java
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/java/org/apache/ode/test/PubSubTest.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/java/org/apache/ode/test/PubSubTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -22,14 +22,14 @@
import org.junit.Test;
public class PubSubTest extends BPELTestAbstract {
- @Test public void testPubSubInProc() throws Throwable {
+ @Ignore @Test public void testPubSubInProc() throws Throwable {
go("/bpel/2.0/TestPubSubInProc");
}
@Ignore @Test public void testPubSubOutOfProc() throws Throwable {
go("/bpel/2.0/TestPubSubOutOfProc");
}
-
+
@Override
protected long getWaitBeforeInvokeTimeout() {
return 10000;
Added:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/META-INF/services/org.apache.commons.logging.LogFactory
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/META-INF/services/org.apache.commons.logging.LogFactory
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/META-INF/services/org.apache.commons.logging.LogFactory 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1 @@
+org.apache.commons.logging.impl.Log4JLogger
\ No newline at end of file
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/FaultService/faultService.wsdl
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/FaultService/faultService.wsdl 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/FaultService/faultService.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -1,48 +1,48 @@
-<!--
- ~ Licensed to the Apache Software Foundation (ASF) under one
- ~ or more contributor license agreements. See the NOTICE file
- ~ distributed with this work for additional information
- ~ regarding copyright ownership. The ASF licenses this file
- ~ to you under the Apache License, Version 2.0 (the
- ~ "License"); you may not use this file except in compliance
- ~ with the License. You may obtain a copy of the License at
- ~
- ~
http://www.apache.org/licenses/LICENSE-2.0
- ~
- ~ Unless required by applicable law or agreed to in writing,
- ~ software distributed under the License is distributed on an
- ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- ~ KIND, either express or implied. See the License for the
- ~ specific language governing permissions and limitations
- ~ under the License.
--->
-
-<wsdl:definitions
targetNamespace="http://ode/bpel/unit-test/FaultService.wsdl"
- xmlns="http://ode/bpel/unit-test/FaultService.wsdl"
- xmlns:tns="http://ode/bpel/unit-test/FaultService.wsdl"
-
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
-
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
-
- <wsdl:message name="faultMessage">
- <wsdl:part name="faultName" type="xsd:string"/>
- <wsdl:part name="faultData" type="xsd:string"/>
- <wsdl:part name="faultIndicator1" type="xsd:string"/>
- <wsdl:part name="faultIndicator2" type="xsd:string"/>
- </wsdl:message>
- <wsdl:message name="errorMessage">
- <wsdl:part name="errorID" type="xsd:string"/>
- <wsdl:part name="errorText" type="xsd:string"/>
- </wsdl:message>
-
- <wsdl:portType name="faultMessagePT">
- <wsdl:operation name="throwFault">
- <wsdl:input name="FaultInputMessage"
message="tns:faultMessage"/>
- <wsdl:output name="FaultOutputMessage"
message="tns:faultMessage"/>
- <wsdl:fault name="FaultMessage1"
message="tns:errorMessage"/>
- <wsdl:fault name="FaultMessage2"
message="tns:errorMessage"/>
- <wsdl:fault name="UnknownFault"
message="tns:errorMessage"/>
- </wsdl:operation>
- </wsdl:portType>
-
-</wsdl:definitions>
-
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+-->
+
+<wsdl:definitions
targetNamespace="http://ode/bpel/unit-test/FaultService.wsdl"
+ xmlns="http://ode/bpel/unit-test/FaultService.wsdl"
+ xmlns:tns="http://ode/bpel/unit-test/FaultService.wsdl"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
+
+ <wsdl:message name="faultMessage">
+ <wsdl:part name="faultName" type="xsd:string"/>
+ <wsdl:part name="faultData" type="xsd:string"/>
+ <wsdl:part name="faultIndicator1" type="xsd:string"/>
+ <wsdl:part name="faultIndicator2" type="xsd:string"/>
+ </wsdl:message>
+ <wsdl:message name="errorMessage">
+ <wsdl:part name="errorID" type="xsd:string"/>
+ <wsdl:part name="errorText" type="xsd:string"/>
+ </wsdl:message>
+
+ <wsdl:portType name="faultMessagePT">
+ <wsdl:operation name="throwFault">
+ <wsdl:input name="FaultInputMessage"
message="tns:faultMessage"/>
+ <wsdl:output name="FaultOutputMessage"
message="tns:faultMessage"/>
+ <wsdl:fault name="FaultMessage1"
message="tns:errorMessage"/>
+ <wsdl:fault name="FaultMessage2"
message="tns:errorMessage"/>
+ <wsdl:fault name="UnknownFault"
message="tns:errorMessage"/>
+ </wsdl:operation>
+ </wsdl:portType>
+
+</wsdl:definitions>
+
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/NegativeCorrelationTest/NegativeCorrelationTest.bpel
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/NegativeCorrelationTest/NegativeCorrelationTest.bpel 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/NegativeCorrelationTest/NegativeCorrelationTest.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -27,7 +27,7 @@
targetNamespace="http://ode/bpel/unit-test/NegativeCorrelationTest"
queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
- suppressJoinFailure="yes">
+ suppressJoinFailure="yes">
<import location="NegativeCorrelationTest.wsdl"
namespace="http://ode/bpel/unit-test/NegativeCorrelationTest.wsdl"
@@ -36,180 +36,180 @@
namespace="http://ode/bpel/unit-test/ProbeService.wsdl"
importType="http://schemas.xmlsoap.org/wsdl/"/>
-
+
<!-- This is a negative unit test for the ODE compiler. The compiler should
- throw an exception because the <pick> does not contain a correlation set.
-->
-
- <partnerLinks>
+ throw an exception because the <pick> does not contain a correlation set.
-->
+
+ <partnerLinks>
<partnerLink name="request1"
partnerLinkType="wns:NegativeCorrelationTestRequest"
myRole="NegativeCorrelationTestService"/>
- <partnerLink name="probe" partnerLinkType="wns:probeRequest"
partnerRole="probeService" initializePartnerRole="yes"/>
- </partnerLinks>
-
- <variables>
- <variable name="request"
- messageType="wns:requestMessage"/>
- <variable name="probeInput"
- messageType="prb:probeMessage"/>
- <variable name="reply"
- messageType="wns:replyMessage"/>
- </variables>
-
- <correlationSets>
- <correlationSet name="testCorr1"
properties="wns:testProbeID"/>
- </correlationSets>
-
- <sequence>
- <receive name="receive1" partnerLink="request1"
- portType="wns:NegativeCorrelationTestPT"
- operation="request" variable="request"
+ <partnerLink name="probe" partnerLinkType="wns:probeRequest"
partnerRole="probeService" initializePartnerRole="yes"/>
+ </partnerLinks>
+
+ <variables>
+ <variable name="request"
+ messageType="wns:requestMessage"/>
+ <variable name="probeInput"
+ messageType="prb:probeMessage"/>
+ <variable name="reply"
+ messageType="wns:replyMessage"/>
+ </variables>
+
+ <correlationSets>
+ <correlationSet name="testCorr1"
properties="wns:testProbeID"/>
+ </correlationSets>
+
+ <sequence>
+ <receive name="receive1" partnerLink="request1"
+ portType="wns:NegativeCorrelationTestPT"
+ operation="request" variable="request"
createInstance="yes">
<correlations>
<correlation set="testCorr1" initiate="yes"/>
- </correlations>
- </receive>
-
- <assign name="assign1">
- <copy>
- <from variable="request" property="wns:testProbeID"/>
- <to variable="probeInput" part="probeName"/>
- </copy>
- <copy>
- <from variable="request" part="requestText"/>
- <to variable="probeInput" part="probeData"/>
- </copy>
- </assign>
-
-
- <assign>
+ </correlations>
+ </receive>
+
+ <assign name="assign1">
+ <copy>
+ <from variable="request" property="wns:testProbeID"/>
+ <to variable="probeInput" part="probeName"/>
+ </copy>
+ <copy>
+ <from variable="request" part="requestText"/>
+ <to variable="probeInput" part="probeData"/>
+ </copy>
+ </assign>
+
+
+ <assign>
<copy>
<from>
<literal><![CDATA[block for next message]]></literal>
- </from>
- <to variable="probeInput" part="probeName"/>
- </copy>
- </assign>
-
- <invoke name="probe" partnerLink="probe"
- portType="prb:probeMessagePT"
- operation="probe"
- inputVariable="probeInput"
- outputVariable="probeInput">
- </invoke>
-
- <pick name="testPick">
- <onMessage partnerLink="request1"
- portType="wns:NegativeCorrelationTestPT" operation="continue1"
variable="request">
+ </from>
+ <to variable="probeInput" part="probeName"/>
+ </copy>
+ </assign>
+
+ <invoke name="probe" partnerLink="probe"
+ portType="prb:probeMessagePT"
+ operation="probe"
+ inputVariable="probeInput"
+ outputVariable="probeInput">
+ </invoke>
+
+ <pick name="testPick">
+ <onMessage partnerLink="request1"
+ portType="wns:NegativeCorrelationTestPT" operation="continue1"
variable="request">
<!--
<correlations>
<correlation set="testCorr1"/>
</correlations>
-->
- <sequence>
- <assign>
+ <sequence>
+ <assign>
<copy>
<from>
<literal><![CDATA[pick branch one invoked]]></literal>
- </from>
- <to variable="probeInput" part="probeName"/>
- </copy>
- </assign>
-
- <invoke name="probe" partnerLink="probe"
- portType="prb:probeMessagePT"
- operation="probe"
- inputVariable="probeInput"
- outputVariable="probeInput">
- </invoke>
-
- <assign>
+ </from>
+ <to variable="probeInput" part="probeName"/>
+ </copy>
+ </assign>
+
+ <invoke name="probe" partnerLink="probe"
+ portType="prb:probeMessagePT"
+ operation="probe"
+ inputVariable="probeInput"
+ outputVariable="probeInput">
+ </invoke>
+
+ <assign>
<copy>
<from>
<literal><![CDATA[process complete]]></literal>
- </from>
- <to variable="probeInput" part="probeName"/>
- </copy>
- </assign>
-
- <invoke name="probe" partnerLink="probe"
- portType="prb:probeMessagePT"
- operation="probe"
- inputVariable="probeInput"
- outputVariable="probeInput">
- </invoke>
-
- <assign name="assign2">
- <copy>
- <from variable="probeInput" part="probeName"/>
- <to variable="reply" part="replyID"/>
- </copy>
- <copy>
- <from variable="probeInput" part="probeData"/>
- <to variable="reply" part="replyText"/>
- </copy>
- </assign>
-
- <reply name="reply" partnerLink="request1"
portType="wns:NegativeCorrelationTestPT"
- operation="continue1" variable="reply">
- </reply>
-
- </sequence>
- </onMessage>
- <onMessage partnerLink="request1"
- portType="wns:NegativeCorrelationTestPT" operation="continue2"
variable="request">
+ </from>
+ <to variable="probeInput" part="probeName"/>
+ </copy>
+ </assign>
+
+ <invoke name="probe" partnerLink="probe"
+ portType="prb:probeMessagePT"
+ operation="probe"
+ inputVariable="probeInput"
+ outputVariable="probeInput">
+ </invoke>
+
+ <assign name="assign2">
+ <copy>
+ <from variable="probeInput" part="probeName"/>
+ <to variable="reply" part="replyID"/>
+ </copy>
+ <copy>
+ <from variable="probeInput" part="probeData"/>
+ <to variable="reply" part="replyText"/>
+ </copy>
+ </assign>
+
+ <reply name="reply" partnerLink="request1"
portType="wns:NegativeCorrelationTestPT"
+ operation="continue1" variable="reply">
+ </reply>
+
+ </sequence>
+ </onMessage>
+ <onMessage partnerLink="request1"
+ portType="wns:NegativeCorrelationTestPT" operation="continue2"
variable="request">
<!--
<correlations>
<correlation set="testCorr1"/>
</correlations>
-->
- <sequence>
- <assign>
+ <sequence>
+ <assign>
<copy>
<from>
<literal><![CDATA[pick branch two invoked]]></literal>
- </from>
- <to variable="probeInput" part="probeName"/>
- </copy>
- </assign>
-
- <invoke name="probe" partnerLink="probe"
- portType="prb:probeMessagePT"
- operation="probe"
- inputVariable="probeInput"
- outputVariable="probeInput">
- </invoke>
-
- <assign>
+ </from>
+ <to variable="probeInput" part="probeName"/>
+ </copy>
+ </assign>
+
+ <invoke name="probe" partnerLink="probe"
+ portType="prb:probeMessagePT"
+ operation="probe"
+ inputVariable="probeInput"
+ outputVariable="probeInput">
+ </invoke>
+
+ <assign>
<copy>
<from>
<literal><![CDATA[process complete]]></literal>
- </from>
- <to variable="probeInput" part="probeName"/>
- </copy>
- </assign>
-
- <invoke name="probe" partnerLink="probe"
- portType="prb:probeMessagePT"
- operation="probe"
- inputVariable="probeInput"
- outputVariable="probeInput">
- </invoke>
- <assign name="assign2">
- <copy>
- <from variable="probeInput" part="probeName"/>
- <to variable="reply" part="replyID"/>
- </copy>
- <copy>
- <from variable="probeInput" part="probeData"/>
- <to variable="reply" part="replyText"/>
- </copy>
- </assign>
-
- <reply name="reply" partnerLink="request1"
portType="wns:NegativeCorrelationTestPT"
- operation="continue2" variable="reply">
- </reply>
-
- </sequence>
- </onMessage>
- </pick>
- </sequence>
-</process>
+ </from>
+ <to variable="probeInput" part="probeName"/>
+ </copy>
+ </assign>
+
+ <invoke name="probe" partnerLink="probe"
+ portType="prb:probeMessagePT"
+ operation="probe"
+ inputVariable="probeInput"
+ outputVariable="probeInput">
+ </invoke>
+ <assign name="assign2">
+ <copy>
+ <from variable="probeInput" part="probeName"/>
+ <to variable="reply" part="replyID"/>
+ </copy>
+ <copy>
+ <from variable="probeInput" part="probeData"/>
+ <to variable="reply" part="replyText"/>
+ </copy>
+ </assign>
+
+ <reply name="reply" partnerLink="request1"
portType="wns:NegativeCorrelationTestPT"
+ operation="continue2" variable="reply">
+ </reply>
+
+ </sequence>
+ </onMessage>
+ </pick>
+ </sequence>
+</process>
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/NegativeCorrelationTest/NegativeCorrelationTest.wsdl
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/NegativeCorrelationTest/NegativeCorrelationTest.wsdl 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/NegativeCorrelationTest/NegativeCorrelationTest.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -1,81 +1,81 @@
-<!--
- ~ Licensed to the Apache Software Foundation (ASF) under one
- ~ or more contributor license agreements. See the NOTICE file
- ~ distributed with this work for additional information
- ~ regarding copyright ownership. The ASF licenses this file
- ~ to you under the Apache License, Version 2.0 (the
- ~ "License"); you may not use this file except in compliance
- ~ with the License. You may obtain a copy of the License at
- ~
- ~
http://www.apache.org/licenses/LICENSE-2.0
- ~
- ~ Unless required by applicable law or agreed to in writing,
- ~ software distributed under the License is distributed on an
- ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- ~ KIND, either express or implied. See the License for the
- ~ specific language governing permissions and limitations
- ~ under the License.
--->
-
-<wsdl:definitions
- targetNamespace="http://ode/bpel/unit-test/NegativeCorrelationTest.wsdl"
- xmlns:tns="http://ode/bpel/unit-test/NegativeCorrelationTest.wsdl"
- xmlns="http://ode/bpel/unit-test/NegativeCorrelationTest.wsdl"
- xmlns:prb="http://ode/bpel/unit-test/ProbeService.wsdl"
-
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
-
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
-
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
-
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
-
-
- <wsdl:message name="requestMessage">
- <wsdl:part name="requestID" type="xsd:string"/>
- <wsdl:part name="requestText" type="xsd:string"/>
- </wsdl:message>
-
- <wsdl:message name="replyMessage">
- <wsdl:part name="replyID" type="xsd:string"/>
- <wsdl:part name="replyText" type="xsd:string"/>
- </wsdl:message>
-
-
- <wsdl:portType name="NegativeCorrelationTestPT">
- <wsdl:operation name="request">
- <wsdl:input message="requestMessage"/>
- </wsdl:operation>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+-->
+
+<wsdl:definitions
+ targetNamespace="http://ode/bpel/unit-test/NegativeCorrelationTest.wsdl"
+ xmlns:tns="http://ode/bpel/unit-test/NegativeCorrelationTest.wsdl"
+ xmlns="http://ode/bpel/unit-test/NegativeCorrelationTest.wsdl"
+ xmlns:prb="http://ode/bpel/unit-test/ProbeService.wsdl"
+
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
+
+
+ <wsdl:message name="requestMessage">
+ <wsdl:part name="requestID" type="xsd:string"/>
+ <wsdl:part name="requestText" type="xsd:string"/>
+ </wsdl:message>
+
+ <wsdl:message name="replyMessage">
+ <wsdl:part name="replyID" type="xsd:string"/>
+ <wsdl:part name="replyText" type="xsd:string"/>
+ </wsdl:message>
+
+
+ <wsdl:portType name="NegativeCorrelationTestPT">
+ <wsdl:operation name="request">
+ <wsdl:input message="requestMessage"/>
+ </wsdl:operation>
<wsdl:operation name="continue1">
- <wsdl:input message="requestMessage"/>
- <wsdl:output message="replyMessage"/>
- </wsdl:operation>
- <wsdl:operation name="continue2">
- <wsdl:input message="requestMessage"/>
- <wsdl:output message="replyMessage"/>
- </wsdl:operation>
- </wsdl:portType>
-
-
- <wsdl:binding name="NegativeCorrelationTestBinding"
type="tns:NegativeCorrelationTestPT">
- <wsdl:operation name="request">
- </wsdl:operation>
- <wsdl:operation name="continue1">
- </wsdl:operation>
- <wsdl:operation name="continue2">
- </wsdl:operation>
- </wsdl:binding>
- <wsdl:service name="NegativeCorrelationTestService">
- <wsdl:port name="NegativeCorrelationTestPort"
binding="tns:NegativeCorrelationTestBinding">
- </wsdl:port>
- </wsdl:service>
-
- <plnk:partnerLinkType name="NegativeCorrelationTestRequest">
- <plnk:role name="NegativeCorrelationTestService"
portType="NegativeCorrelationTestPT"/>
- </plnk:partnerLinkType>
-
- <plnk:partnerLinkType name="probeRequest">
- <plnk:role name="probeService"
portType="prb:probeMessagePT"/>
- </plnk:partnerLinkType>
-
- <bpws:property name="testProbeID" type="xsd:string"/>
- <bpws:propertyAlias propertyName="tns:testProbeID"
messageType="tns:requestMessage" part="requestID"/>
-
-</wsdl:definitions>
+ <wsdl:input message="requestMessage"/>
+ <wsdl:output message="replyMessage"/>
+ </wsdl:operation>
+ <wsdl:operation name="continue2">
+ <wsdl:input message="requestMessage"/>
+ <wsdl:output message="replyMessage"/>
+ </wsdl:operation>
+ </wsdl:portType>
+
+
+ <wsdl:binding name="NegativeCorrelationTestBinding"
type="tns:NegativeCorrelationTestPT">
+ <wsdl:operation name="request">
+ </wsdl:operation>
+ <wsdl:operation name="continue1">
+ </wsdl:operation>
+ <wsdl:operation name="continue2">
+ </wsdl:operation>
+ </wsdl:binding>
+ <wsdl:service name="NegativeCorrelationTestService">
+ <wsdl:port name="NegativeCorrelationTestPort"
binding="tns:NegativeCorrelationTestBinding">
+ </wsdl:port>
+ </wsdl:service>
+
+ <plnk:partnerLinkType name="NegativeCorrelationTestRequest">
+ <plnk:role name="NegativeCorrelationTestService"
portType="NegativeCorrelationTestPT"/>
+ </plnk:partnerLinkType>
+
+ <plnk:partnerLinkType name="probeRequest">
+ <plnk:role name="probeService"
portType="prb:probeMessagePT"/>
+ </plnk:partnerLinkType>
+
+ <bpws:property name="testProbeID" type="xsd:string"/>
+ <bpws:propertyAlias propertyName="tns:testProbeID"
messageType="tns:requestMessage" part="requestID"/>
+
+</wsdl:definitions>
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/NegativeInitializationTest/NegativeInitializationTest.bpel
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/NegativeInitializationTest/NegativeInitializationTest.bpel 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/NegativeInitializationTest/NegativeInitializationTest.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -27,10 +27,10 @@
targetNamespace="http://ode/bpel/unit-test/NegativeInitializationTest"
queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
- suppressJoinFailure="yes">
-
-<!-- test onMessage with static correlation key -->
+ suppressJoinFailure="yes">
+<!-- test onMessage with static correlation key -->
+
<import location="NegativeInitializationTest.wsdl"
namespace="http://ode/bpel/unit-test/NegativeInitializationTest.wsdl"
importType="http://schemas.xmlsoap.org/wsdl/" />
@@ -38,90 +38,90 @@
namespace="http://ode/bpel/unit-test/ProbeService.wsdl"
importType="http://schemas.xmlsoap.org/wsdl/"/>
-
- <partnerLinks>
- <partnerLink name="request1"
partnerLinkType="wns:NegativeInitializationTestRequest"
myRole="NegativeInitializationTestService"/>
- <partnerLink name="probe" partnerLinkType="wns:probeRequest"
partnerRole="probeService" initializePartnerRole="yes"/>
- </partnerLinks>
-
- <variables>
- <variable name="request"
- messageType="wns:requestMessage"/>
- <variable name="probeInput"
- messageType="prb:probeMessage"/>
- <variable name="reply"
- messageType="wns:replyMessage"/>
- </variables>
-
- <correlationSets>
- <correlationSet name="testCorr1"
properties="wns:testProbeID"/>
- </correlationSets>
-
+
+ <partnerLinks>
+ <partnerLink name="request1"
partnerLinkType="wns:NegativeInitializationTestRequest"
myRole="NegativeInitializationTestService"/>
+ <partnerLink name="probe" partnerLinkType="wns:probeRequest"
partnerRole="probeService" initializePartnerRole="yes"/>
+ </partnerLinks>
+
+ <variables>
+ <variable name="request"
+ messageType="wns:requestMessage"/>
+ <variable name="probeInput"
+ messageType="prb:probeMessage"/>
+ <variable name="reply"
+ messageType="wns:replyMessage"/>
+ </variables>
+
+ <correlationSets>
+ <correlationSet name="testCorr1"
properties="wns:testProbeID"/>
+ </correlationSets>
+
<sequence>
- <scope name="scopeOne">
- <eventHandlers>
-
- <onEvent partnerLink="request1"
messageType="wns:requestMessage"
+ <scope name="scopeOne">
+ <eventHandlers>
+
+ <onEvent partnerLink="request1"
messageType="wns:requestMessage"
portType="wns:NegativeInitializationTestPT" operation="event1"
variable="request">
<correlations>
<correlation set="testCorr1"/>
</correlations>
-
+
<scope>
- <sequence>
- <assign>
+ <sequence>
+ <assign>
<copy>
<from>
<literal><![CDATA[TestStaticOnMessage3PT]]></literal>
- </from>
- <to variable="probeInput" part="probeName"/>
- </copy>
- </assign>
-
- <invoke name="probe" partnerLink="probe"
- portType="prb:probeMessagePT"
- operation="probe"
- inputVariable="probeInput"
- outputVariable="probeInput">
- </invoke>
+ </from>
+ <to variable="probeInput" part="probeName"/>
+ </copy>
+ </assign>
+
+ <invoke name="probe" partnerLink="probe"
+ portType="prb:probeMessagePT"
+ operation="probe"
+ inputVariable="probeInput"
+ outputVariable="probeInput">
+ </invoke>
</sequence>
- </scope>
- </onEvent>
- <onEvent partnerLink="request1"
messageType="wns:requestMessage"
- portType="wns:NegativeInitializationTestPT" operation="event2"
variable="request">
+ </scope>
+ </onEvent>
+ <onEvent partnerLink="request1"
messageType="wns:requestMessage"
+ portType="wns:NegativeInitializationTestPT" operation="event2"
variable="request">
<correlations>
<correlation set="testCorr1"/>
</correlations>
<scope>
- <sequence>
- <assign>
+ <sequence>
+ <assign>
<copy>
<from>
<literal><![CDATA[received event on
TestStaticOnMessage4PT]]></literal>
- </from>
- <to variable="probeInput" part="probeName"/>
- </copy>
- </assign>
-
- <invoke name="probe" partnerLink="probe"
- portType="prb:probeMessagePT"
- operation="probe"
- inputVariable="probeInput"
- outputVariable="probeInput">
- </invoke>
+ </from>
+ <to variable="probeInput" part="probeName"/>
+ </copy>
+ </assign>
+
+ <invoke name="probe" partnerLink="probe"
+ portType="prb:probeMessagePT"
+ operation="probe"
+ inputVariable="probeInput"
+ outputVariable="probeInput">
+ </invoke>
</sequence>
- </scope>
- </onEvent>
-
-
- </eventHandlers>
-
- <sequence>
-
+ </scope>
+ </onEvent>
+
+
+ </eventHandlers>
+
+ <sequence>
+
<receive name="receive1" partnerLink="request1"
portType="wns:NegativeInitializationTestPT"
operation="request" variable="request"
@@ -129,104 +129,104 @@
<correlations>
<correlation set="testCorr1" initiate="yes"/>
</correlations>
- </receive>
-
- <!-- Copy input variables to internal accumulators -->
-
- <assign name="assign1">
- <copy>
- <from variable="request" property="wns:testProbeID"/>
- <to variable="probeInput" part="probeName"/>
- </copy>
- <copy>
- <from variable="request"
property="wns:testProbeData"/>
- <to variable="probeInput" part="probeData"/>
- </copy>
- </assign>
-
+ </receive>
+
+ <!-- Copy input variables to internal accumulators -->
+
+ <assign name="assign1">
+ <copy>
+ <from variable="request" property="wns:testProbeID"/>
+ <to variable="probeInput" part="probeName"/>
+ </copy>
+ <copy>
+ <from variable="request"
property="wns:testProbeData"/>
+ <to variable="probeInput" part="probeData"/>
+ </copy>
+ </assign>
+
- <assign>
+ <assign>
<copy>
<from>
<literal><![CDATA[block for next message]]></literal>
- </from>
- <to variable="probeInput" part="probeName"/>
- </copy>
- </assign>
-
- <invoke name="probe" partnerLink="probe"
- portType="prb:probeMessagePT"
- operation="probe"
- inputVariable="probeInput"
- outputVariable="probeInput">
+ </from>
+ <to variable="probeInput" part="probeName"/>
+ </copy>
+ </assign>
+
+ <invoke name="probe" partnerLink="probe"
+ portType="prb:probeMessagePT"
+ operation="probe"
+ inputVariable="probeInput"
+ outputVariable="probeInput">
</invoke>
<!-- block the process here while test messages are sent to the eventHandlers
-->
-
- <receive name="receive2" partnerLink="request1"
- portType="wns:NegativeInitializationTestPT"
- operation="continue1" variable="request">
- <correlations>
- <correlation set="testCorr1"/>
- </correlations>
- </receive>
-
- </sequence>
- </scope>
-
- <assign>
+
+ <receive name="receive2" partnerLink="request1"
+ portType="wns:NegativeInitializationTestPT"
+ operation="continue1" variable="request">
+ <correlations>
+ <correlation set="testCorr1"/>
+ </correlations>
+ </receive>
+
+ </sequence>
+ </scope>
+
+ <assign>
<copy>
<from>
<literal><![CDATA[block for final message]]></literal>
- </from>
- <to variable="probeInput" part="probeName"/>
- </copy>
- </assign>
-
- <invoke name="probe" partnerLink="probe"
- portType="prb:probeMessagePT"
- operation="probe"
- inputVariable="probeInput"
- outputVariable="probeInput">
- </invoke>
-
- <receive name="receive3" partnerLink="request1"
- portType="wns:NegativeInitializationTestPT"
- operation="continue2" variable="request">
- <correlations>
- <correlation set="testCorr1"/>
- </correlations>
- </receive>
-
- <assign>
+ </from>
+ <to variable="probeInput" part="probeName"/>
+ </copy>
+ </assign>
+
+ <invoke name="probe" partnerLink="probe"
+ portType="prb:probeMessagePT"
+ operation="probe"
+ inputVariable="probeInput"
+ outputVariable="probeInput">
+ </invoke>
+
+ <receive name="receive3" partnerLink="request1"
+ portType="wns:NegativeInitializationTestPT"
+ operation="continue2" variable="request">
+ <correlations>
+ <correlation set="testCorr1"/>
+ </correlations>
+ </receive>
+
+ <assign>
<copy>
<from>
<literal><![CDATA[process complete]]></literal>
- </from>
- <to variable="probeInput" part="probeName"/>
- </copy>
- </assign>
-
- <invoke name="probe" partnerLink="probe"
- portType="prb:probeMessagePT"
- operation="probe"
- inputVariable="probeInput"
- outputVariable="probeInput">
- </invoke>
- <assign name="assign2">
- <copy>
- <from variable="probeInput" part="probeName"/>
- <to variable="reply" part="replyID"/>
- </copy>
- <copy>
- <from variable="probeInput" part="probeData"/>
- <to variable="reply" part="replyText"/>
- </copy>
- </assign>
-
- <reply name="reply" partnerLink="request1"
portType="wns:NegativeInitializationTestPT"
- operation="continue2" variable="reply">
- </reply>
-
- </sequence>
-</process>
+ </from>
+ <to variable="probeInput" part="probeName"/>
+ </copy>
+ </assign>
+
+ <invoke name="probe" partnerLink="probe"
+ portType="prb:probeMessagePT"
+ operation="probe"
+ inputVariable="probeInput"
+ outputVariable="probeInput">
+ </invoke>
+ <assign name="assign2">
+ <copy>
+ <from variable="probeInput" part="probeName"/>
+ <to variable="reply" part="replyID"/>
+ </copy>
+ <copy>
+ <from variable="probeInput" part="probeData"/>
+ <to variable="reply" part="replyText"/>
+ </copy>
+ </assign>
+
+ <reply name="reply" partnerLink="request1"
portType="wns:NegativeInitializationTestPT"
+ operation="continue2" variable="reply">
+ </reply>
+
+ </sequence>
+</process>
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/NegativeInitializationTest/NegativeInitializationTest.wsdl
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/NegativeInitializationTest/NegativeInitializationTest.wsdl 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/NegativeInitializationTest/NegativeInitializationTest.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -1,116 +1,116 @@
-<!--
- ~ Licensed to the Apache Software Foundation (ASF) under one
- ~ or more contributor license agreements. See the NOTICE file
- ~ distributed with this work for additional information
- ~ regarding copyright ownership. The ASF licenses this file
- ~ to you under the Apache License, Version 2.0 (the
- ~ "License"); you may not use this file except in compliance
- ~ with the License. You may obtain a copy of the License at
- ~
- ~
http://www.apache.org/licenses/LICENSE-2.0
- ~
- ~ Unless required by applicable law or agreed to in writing,
- ~ software distributed under the License is distributed on an
- ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- ~ KIND, either express or implied. See the License for the
- ~ specific language governing permissions and limitations
- ~ under the License.
--->
-
-<wsdl:definitions
- targetNamespace="http://ode/bpel/unit-test/NegativeInitializationTest.wsdl"
- xmlns:tns="http://ode/bpel/unit-test/NegativeInitializationTest.wsdl"
-
xmlns:typens="http://ode/bpel/unit-test/NegativeInitializationTest.wsdl.types"
- xmlns="http://ode/bpel/unit-test/NegativeInitializationTest.wsdl"
- xmlns:prb="http://ode/bpel/unit-test/ProbeService.wsdl"
-
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
-
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
-
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
-
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
-
-
- <wsdl:types>
- <xsd:schema
-
targetNamespace="http://ode/bpel/unit-test/NegativeInitializationTest.wsdl.types"
-
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
-
- <xsd:complexType name="testMessage">
- <xsd:sequence>
- <xsd:element name="requestID" type="xsd:string"/>
- <xsd:element name="requestText" type="xsd:string"/>
- </xsd:sequence>
- </xsd:complexType>
-
- </xsd:schema>
- </wsdl:types>
-
- <wsdl:message name="requestMessage">
- <wsdl:part name="requestMessageData"
type="typens:testMessage"/>
- </wsdl:message>
-
- <wsdl:message name="replyMessage">
- <wsdl:part name="replyID" type="xsd:string"/>
- <wsdl:part name="replyText" type="xsd:string"/>
- </wsdl:message>
-
-
- <wsdl:portType name="NegativeInitializationTestPT">
- <wsdl:operation name="request">
- <wsdl:input message="requestMessage"/>
- </wsdl:operation>
- <wsdl:operation name="event1">
- <wsdl:input message="requestMessage"/>
- </wsdl:operation>
- <wsdl:operation name="event2">
- <wsdl:input message="requestMessage"/>
- </wsdl:operation>
- <wsdl:operation name="continue1">
- <wsdl:input message="requestMessage"/>
- </wsdl:operation>
- <wsdl:operation name="continue2">
- <wsdl:input message="requestMessage"/>
- <wsdl:output message="replyMessage"/>
- </wsdl:operation>
- </wsdl:portType>
-
- <wsdl:binding name="NegativeInitializationTestBinding"
type="tns:NegativeInitializationTestPT">
- <wsdl:operation name="request">
- </wsdl:operation>
- <wsdl:operation name="event1">
- </wsdl:operation>
- <wsdl:operation name="event2">
- </wsdl:operation>
- <wsdl:operation name="continue1">
- </wsdl:operation>
- <wsdl:operation name="continue2">
- </wsdl:operation>
- </wsdl:binding>
- <wsdl:service name="NegativeInitializationTestService">
- <wsdl:port name="NegativeInitializationTestPort"
binding="tns:NegativeInitializationTestBinding">
- </wsdl:port>
- </wsdl:service>
-
- <bpws:property name="testProbeID" type="xsd:string"/>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+-->
+
+<wsdl:definitions
+ targetNamespace="http://ode/bpel/unit-test/NegativeInitializationTest.wsdl"
+ xmlns:tns="http://ode/bpel/unit-test/NegativeInitializationTest.wsdl"
+
xmlns:typens="http://ode/bpel/unit-test/NegativeInitializationTest.wsdl.types"
+ xmlns="http://ode/bpel/unit-test/NegativeInitializationTest.wsdl"
+ xmlns:prb="http://ode/bpel/unit-test/ProbeService.wsdl"
+
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
+
+
+ <wsdl:types>
+ <xsd:schema
+
targetNamespace="http://ode/bpel/unit-test/NegativeInitializationTest.wsdl.types"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
+
+ <xsd:complexType name="testMessage">
+ <xsd:sequence>
+ <xsd:element name="requestID" type="xsd:string"/>
+ <xsd:element name="requestText" type="xsd:string"/>
+ </xsd:sequence>
+ </xsd:complexType>
+
+ </xsd:schema>
+ </wsdl:types>
+
+ <wsdl:message name="requestMessage">
+ <wsdl:part name="requestMessageData"
type="typens:testMessage"/>
+ </wsdl:message>
+
+ <wsdl:message name="replyMessage">
+ <wsdl:part name="replyID" type="xsd:string"/>
+ <wsdl:part name="replyText" type="xsd:string"/>
+ </wsdl:message>
+
+
+ <wsdl:portType name="NegativeInitializationTestPT">
+ <wsdl:operation name="request">
+ <wsdl:input message="requestMessage"/>
+ </wsdl:operation>
+ <wsdl:operation name="event1">
+ <wsdl:input message="requestMessage"/>
+ </wsdl:operation>
+ <wsdl:operation name="event2">
+ <wsdl:input message="requestMessage"/>
+ </wsdl:operation>
+ <wsdl:operation name="continue1">
+ <wsdl:input message="requestMessage"/>
+ </wsdl:operation>
+ <wsdl:operation name="continue2">
+ <wsdl:input message="requestMessage"/>
+ <wsdl:output message="replyMessage"/>
+ </wsdl:operation>
+ </wsdl:portType>
+
+ <wsdl:binding name="NegativeInitializationTestBinding"
type="tns:NegativeInitializationTestPT">
+ <wsdl:operation name="request">
+ </wsdl:operation>
+ <wsdl:operation name="event1">
+ </wsdl:operation>
+ <wsdl:operation name="event2">
+ </wsdl:operation>
+ <wsdl:operation name="continue1">
+ </wsdl:operation>
+ <wsdl:operation name="continue2">
+ </wsdl:operation>
+ </wsdl:binding>
+ <wsdl:service name="NegativeInitializationTestService">
+ <wsdl:port name="NegativeInitializationTestPort"
binding="tns:NegativeInitializationTestBinding">
+ </wsdl:port>
+ </wsdl:service>
+
+ <bpws:property name="testProbeID" type="xsd:string"/>
<bpws:propertyAlias propertyName="tns:testProbeID"
messageType="tns:requestMessage" part="requestMessageData">
- <bpws:query
queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
- testMessage/requestID
- </bpws:query>
- </bpws:propertyAlias>
-
- <bpws:property name="testProbeData" type="xsd:string"/>
+ <bpws:query
queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ testMessage/requestID
+ </bpws:query>
+ </bpws:propertyAlias>
+
+ <bpws:property name="testProbeData" type="xsd:string"/>
<bpws:propertyAlias propertyName="tns:testProbeData"
messageType="tns:requestMessage" part="requestMessageData">
- <bpws:query
queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
- testMessage/requestText
+ <bpws:query
queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ testMessage/requestText
</bpws:query>
- </bpws:propertyAlias>
-
-
- <plnk:partnerLinkType name="NegativeInitializationTestRequest">
- <plnk:role name="NegativeInitializationTestService"
portType="NegativeInitializationTestPT"/>
- </plnk:partnerLinkType>
-
- <plnk:partnerLinkType name="probeRequest">
- <plnk:role name="probeService"
portType="prb:probeMessagePT"/>
- </plnk:partnerLinkType>
-
-</wsdl:definitions>
+ </bpws:propertyAlias>
+
+
+ <plnk:partnerLinkType name="NegativeInitializationTestRequest">
+ <plnk:role name="NegativeInitializationTestService"
portType="NegativeInitializationTestPT"/>
+ </plnk:partnerLinkType>
+
+ <plnk:partnerLinkType name="probeRequest">
+ <plnk:role name="probeService"
portType="prb:probeMessagePT"/>
+ </plnk:partnerLinkType>
+
+</wsdl:definitions>
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/NegativeTargetNSTest1/NegativeTargetNSTest1.bpel
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/NegativeTargetNSTest1/NegativeTargetNSTest1.bpel 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/NegativeTargetNSTest1/NegativeTargetNSTest1.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -28,35 +28,35 @@
queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
suppressJoinFailure="yes">
-
+
<import location="NegativeTargetNSTest1.wsdl"
namespace="http://ode/bpel/unit-test/NegativeTargetNSTest1.wsdl"
importType="http://schemas.xmlsoap.org/wsdl/" />
- <partnerLinks>
- <partnerLink name="request"
partnerLinkType="wns:NegativeTargetNSTest1Request"
myRole="NegativeTargetNSTest1Service"/>
- </partnerLinks>
- <variables>
- <variable name="request" messageType="wns:requestMessage"/>
- <variable name="reply" messageType="wns:replyMessage"/>
- </variables>
-
- <sequence>
- <receive name="receive1" partnerLink="request"
portType="wns:NegativeTargetNSTest1PT" operation="request"
variable="request" createInstance="yes"/>
- <!-- Copy input variables to internal accumulators -->
- <assign name="assign1">
- <copy>
- <from variable="request" part="requestID"/>
- <to variable="reply" part="replyID"/>
- </copy>
- <copy>
- <from variable="request" part="requestText"/>
- <to variable="reply" part="replyText"/>
- </copy>
- </assign>
-
- <reply name="reply" partnerLink="request"
portType="wns:NegativeTargetNSTest1PT" operation="request"
variable="reply"/>
- </sequence>
-</process>
+ <partnerLinks>
+ <partnerLink name="request"
partnerLinkType="wns:NegativeTargetNSTest1Request"
myRole="NegativeTargetNSTest1Service"/>
+ </partnerLinks>
+ <variables>
+ <variable name="request" messageType="wns:requestMessage"/>
+ <variable name="reply" messageType="wns:replyMessage"/>
+ </variables>
+
+ <sequence>
+ <receive name="receive1" partnerLink="request"
portType="wns:NegativeTargetNSTest1PT" operation="request"
variable="request" createInstance="yes"/>
+ <!-- Copy input variables to internal accumulators -->
+ <assign name="assign1">
+ <copy>
+ <from variable="request" part="requestID"/>
+ <to variable="reply" part="replyID"/>
+ </copy>
+ <copy>
+ <from variable="request" part="requestText"/>
+ <to variable="reply" part="replyText"/>
+ </copy>
+ </assign>
+
+ <reply name="reply" partnerLink="request"
portType="wns:NegativeTargetNSTest1PT" operation="request"
variable="reply"/>
+ </sequence>
+</process>
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/NegativeTargetNSTest1/NegativeTargetNSTest1.wsdl
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/NegativeTargetNSTest1/NegativeTargetNSTest1.wsdl 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/NegativeTargetNSTest1/NegativeTargetNSTest1.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -1,55 +1,55 @@
-<!--
- ~ Licensed to the Apache Software Foundation (ASF) under one
- ~ or more contributor license agreements. See the NOTICE file
- ~ distributed with this work for additional information
- ~ regarding copyright ownership. The ASF licenses this file
- ~ to you under the Apache License, Version 2.0 (the
- ~ "License"); you may not use this file except in compliance
- ~ with the License. You may obtain a copy of the License at
- ~
- ~
http://www.apache.org/licenses/LICENSE-2.0
- ~
- ~ Unless required by applicable law or agreed to in writing,
- ~ software distributed under the License is distributed on an
- ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- ~ KIND, either express or implied. See the License for the
- ~ specific language governing permissions and limitations
- ~ under the License.
--->
-
-<wsdl:definitions
targetNamespace="http://ode/bpel/unit-test/NegativeTargetNSTest.wsdl"
- xmlns:tns="http://ode/bpel/unit-test/NegativeTargetNSTest1.wsdl"
- xmlns="http://ode/bpel/unit-test/NegativeTargetNSTest1.wsdl"
-
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
-
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
-
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
-
- <wsdl:message name="requestMessage">
- <wsdl:part name="requestID" type="xsd:string"/>
- <wsdl:part name="requestText" type="xsd:string"/>
- </wsdl:message>
- <wsdl:message name="replyMessage">
- <wsdl:part name="replyID" type="xsd:string"/>
- <wsdl:part name="replyText" type="xsd:string"/>
- </wsdl:message>
-
- <wsdl:portType name="NegativeTargetNSTest1PT">
- <wsdl:operation name="request">
- <wsdl:input message="requestMessage"/>
- <wsdl:output message="replyMessage"/>
- </wsdl:operation>
- </wsdl:portType>
- <wsdl:binding name="NegativeTargetNSTest1Binding"
type="tns:NegativeTargetNSTest1PT">
- <wsdl:operation name="request">
- </wsdl:operation>
- </wsdl:binding>
- <wsdl:service name="NegativeTargetNSTest1Service">
- <wsdl:port name="NegativeTargetNSTest1Port"
binding="tns:NegativeTargetNSTest1Binding">
- </wsdl:port>
- </wsdl:service>
-
- <plnk:partnerLinkType name="NegativeTargetNSTest1Request">
- <plnk:role name="NegativeTargetNSTest1Service"
portType="NegativeTargetNSTest1PT"/>
- </plnk:partnerLinkType>
-
-</wsdl:definitions>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+-->
+
+<wsdl:definitions
targetNamespace="http://ode/bpel/unit-test/NegativeTargetNSTest.wsdl"
+ xmlns:tns="http://ode/bpel/unit-test/NegativeTargetNSTest1.wsdl"
+ xmlns="http://ode/bpel/unit-test/NegativeTargetNSTest1.wsdl"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
+
+ <wsdl:message name="requestMessage">
+ <wsdl:part name="requestID" type="xsd:string"/>
+ <wsdl:part name="requestText" type="xsd:string"/>
+ </wsdl:message>
+ <wsdl:message name="replyMessage">
+ <wsdl:part name="replyID" type="xsd:string"/>
+ <wsdl:part name="replyText" type="xsd:string"/>
+ </wsdl:message>
+
+ <wsdl:portType name="NegativeTargetNSTest1PT">
+ <wsdl:operation name="request">
+ <wsdl:input message="requestMessage"/>
+ <wsdl:output message="replyMessage"/>
+ </wsdl:operation>
+ </wsdl:portType>
+ <wsdl:binding name="NegativeTargetNSTest1Binding"
type="tns:NegativeTargetNSTest1PT">
+ <wsdl:operation name="request">
+ </wsdl:operation>
+ </wsdl:binding>
+ <wsdl:service name="NegativeTargetNSTest1Service">
+ <wsdl:port name="NegativeTargetNSTest1Port"
binding="tns:NegativeTargetNSTest1Binding">
+ </wsdl:port>
+ </wsdl:service>
+
+ <plnk:partnerLinkType name="NegativeTargetNSTest1Request">
+ <plnk:role name="NegativeTargetNSTest1Service"
portType="NegativeTargetNSTest1PT"/>
+ </plnk:partnerLinkType>
+
+</wsdl:definitions>
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/ProbeService/probeService.wsdl
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/ProbeService/probeService.wsdl 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/ProbeService/probeService.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -1,49 +1,49 @@
-<!--
- ~ Licensed to the Apache Software Foundation (ASF) under one
- ~ or more contributor license agreements. See the NOTICE file
- ~ distributed with this work for additional information
- ~ regarding copyright ownership. The ASF licenses this file
- ~ to you under the Apache License, Version 2.0 (the
- ~ "License"); you may not use this file except in compliance
- ~ with the License. You may obtain a copy of the License at
- ~
- ~
http://www.apache.org/licenses/LICENSE-2.0
- ~
- ~ Unless required by applicable law or agreed to in writing,
- ~ software distributed under the License is distributed on an
- ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- ~ KIND, either express or implied. See the License for the
- ~ specific language governing permissions and limitations
- ~ under the License.
--->
-
-<wsdl:definitions
targetNamespace="http://ode/bpel/unit-test/ProbeService.wsdl"
- xmlns:tns="http://ode/bpel/unit-test/ProbeService.wsdl"
-
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
-
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
- xmlns="http://ode/bpel/unit-test/ProbeService.wsdl">
-
- <wsdl:message name="probeMessage">
- <wsdl:part name="probeName" type="xsd:string"/>
- <wsdl:part name="probeData" type="xsd:string"/>
- </wsdl:message>
-
- <wsdl:portType name="probeMessagePT">
- <wsdl:operation name="probe">
- <wsdl:input name="ProbeInputMessage"
message="tns:probeMessage"/>
- <wsdl:output name="ProbeOutputMessage"
message="tns:probeMessage"/>
- </wsdl:operation>
- </wsdl:portType>
-
- <wsdl:binding name="probeBinding"
type="tns:probeMessagePT">
- <wsdl:operation name="probe">
- </wsdl:operation>
- </wsdl:binding>
-
- <wsdl:service name="ProbeService">
- <wsdl:port name="ProbePort"
binding="tns:probeBinding">
- </wsdl:port>
- </wsdl:service>
-
-</wsdl:definitions>
-
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+-->
+
+<wsdl:definitions
targetNamespace="http://ode/bpel/unit-test/ProbeService.wsdl"
+ xmlns:tns="http://ode/bpel/unit-test/ProbeService.wsdl"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
+ xmlns="http://ode/bpel/unit-test/ProbeService.wsdl">
+
+ <wsdl:message name="probeMessage">
+ <wsdl:part name="probeName" type="xsd:string"/>
+ <wsdl:part name="probeData" type="xsd:string"/>
+ </wsdl:message>
+
+ <wsdl:portType name="probeMessagePT">
+ <wsdl:operation name="probe">
+ <wsdl:input name="ProbeInputMessage"
message="tns:probeMessage"/>
+ <wsdl:output name="ProbeOutputMessage"
message="tns:probeMessage"/>
+ </wsdl:operation>
+ </wsdl:portType>
+
+ <wsdl:binding name="probeBinding"
type="tns:probeMessagePT">
+ <wsdl:operation name="probe">
+ </wsdl:operation>
+ </wsdl:binding>
+
+ <wsdl:service name="ProbeService">
+ <wsdl:port name="ProbePort"
binding="tns:probeBinding">
+ </wsdl:port>
+ </wsdl:service>
+
+</wsdl:definitions>
+
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAlarm/HandleTimer-Timer.bpel
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAlarm/HandleTimer-Timer.bpel 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAlarm/HandleTimer-Timer.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -16,69 +16,69 @@
~ specific language governing permissions and limitations
~ under the License.
-->
-
-<bpel:process
xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
-
xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
-
xmlns:xs="http://www.w3.org/2001/XMLSchema"
-
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
-
xmlns:Client="http://example.com/HandleTimer/Client"
-
xmlns:this="http://ode.apache.org/example"
- queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
-
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
- name="Timer"
targetNamespace="http://ode.apache.org/example">
- <bpel:import
namespace="http://example.com/HandleTimer"
location="HandleTimer.wsdl"
importType="http://schemas.xmlsoap.org/wsdl/"/>
- <bpel:import
namespace="http://example.com/HandleTimer/Timer"
location="HandleTimer-Timer.wsdl"
importType="http://schemas.xmlsoap.org/wsdl/"/>
- <bpel:partnerLinks>
- <bpel:partnerLink name="timerAndClientPlkVar"
partnerLinkType="this:TimerAndClient" myRole="Timer_for_Client"/>
- </bpel:partnerLinks>
- <bpel:variables>
- <bpel:variable name="msg"
messageType="this:receiveRequest"/>
- <bpel:variable name="msg1"
messageType="this:receiveResponse"/>
- </bpel:variables>
- <bpel:sequence>
- <bpel:receive partnerLink="timerAndClientPlkVar"
portType="this:ForClient" operation="receive" variable="msg"
createInstance="yes"></bpel:receive>
- <bpel:assign name="init-variables-Timer">
- <bpel:copy>
- <bpel:from>
- <bpel:literal>
- <this:start>
- </this:start>
- </bpel:literal>
- </bpel:from>
- <bpel:to>$msg1.body</bpel:to>
- </bpel:copy>
- </bpel:assign>
- <bpel:scope>
- <bpel:faultHandlers>
- <bpel:catchAll>
- <bpel:empty/>
- </bpel:catchAll>
- </bpel:faultHandlers>
- <bpel:scope>
- <bpel:eventHandlers>
- <bpel:onAlarm>
- <bpel:for>"PT1S"</bpel:for>
- <bpel:scope>
- <bpel:throw faultName="tns:goodFault"/>
- </bpel:scope>
- </bpel:onAlarm>
- </bpel:eventHandlers>
- <bpel:if>
- <bpel:condition>$msg/start=10</bpel:condition>
- <bpel:sequence>
- <bpel:empty/>
- </bpel:sequence>
- <bpel:else>
- <bpel:sequence>
- <bpel:empty/>
- <bpel:wait>
- <bpel:for>'PT15S'</bpel:for>
- </bpel:wait>
- </bpel:sequence>
- </bpel:else>
- </bpel:if>
- </bpel:scope>
- </bpel:scope>
- <bpel:reply partnerLink="timerAndClientPlkVar"
portType="this:ForClient" operation="receive"
variable="msg1"></bpel:reply>
- </bpel:sequence>
+
+<bpel:process
xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
+
xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns:xs="http://www.w3.org/2001/XMLSchema"
+
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
+
xmlns:Client="http://example.com/HandleTimer/Client"
+
xmlns:this="http://ode.apache.org/example"
+ queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
+
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
+ name="Timer"
targetNamespace="http://ode.apache.org/example">
+ <bpel:import
namespace="http://example.com/HandleTimer"
location="HandleTimer.wsdl"
importType="http://schemas.xmlsoap.org/wsdl/"/>
+ <bpel:import
namespace="http://example.com/HandleTimer/Timer"
location="HandleTimer-Timer.wsdl"
importType="http://schemas.xmlsoap.org/wsdl/"/>
+ <bpel:partnerLinks>
+ <bpel:partnerLink name="timerAndClientPlkVar"
partnerLinkType="this:TimerAndClient" myRole="Timer_for_Client"/>
+ </bpel:partnerLinks>
+ <bpel:variables>
+ <bpel:variable name="msg"
messageType="this:receiveRequest"/>
+ <bpel:variable name="msg1"
messageType="this:receiveResponse"/>
+ </bpel:variables>
+ <bpel:sequence>
+ <bpel:receive partnerLink="timerAndClientPlkVar"
portType="this:ForClient" operation="receive" variable="msg"
createInstance="yes"></bpel:receive>
+ <bpel:assign name="init-variables-Timer">
+ <bpel:copy>
+ <bpel:from>
+ <bpel:literal>
+ <this:start>
+ </this:start>
+ </bpel:literal>
+ </bpel:from>
+ <bpel:to>$msg1.body</bpel:to>
+ </bpel:copy>
+ </bpel:assign>
+ <bpel:scope>
+ <bpel:faultHandlers>
+ <bpel:catchAll>
+ <bpel:empty/>
+ </bpel:catchAll>
+ </bpel:faultHandlers>
+ <bpel:scope>
+ <bpel:eventHandlers>
+ <bpel:onAlarm>
+ <bpel:for>"PT1S"</bpel:for>
+ <bpel:scope>
+ <bpel:throw faultName="tns:goodFault"/>
+ </bpel:scope>
+ </bpel:onAlarm>
+ </bpel:eventHandlers>
+ <bpel:if>
+ <bpel:condition>$msg/start=10</bpel:condition>
+ <bpel:sequence>
+ <bpel:empty/>
+ </bpel:sequence>
+ <bpel:else>
+ <bpel:sequence>
+ <bpel:empty/>
+ <bpel:wait>
+ <bpel:for>'PT15S'</bpel:for>
+ </bpel:wait>
+ </bpel:sequence>
+ </bpel:else>
+ </bpel:if>
+ </bpel:scope>
+ </bpel:scope>
+ <bpel:reply partnerLink="timerAndClientPlkVar"
portType="this:ForClient" operation="receive"
variable="msg1"></bpel:reply>
+ </bpel:sequence>
</bpel:process>
\ No newline at end of file
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAssignDate/NewDiagram-Pool.bpel
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAssignDate/NewDiagram-Pool.bpel 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAssignDate/NewDiagram-Pool.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -16,49 +16,49 @@
~ specific language governing permissions and limitations
~ under the License.
-->
-
-<bpel:process
xmlns:bpel="http://schemas.xmlsoap.org/ws/2004/03/business-process/&...
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns:pnlk="http://schemas.xmlsoap.org/ws/2004/03/partner-link/"
xmlns:Pool0="http://example.com/NewDiagram/Pool0"
xmlns:this="http://example.com/NewDiagram/Pool"
xmlns:diag="http://example.com/NewDiagram"
xmlns:bpmn="http://www.intalio.com/bpms"
xmlns:atomic="http://ode.apache.org/atomicScope"
queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
bpmn:label="Pool" bpmn:id="_ZbUEcNw9Edye_tsy8V393Q"
name="Pool"
targetNamespace="http://example.com/NewDiagram/Pool">
- <bpel:import
namespace="http://example.com/NewDiagram"
location="NewDiagram.wsdl"
importType="http://schemas.xmlsoap.org/wsdl/"/>
- <bpel:import
namespace="http://example.com/NewDiagram/Pool"
location="NewDiagram-Pool.wsdl"
importType="http://schemas.xmlsoap.org/wsdl/"/>
- <bpel:partnerLinks>
- <bpel:partnerLink name="pool0AndPoolPlkVar"
partnerLinkType="diag:Pool0AndPool" myRole="Pool_for_Pool0"/>
- </bpel:partnerLinks>
- <bpel:variables>
- <bpel:variable name="thisTaskRequestMsg"
messageType="this:TaskRequest"/>
- <bpel:variable name="thisTaskResponseMsg"
messageType="this:TaskResponse"/>
- <bpel:variable name="variable" type="xs:dateTime"/>
- </bpel:variables>
- <bpel:sequence>
- <bpel:receive partnerLink="pool0AndPoolPlkVar"
portType="this:ForPool0" operation="Task"
- variable="thisTaskRequestMsg"
createInstance="yes"/>
- <bpel:assign name="init-variables-Pool">
- <bpel:copy bpmn:label="$thisTaskResponseMsg">
- <bpel:from>
- <bpel:literal>
-<this:TaskResponse>OK</this:TaskResponse>
- </bpel:literal>
- </bpel:from>
- <bpel:to>$thisTaskResponseMsg.body</bpel:to>
- </bpel:copy>
- <bpel:copy bpmn:label="$variable">
- <bpel:from>xs:dateTime("2008-01-01T00:00:00Z")</bpel:from>
- <bpel:to>$variable</bpel:to>
- </bpel:copy>
- </bpel:assign>
- <bpel:assign bpmn:label="Task"
bpmn:id="_e0Xz0Nw9Edye_tsy8V393Q">
- <bpel:copy>
- <bpel:from>xs:dateTime($variable) + xs:dayTimeDuration
("P1D")</bpel:from>
- <bpel:to>$variable</bpel:to>
- </bpel:copy>
- <bpel:copy>
- <bpel:from>$variable + xs:dayTimeDuration
("P1D")</bpel:from>
- <bpel:to>$variable</bpel:to>
- </bpel:copy>
- </bpel:assign>
- <bpel:wait bpmn:label="EventIntermediateTimer"
bpmn:id="_cLa0kNw9Edye_tsy8V393Q">
- <bpel:until>$variable</bpel:until>
- </bpel:wait>
- <bpel:reply partnerLink="pool0AndPoolPlkVar"
portType="this:ForPool0" operation="Task"
- variable="thisTaskResponseMsg"/>
- </bpel:sequence>
+
+<bpel:process
xmlns:bpel="http://schemas.xmlsoap.org/ws/2004/03/business-process/&...
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns:pnlk="http://schemas.xmlsoap.org/ws/2004/03/partner-link/"
xmlns:Pool0="http://example.com/NewDiagram/Pool0"
xmlns:this="http://example.com/NewDiagram/Pool"
xmlns:diag="http://example.com/NewDiagram"
xmlns:bpmn="http://www.intalio.com/bpms"
xmlns:atomic="http://ode.apache.org/atomicScope"
queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
bpmn:label="Pool" bpmn:id="_ZbUEcNw9Edye_tsy8V393Q"
name="Pool"
targetNamespace="http://example.com/NewDiagram/Pool">
+ <bpel:import
namespace="http://example.com/NewDiagram"
location="NewDiagram.wsdl"
importType="http://schemas.xmlsoap.org/wsdl/"/>
+ <bpel:import
namespace="http://example.com/NewDiagram/Pool"
location="NewDiagram-Pool.wsdl"
importType="http://schemas.xmlsoap.org/wsdl/"/>
+ <bpel:partnerLinks>
+ <bpel:partnerLink name="pool0AndPoolPlkVar"
partnerLinkType="diag:Pool0AndPool" myRole="Pool_for_Pool0"/>
+ </bpel:partnerLinks>
+ <bpel:variables>
+ <bpel:variable name="thisTaskRequestMsg"
messageType="this:TaskRequest"/>
+ <bpel:variable name="thisTaskResponseMsg"
messageType="this:TaskResponse"/>
+ <bpel:variable name="variable" type="xs:dateTime"/>
+ </bpel:variables>
+ <bpel:sequence>
+ <bpel:receive partnerLink="pool0AndPoolPlkVar"
portType="this:ForPool0" operation="Task"
+ variable="thisTaskRequestMsg"
createInstance="yes"/>
+ <bpel:assign name="init-variables-Pool">
+ <bpel:copy bpmn:label="$thisTaskResponseMsg">
+ <bpel:from>
+ <bpel:literal>
+<this:TaskResponse>OK</this:TaskResponse>
+ </bpel:literal>
+ </bpel:from>
+ <bpel:to>$thisTaskResponseMsg.body</bpel:to>
+ </bpel:copy>
+ <bpel:copy bpmn:label="$variable">
+ <bpel:from>xs:dateTime("2008-01-01T00:00:00Z")</bpel:from>
+ <bpel:to>$variable</bpel:to>
+ </bpel:copy>
+ </bpel:assign>
+ <bpel:assign bpmn:label="Task"
bpmn:id="_e0Xz0Nw9Edye_tsy8V393Q">
+ <bpel:copy>
+ <bpel:from>xs:dateTime($variable) + xs:dayTimeDuration
("P1D")</bpel:from>
+ <bpel:to>$variable</bpel:to>
+ </bpel:copy>
+ <bpel:copy>
+ <bpel:from>$variable + xs:dayTimeDuration
("P1D")</bpel:from>
+ <bpel:to>$variable</bpel:to>
+ </bpel:copy>
+ </bpel:assign>
+ <bpel:wait bpmn:label="EventIntermediateTimer"
bpmn:id="_cLa0kNw9Edye_tsy8V393Q">
+ <bpel:until>$variable</bpel:until>
+ </bpel:wait>
+ <bpel:reply partnerLink="pool0AndPoolPlkVar"
portType="this:ForPool0" operation="Task"
+ variable="thisTaskResponseMsg"/>
+ </bpel:sequence>
</bpel:process>
\ No newline at end of file
Added:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAssignMissingData/TestIgnoreMissingFromData.bpel
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAssignMissingData/TestIgnoreMissingFromData.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAssignMissingData/TestIgnoreMissingFromData.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,71 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<bpel:process exitOnStandardFault="yes"
+ expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
+ name="TestIgnoreMissingFromData"
+ queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
+ suppressJoinFailure="yes" targetNamespace="test:test"
+
xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
+
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
+
xmlns:ode="http://www.apache.org/ode/type/extension"
+ xmlns:tns="test:test"
xmlns:xs="http://www.w3.org/2001/XMLSchema">
+ <bpel:import
importType="http://schemas.xmlsoap.org/wsdl/"
+ location="TestIgnoreMissingFromData.wsdl"
namespace="test:test"/>
+ <bpel:partnerLinks>
+ <bpel:partnerLink myRole="ServiceProvider" name="client"
partnerLinkType="tns:ServicePartnerLinkType"/>
+ </bpel:partnerLinks>
+ <bpel:variables>
+ <bpel:variable messageType="tns:InputMessage"
name="input"/>
+ <bpel:variable messageType="tns:OutputMessage"
name="output"/>
+ <bpel:variable element="tns:TestElement"
name="TestVar"/>
+ </bpel:variables>
+ <bpel:sequence name="process">
+ <bpel:receive createInstance="yes" name="ReceiveInput"
+ operation="process" partnerLink="client"
+ portType="tns:ServicePortType" variable="input"/>
+ <bpel:assign name="Assign" validate="no">
+ <bpel:copy>
+ <bpel:from>
+ <bpel:literal>
+ <tns:TestElement xmlns:tns="test:test"
+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="test:test TestIgnoreMissingFromData.wsdl ">
+ <!-- Omit the optional element. -->
+ </tns:TestElement>
+ </bpel:literal>
+ </bpel:from>
+ <bpel:to variable="TestVar"/>
+ </bpel:copy>
+ <bpel:copy ignoreMissingFromData="yes">
+ <bpel:from variable="TestVar">
+ <bpel:query
queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"><![CDATA[tns:OptionalElement]]></bpel:query>
+ </bpel:from>
+ <bpel:to part="payload" variable="output"/>
+ </bpel:copy>
+ <bpel:copy>
+ <bpel:from
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"><![CDATA["Test
passed."]]></bpel:from>
+ <bpel:to part="payload" variable="output"/>
+ </bpel:copy>
+ </bpel:assign>
+ <bpel:reply name="ReplyWithOutput" operation="process"
+ partnerLink="client" portType="tns:ServicePortType"
variable="output"/>
+ </bpel:sequence>
+</bpel:process>
+
Added:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAssignMissingData/TestIgnoreMissingFromData.wsdl
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAssignMissingData/TestIgnoreMissingFromData.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAssignMissingData/TestIgnoreMissingFromData.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,84 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<definitions name="TestIgnoreMissingFromData"
+ targetNamespace="test:test"
+ xmlns:tns="test:test"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+
xmlns="http://schemas.xmlsoap.org/wsdl/"
+
+
+ <types>
+ <schema attributeFormDefault="unqualified"
elementFormDefault="qualified"
+ targetNamespace="test:test"
+
xmlns="http://www.w3.org/2001/XMLSchema">
+
+ <element name="Input" type="string" />
+ <element name="Output" type="string" />
+
+ <element name="TestElement">
+ <complexType>
+ <sequence>
+ <element name="OptionalElement" type="string"
minOccurs="0" maxOccurs="1"></element>
+ </sequence>
+ </complexType>
+ </element>
+ </schema>
+ </types>
+
+ <message name="InputMessage">
+ <part name="payload" element="tns:Input"/>
+ </message>
+ <message name="OutputMessage">
+ <part name="payload" element="tns:Output"/>
+ </message>
+
+ <portType name="ServicePortType">
+ <operation name="process">
+ <input message="tns:InputMessage" />
+ <output message="tns:OutputMessage"/>
+ </operation>
+ </portType>
+
+ <plnk:partnerLinkType name="ServicePartnerLinkType">
+ <plnk:role name="ServiceProvider"
portType="tns:ServicePortType"/>
+ </plnk:partnerLinkType>
+
+ <binding name="ServiceBinding" type="tns:ServicePortType">
+ <soap:binding style="document"
transport="http://schemas.xmlsoap.org/soap/http" />
+ <operation name="process">
+ <soap:operation soapAction="test:test/process" />
+ <input>
+ <soap:body use="literal" />
+ </input>
+ <output>
+ <soap:body use="literal" />
+ </output>
+ </operation>
+ </binding>
+
+ <service name="TestIgnoreMissingFromDataService">
+ <port name="TestIgnoreMissingFromDataPort"
binding="tns:ServiceBinding">
+ <soap:address
location="http://[server]:[port]/ode/processes/TestIgnoreMissingFromData" />
+ </port>
+ </service>
+</definitions>
+
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAssignMissingData/deploy.xml
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAssignMissingData/deploy.xml 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAssignMissingData/deploy.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -19,7 +19,8 @@
<deploy
xmlns="http://www.apache.org/ode/schemas/dd/2007/03"
xmlns:pns="http://ode/bpel/unit-testAssign1"
- xmlns:wns="http://ode/bpel/unit-testAssign1.wsdl">
+ xmlns:wns="http://ode/bpel/unit-testAssign1.wsdl"
+ xmlns:ns1="test:test">
<process name="pns:TestAssign">
@@ -29,4 +30,12 @@
<service name="wns:TestAssignService"
port="TestAssignPort"/>
</provide>
</process>
+
+ <process name="ns1:TestIgnoreMissingFromData">
+ <active>true</active>
+ <provide partnerLink="client">
+ <service name="ns1:TestIgnoreMissingFromDataService"
port="TestIgnoreMissingFromDataPort"/>
+ </provide>
+ </process>
+
</deploy>
Added:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAssignMissingData/test1.properties
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAssignMissingData/test1.properties
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAssignMissingData/test1.properties 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,22 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+#
http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+namespace=http://ode/bpel/unit-testAssign1.wsdl
+service=TestAssignService
+operation=testAssign
+request1=<message><TestPart>Hello</TestPart></message>
+response1=.*Hello World.*
\ No newline at end of file
Added:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAssignMissingData/test2.properties
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAssignMissingData/test2.properties
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestAssignMissingData/test2.properties 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,22 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+#
http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+namespace=test:test
+service=TestIgnoreMissingFromDataService
+operation=process
+request1=<message><payload><test:Input
xmlns:test="test:test">abc</test:Input></payload></message>
+response1=.*Test passed.*
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestCorrelationMultiNegative/deploy.xml
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestCorrelationMultiNegative/deploy.xml 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestCorrelationMultiNegative/deploy.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -23,7 +23,7 @@
xmlns:wns="http://ode/bpel/unit-test/testCorrelation.wsdl">
- <process name="pns:TestCorrelationProcess">
+ <process name="pns:TestCorrelationNegativeProcess">
<active>true</active>
<provide partnerLink="request">
<service name="wns:testCorrelationService"
port="wns:testCorrelationPort"/>
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestCorrelationMultiNegative/testCorrelation.bpel
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestCorrelationMultiNegative/testCorrelation.bpel 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestCorrelationMultiNegative/testCorrelation.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -22,7 +22,7 @@
xmlns:tns="http://ode/bpel/unit-test/testCorrelation"
xmlns:wns="http://ode/bpel/unit-test/testCorrelation.wsdl"
xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
- name="TestCorrelationProcess"
+ name="TestCorrelationNegativeProcess"
targetNamespace="http://ode/bpel/unit-test/testCorrelation"
queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestDuration/BugCastDayTimeDurationToDuration-Pool.bpel
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestDuration/BugCastDayTimeDurationToDuration-Pool.bpel 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestDuration/BugCastDayTimeDurationToDuration-Pool.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -16,37 +16,37 @@
~ specific language governing permissions and limitations
~ under the License.
-->
-
-<bpel:process
xmlns:bpel="http://schemas.xmlsoap.org/ws/2004/03/business-process/&...
xmlns:pnlk="http://schemas.xmlsoap.org/ws/2004/03/partner-link/"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:diag="http://example.com/BugCastDayTimeDurationToDuration"
xmlns:Pool0="http://example.com/BugCastDayTimeDurationToDuration/Poo...
xmlns:tns="http://www.example.org/duration"
xmlns:this="http://example.com/BugCastDayTimeDurationToDuration/Pool...
xmlns:bpmn="http://www.intalio.com/bpms"
xmlns:atomic="http://ode.apache.org/atomicScope"
queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
bpmn:label="Pool" bpmn:id="_S2O9UOskEdyAk8HLE80VlA"
name="Pool"
targetNamespace="http://example.com/BugCastDayTimeDurationToDuration...
- <bpel:import
namespace="http://example.com/BugCastDayTimeDurationToDuration"
location="BugCastDayTimeDurationToDuration.wsdl"
importType="http://schemas.xmlsoap.org/wsdl/"/>
- <bpel:import
namespace="http://example.com/BugCastDayTimeDurationToDuration/Pool&...
location="BugCastDayTimeDurationToDuration-Pool.wsdl"
importType="http://schemas.xmlsoap.org/wsdl/"/>
- <bpel:partnerLinks>
- <bpel:partnerLink name="pool0AndPoolPlkVar"
partnerLinkType="diag:Pool0AndPool" myRole="Pool_for_Pool0"/>
- </bpel:partnerLinks>
- <bpel:variables>
- <bpel:variable name="thisTaskRequestMsg"
messageType="this:TaskRequest"/>
- <bpel:variable name="thisTaskResponseMsg"
messageType="this:TaskResponse"/>
- </bpel:variables>
- <bpel:sequence>
- <bpel:receive partnerLink="pool0AndPoolPlkVar"
portType="this:ForPool0" operation="Task"
variable="thisTaskRequestMsg" createInstance="yes"/>
- <bpel:assign name="init-variables-Pool">
- <bpel:copy bpmn:label="$thisTaskResponseMsg">
- <bpel:from>
-
<bpel:literal><this:TaskResponse>OK</this:TaskResponse></bpel:literal>
- </bpel:from>
- <bpel:to>$thisTaskResponseMsg.body</bpel:to>
- </bpel:copy>
- </bpel:assign>
- <bpel:assign bpmn:label="Task"
bpmn:id="_6_3QwOu1EdyUWbG-WWtMzg">
- <bpel:copy>
- <!--<bpel:from
xmlns:xdt="http://www.w3.org/2003/11/xpath-datatypes">xdt:da...
("PT2S")</bpel:from>-->
- <bpel:from>xs:dayTimeDuration ("PT2S")</bpel:from>
- <bpel:to>$thisTaskRequestMsg.body/tns:duration</bpel:to>
- </bpel:copy>
- </bpel:assign>
- <bpel:wait>
- <bpel:for>$thisTaskRequestMsg.body/tns:duration</bpel:for>
- </bpel:wait>
- <bpel:reply partnerLink="pool0AndPoolPlkVar"
portType="this:ForPool0" operation="Task"
variable="thisTaskResponseMsg"/>
- </bpel:sequence>
+
+<bpel:process
xmlns:bpel="http://schemas.xmlsoap.org/ws/2004/03/business-process/&...
xmlns:pnlk="http://schemas.xmlsoap.org/ws/2004/03/partner-link/"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:diag="http://example.com/BugCastDayTimeDurationToDuration"
xmlns:Pool0="http://example.com/BugCastDayTimeDurationToDuration/Poo...
xmlns:tns="http://www.example.org/duration"
xmlns:this="http://example.com/BugCastDayTimeDurationToDuration/Pool...
xmlns:bpmn="http://www.intalio.com/bpms"
xmlns:atomic="http://ode.apache.org/atomicScope"
queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
bpmn:label="Pool" bpmn:id="_S2O9UOskEdyAk8HLE80VlA"
name="Pool"
targetNamespace="http://example.com/BugCastDayTimeDurationToDuration...
+ <bpel:import
namespace="http://example.com/BugCastDayTimeDurationToDuration"
location="BugCastDayTimeDurationToDuration.wsdl"
importType="http://schemas.xmlsoap.org/wsdl/"/>
+ <bpel:import
namespace="http://example.com/BugCastDayTimeDurationToDuration/Pool&...
location="BugCastDayTimeDurationToDuration-Pool.wsdl"
importType="http://schemas.xmlsoap.org/wsdl/"/>
+ <bpel:partnerLinks>
+ <bpel:partnerLink name="pool0AndPoolPlkVar"
partnerLinkType="diag:Pool0AndPool" myRole="Pool_for_Pool0"/>
+ </bpel:partnerLinks>
+ <bpel:variables>
+ <bpel:variable name="thisTaskRequestMsg"
messageType="this:TaskRequest"/>
+ <bpel:variable name="thisTaskResponseMsg"
messageType="this:TaskResponse"/>
+ </bpel:variables>
+ <bpel:sequence>
+ <bpel:receive partnerLink="pool0AndPoolPlkVar"
portType="this:ForPool0" operation="Task"
variable="thisTaskRequestMsg" createInstance="yes"/>
+ <bpel:assign name="init-variables-Pool">
+ <bpel:copy bpmn:label="$thisTaskResponseMsg">
+ <bpel:from>
+
<bpel:literal><this:TaskResponse>OK</this:TaskResponse></bpel:literal>
+ </bpel:from>
+ <bpel:to>$thisTaskResponseMsg.body</bpel:to>
+ </bpel:copy>
+ </bpel:assign>
+ <bpel:assign bpmn:label="Task"
bpmn:id="_6_3QwOu1EdyUWbG-WWtMzg">
+ <bpel:copy>
+ <!--<bpel:from
xmlns:xdt="http://www.w3.org/2003/11/xpath-datatypes">xdt:da...
("PT2S")</bpel:from>-->
+ <bpel:from>xs:dayTimeDuration ("PT2S")</bpel:from>
+ <bpel:to>$thisTaskRequestMsg.body/tns:duration</bpel:to>
+ </bpel:copy>
+ </bpel:assign>
+ <bpel:wait>
+ <bpel:for>$thisTaskRequestMsg.body/tns:duration</bpel:for>
+ </bpel:wait>
+ <bpel:reply partnerLink="pool0AndPoolPlkVar"
portType="this:ForPool0" operation="Task"
variable="thisTaskResponseMsg"/>
+ </bpel:sequence>
</bpel:process>
\ No newline at end of file
Added: branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/TestIMA.bpel
===================================================================
--- branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/TestIMA.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/TestIMA.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,211 @@
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+-->
+
+<bpel:process name="TestIMAProcess"
targetNamespace="http://ode/bpel/unit-test/TestIMA"
suppressJoinFailure="yes"
xmlns:tns="http://ode/bpel/unit-test/TestIMA"
xmlns:wns="http://ode/bpel/unit-test/TestIMA.wsdl"
xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://docs.oasis-open.org/wsbpel/2.0/process/ex...
/usr/share/bpel-schema/ws-bpel_executable.xsd">
+ <bpel:import location="TestIMA.wsdl"
namespace="http://ode/bpel/unit-test/TestIMA.wsdl"
importType="http://schemas.xmlsoap.org/wsdl/" />
+ <bpel:partnerLinks>
+ <bpel:partnerLink name="client"
partnerLinkType="wns:TestIMAPL" myRole="TestIMAProvider"
partnerRole="TestIMAProvider"/>
+ </bpel:partnerLinks>
+ <bpel:variables>
+ <bpel:variable name="input"
messageType="wns:TestIMAMessage" />
+ <bpel:variable name="output"
messageType="wns:TestIMAMessage" />
+ </bpel:variables>
+ <bpel:correlationSets>
+ <bpel:correlationSet name="CorrelationSet"
properties="wns:input"></bpel:correlationSet>
+ </bpel:correlationSets>
+ <bpel:sequence>
+ <bpel:receive partnerLink="client" portType="wns:TestIMA"
operation="process" variable="input"
createInstance="yes">
+ <bpel:correlations>
+ <bpel:correlation set="CorrelationSet"
initiate="yes"></bpel:correlation>
+ </bpel:correlations>
+ </bpel:receive>
+
+ <bpel:scope name="ConflictingReceiveInOnly">
+ <bpel:faultHandlers>
+ <bpel:catch faultName="bpel:conflictingReceive">
+ <bpel:empty/>
+ </bpel:catch>
+ </bpel:faultHandlers>
+ <bpel:sequence>
+ <bpel:flow>
+ <bpel:receive partnerLink="client"
operation="inOnly" variable="input">
+ <bpel:correlations>
+ <bpel:correlation set="CorrelationSet"
initiate="no"></bpel:correlation>
+ </bpel:correlations>
+ </bpel:receive>
+ <bpel:receive partnerLink="client"
operation="inOnly" variable="input">
+ <bpel:correlations>
+ <bpel:correlation set="CorrelationSet"
initiate="no"></bpel:correlation>
+ </bpel:correlations>
+ </bpel:receive>
+ </bpel:flow>
+ <bpel:throw faultName="error"/>
+ </bpel:sequence>
+ </bpel:scope>
+
+ <bpel:scope name="ConflictingReceiveInOut">
+ <bpel:faultHandlers>
+ <bpel:catch faultName="bpel:conflictingReceive">
+ <bpel:empty/>
+ </bpel:catch>
+ </bpel:faultHandlers>
+ <bpel:sequence>
+ <bpel:flow>
+ <bpel:receive partnerLink="client"
operation="inOut" variable="input">
+ <bpel:correlations>
+ <bpel:correlation set="CorrelationSet"
initiate="no"></bpel:correlation>
+ </bpel:correlations>
+ </bpel:receive>
+ <bpel:receive partnerLink="client"
operation="inOut" variable="input">
+ <bpel:correlations>
+ <bpel:correlation set="CorrelationSet"
initiate="no"></bpel:correlation>
+ </bpel:correlations>
+ </bpel:receive>
+ </bpel:flow>
+ <bpel:throw faultName="error"/>
+ </bpel:sequence>
+ </bpel:scope>
+
+ <bpel:scope name="ConflictingReceiveInOutTwoMexes">
+ <bpel:faultHandlers>
+ <bpel:catch faultName="bpel:conflictingReceive">
+ <bpel:empty/>
+ </bpel:catch>
+ </bpel:faultHandlers>
+ <bpel:sequence>
+ <bpel:flow>
+ <bpel:receive partnerLink="client"
operation="inOut" variable="input"
messageExchange="mex1">
+ <bpel:correlations>
+ <bpel:correlation set="CorrelationSet"
initiate="no"></bpel:correlation>
+ </bpel:correlations>
+ </bpel:receive>
+ <bpel:receive partnerLink="client"
operation="inOut" variable="input"
messageExchange="mex2">
+ <bpel:correlations>
+ <bpel:correlation set="CorrelationSet"
initiate="no"></bpel:correlation>
+ </bpel:correlations>
+ </bpel:receive>
+ </bpel:flow>
+ <bpel:throw faultName="error"/>
+ </bpel:sequence>
+ </bpel:scope>
+
+ <!--
+ ~ This is correct path example, because it relies on sequential operations for
the same mex1.
+ ~ No conflictingRequest is thrown here.
+ -->
+ <bpel:scope name="NoConflictingRequest">
+ <bpel:sequence>
+ <bpel:receive partnerLink="client"
operation="inOut2" variable="input"
messageExchange="mex1">
+ <bpel:correlations>
+ <bpel:correlation set="CorrelationSet"
initiate="no"></bpel:correlation>
+ </bpel:correlations>
+ </bpel:receive>
+ <bpel:flow>
+ <bpel:sequence>
+ <bpel:wait>
+ <!-- We need a constraint of executing following reply in
new job in order to register concurrent receive before reply -->
+ <bpel:for>'PT1S'</bpel:for>
+ </bpel:wait>
+ <bpel:reply partnerLink="client"
portType="wns:TestIMA" operation="inOut2" variable="input"
messageExchange="mex1" />
+ </bpel:sequence>
+ <bpel:sequence>
+ <bpel:receive partnerLink="client"
operation="inOut2" variable="input"
messageExchange="mex1">
+ <bpel:correlations>
+ <bpel:correlation set="CorrelationSet"
initiate="no"></bpel:correlation>
+ </bpel:correlations>
+ </bpel:receive>
+ <bpel:reply partnerLink="client"
portType="wns:TestIMA" operation="inOut2" variable="input"
messageExchange="mex1" />
+ </bpel:sequence>
+ </bpel:flow>
+ </bpel:sequence>
+ </bpel:scope>
+
+ <bpel:scope name="ConflictingRequest">
+ <bpel:sequence>
+ <bpel:receive partnerLink="client"
operation="inOut3" variable="input"
messageExchange="mex1">
+ <bpel:correlations>
+ <bpel:correlation set="CorrelationSet"
initiate="no"></bpel:correlation>
+ </bpel:correlations>
+ </bpel:receive>
+ <bpel:flow>
+ <bpel:scope
xmlns:ext="http://ode.apache.org/activityRecovery">
+ <bpel:faultHandlers>
+ <bpel:catch faultName="ext:activityFailure">
+ <bpel:empty/>
+ </bpel:catch>
+ </bpel:faultHandlers>
+ <bpel:sequence>
+ <bpel:invoke operation="inOut3"
partnerLink="client" inputVariable="input"
outputVariable="output">
+ <ext:failureHandling>
+
<ext:faultOnFailure>true</ext:faultOnFailure>
+ </ext:failureHandling>
+ </bpel:invoke>
+ <bpel:throw
faultName="error"></bpel:throw>
+ </bpel:sequence>
+ </bpel:scope>
+ <bpel:scope>
+ <bpel:faultHandlers>
+ <bpel:catch
faultName="bpel:conflictingRequest">
+ <bpel:empty/>
+ </bpel:catch>
+ </bpel:faultHandlers>
+ <bpel:sequence>
+ <bpel:receive operation="inOut3"
partnerLink="client" variable="input"
messageExchange="mex1">
+ <bpel:correlations>
+ <bpel:correlation set="CorrelationSet"
initiate="no"></bpel:correlation>
+ </bpel:correlations>
+ </bpel:receive>
+ <bpel:throw
faultName="error"></bpel:throw>
+ </bpel:sequence>
+ </bpel:scope>
+ </bpel:flow>
+ <bpel:reply operation="inOut3"
partnerLink="client" variable="input"
messageExchange="mex1"/>
+
+ <bpel:receive partnerLink="client"
operation="inOut3" variable="input"
messageExchange="mex1">
+ <bpel:correlations>
+ <bpel:correlation set="CorrelationSet"
initiate="no"></bpel:correlation>
+ </bpel:correlations>
+ </bpel:receive>
+ <bpel:reply operation="inOut3"
partnerLink="client" variable="input"
messageExchange="mex1"/>
+ </bpel:sequence>
+ </bpel:scope>
+
+ <bpel:scope name="TwoMexesInOut">
+ <bpel:sequence>
+ <bpel:receive partnerLink="client"
operation="inOut4" variable="input"
messageExchange="mex2">
+ <bpel:correlations>
+ <bpel:correlation set="CorrelationSet"
initiate="no"></bpel:correlation>
+ </bpel:correlations>
+ </bpel:receive>
+
+ <bpel:receive partnerLink="client"
operation="inOut4" variable="input"
messageExchange="mex3">
+ <bpel:correlations>
+ <bpel:correlation set="CorrelationSet"
initiate="no"></bpel:correlation>
+ </bpel:correlations>
+ </bpel:receive>
+
+ <bpel:reply partnerLink="client"
portType="wns:TestIMA" operation="inOut4" variable="input"
messageExchange="mex2" />
+ <bpel:reply partnerLink="client"
portType="wns:TestIMA" operation="inOut4" variable="input"
messageExchange="mex3" />
+ </bpel:sequence>
+ </bpel:scope>
+
+ <bpel:reply partnerLink="client" portType="wns:TestIMA"
operation="process" variable="input" />
+ </bpel:sequence>
+</bpel:process>
+
Added: branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/TestIMA.wsdl
===================================================================
--- branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/TestIMA.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/TestIMA.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,71 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+-->
+<definitions name="TestIMA"
+ targetNamespace="http://ode/bpel/unit-test/TestIMA.wsdl"
+ xmlns:tns="http://ode/bpel/unit-test/TestIMA.wsdl"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns="http://schemas.xmlsoap.org/wsdl/"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+
xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop"
+
+
+ <message name="TestIMAMessage">
+ <part name="payload" type="xsd:string"/>
+ <part name="value" type="xsd:string"/>
+ </message>
+
+ <portType name="TestIMA">
+ <operation name="process">
+ <input message="tns:TestIMAMessage" />
+ <output message="tns:TestIMAMessage"/>
+ </operation>
+ <operation name="complete">
+ <input message="tns:TestIMAMessage" />
+ <output message="tns:TestIMAMessage"/>
+ </operation>
+ <operation name="inOnly">
+ <input message="tns:TestIMAMessage"></input>
+
+ </operation>
+ <operation name="inOut">
+ <input message="tns:TestIMAMessage"></input>
+ <output message="tns:TestIMAMessage"></output>
+ </operation>
+ <operation name="inOut2">
+ <input message="tns:TestIMAMessage"></input>
+ <output message="tns:TestIMAMessage"></output>
+ </operation>
+ <operation name="inOut3">
+ <input message="tns:TestIMAMessage"></input>
+ <output message="tns:TestIMAMessage"></output>
+ </operation>
+ <operation name="inOut4">
+ <input message="tns:TestIMAMessage"></input>
+ <output message="tns:TestIMAMessage"></output>
+ </operation>
+ </portType>
+
+ <plnk:partnerLinkType name="TestIMAPL">
+ <plnk:role name="TestIMAProvider"
portType="tns:TestIMA"/>
+ </plnk:partnerLinkType>
+ <vprop:property name="input" type="xsd:string"/>
+ <vprop:propertyAlias propertyName="tns:input"
messageType="tns:TestIMAMessage" part="payload"
type="xsd:string"/>
+</definitions>
Added: branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/deploy.xml
===================================================================
--- branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/deploy.xml
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/deploy.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,33 @@
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+-->
+
+<deploy
xmlns="http://www.apache.org/ode/schemas/dd/2007/03"
+ xmlns:pns="http://ode/bpel/unit-test/TestIMA"
+ xmlns:wns="http://ode/bpel/unit-test/TestIMA.wsdl">
+
+ <process name="pns:TestIMAProcess">
+ <active>true</active>
+ <provide partnerLink="client">
+ <service name="wns:TestIMAService" port="wns:TestIMAPort"/>
+ </provide>
+ <invoke partnerLink="client">
+ <service name="wns:TestIMAService"
port="wns:TestIMAPort"/>
+ </invoke>
+ </process>
+</deploy>
Added:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/test1.properties
===================================================================
--- branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/test1.properties
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/test1.properties 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,22 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+#
http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+namespace=http://ode/bpel/unit-test/TestIMA.wsdl
+service=TestIMAService
+operation=process
+request1=<message><payload>test</payload><value>process</value></message>
+response1=.*
Added:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/test2.properties
===================================================================
--- branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/test2.properties
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/test2.properties 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,27 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+#
http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+#NoConflictingRequestInOut
+sequential=true
+namespace=http://ode/bpel/unit-test/TestIMA.wsdl
+service=TestIMAService
+operation=inOut2
+request1=<message><payload>test</payload><value>NoConflictingRequestInOut1</value></message>
+response1=.*
+request2=<message><payload>test</payload><value>NoConflictingRequestInOut2</value></message>
+response2=.*
+
Added:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/test3.properties
===================================================================
--- branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/test3.properties
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/test3.properties 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,26 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+#
http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+#ConflictingRequest
+sequential=true
+namespace=http://ode/bpel/unit-test/TestIMA.wsdl
+service=TestIMAService
+operation=inOut3
+request1=<message><payload>test</payload><value>ConflictingRequest1</value></message>
+response1=.*
+request2=<message><payload>test</payload><value>ConflictingRequest1</value></message>
+response2=.*
Added:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/test4.properties
===================================================================
--- branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/test4.properties
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestIMA/test4.properties 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,26 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+#
http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+#TwoMexesInOut
+sequential=false
+namespace=http://ode/bpel/unit-test/TestIMA.wsdl
+service=TestIMAService
+operation=inOut4
+request1=<message><payload>test</payload><value>TwoMexesInOut1</value></message>
+response1=.*
+request2=<message><payload>test</payload><value>TwoMexesInOut2</value></message>
+response2=.*
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestInsertMissingData/TestInsertMissingData.bpel
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestInsertMissingData/TestInsertMissingData.bpel 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestInsertMissingData/TestInsertMissingData.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -1,105 +1,105 @@
-<!--
- ~ Licensed to the Apache Software Foundation (ASF) under one
- ~ or more contributor license agreements. See the NOTICE file
- ~ distributed with this work for additional information
- ~ regarding copyright ownership. The ASF licenses this file
- ~ to you under the Apache License, Version 2.0 (the
- ~ "License"); you may not use this file except in compliance
- ~ with the License. You may obtain a copy of the License at
- ~
- ~
http://www.apache.org/licenses/LICENSE-2.0
- ~
- ~ Unless required by applicable law or agreed to in writing,
- ~ software distributed under the License is distributed on an
- ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- ~ KIND, either express or implied. See the License for the
- ~ specific language governing permissions and limitations
- ~ under the License.
--->
-<process
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-
xsi:schemaLocation="http://docs.oasis-open.org/wsbpel/2.0/process/ex...
../../../../../../../bpel-schemas/src/main/resources/wsbpel_executable.xsd"
- xmlns:tns="http://ode/bpel/unit-test/TestInsertMissingData"
- xmlns:prb="http://ode/bpel/unit-test/ProbeService.wsdl"
- xmlns:types="http://ode/bpel/unit-test/TestInsertMissingData.wsdl.types"
- xmlns:foo="http://ode/bpel/unit-test/TestInsertMissingData.wsdl.types"
-
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
- xmlns:wns="http://ode/bpel/unit-test/TestInsertMissingData.wsdl"
-
xmlns:ode="http://www.apache.org/ode/type/extension"
-
xmlns:fn="http://www.w3.org/2005/xpath-functions"
-
xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
- targetNamespace="http://ode/bpel/unit-test/TestInsertMissingData"
- name="TestInsertMissingData"
- queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
- expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
- suppressJoinFailure="yes">
-
- <import location="TestInsertMissingData.wsdl"
- namespace="http://ode/bpel/unit-test/TestInsertMissingData.wsdl"
-
importType="http://schemas.xmlsoap.org/wsdl/" />
- <import location="../ProbeService/probeService.wsdl"
- namespace="http://ode/bpel/unit-test/ProbeService.wsdl"
-
importType="http://schemas.xmlsoap.org/wsdl/"/>
-
- <partnerLinks>
- <partnerLink name="request"
partnerLinkType="wns:TestInsertMissingDataRequest"
myRole="TestInsertMissingDataService"/>
- </partnerLinks>
- <variables>
- <variable name="request" messageType="wns:requestMessage"/>
- <variable name="testType" element="types:aTestMessage"/>
- <variable name="reply" messageType="wns:replyMessage"/>
- </variables>
- <sequence>
- <receive name="receive1" partnerLink="request"
portType="wns:TestInsertMissingDataPT" operation="request"
variable="request" createInstance="yes"/>
-
- <!-- test cases for ignore missing to data -->
- <assign name="assign1">
- <copy insertMissingToData="yes">
-
<from>$request.requestMessageData/typeIndicators/types:indicatorTwo</from>
- <to>$testType/@xsi:nil</to>
- </copy>
- <copy insertMissingToData="yes">
-
<from>$request.requestMessageData/typeIndicators/types:indicatorTwo</from>
- <to>$testType/typeIndicators/types:indicatorTwo</to>
- </copy>
- <copy>
- <from>ode:delete($testType/typeIndicators)</from>
- <to>$testType</to>
- </copy>
- <copy insertMissingToData="yes">
-
<from>$request.requestMessageData/typeIndicators/types:indicatorTwo</from>
- <to>$testType/child::typeIndicators/types:indicatorTwo</to>
- </copy>
- <copy>
- <from>ode:delete($testType/typeIndicators)</from>
- <to>$testType</to>
- </copy>
- <copy insertMissingToData="yes">
-
<from>$request.requestMessageData/typeIndicators/types:indicatorTwo</from>
- <to>$testType/child::typeIndicators/child::types:indicatorTwo</to>
- </copy>
- <copy>
- <from>ode:delete($testType/typeIndicators)</from>
- <to>$testType</to>
- </copy>
- <copy insertMissingToData="yes">
-
<from>$request.requestMessageData/typeIndicators/types:indicatorTwo</from>
- <to
variable="testType">/typeIndicators/child::types:indicatorTwo</to>
- </copy>
- </assign>
-
- <assign name="assign3">
- <copy>
- <from>$request.requestMessageData/requestID</from>
- <to variable="reply" part="replyID"/>
- </copy>
- <copy>
- <from>
- <literal><![CDATA[pass]]></literal>
- </from>
- <to>$reply.replyText</to>
- </copy>
- </assign>
-
- <reply name="reply" partnerLink="request"
portType="wns:TestInsertMissingDataPT" operation="request"
variable="reply"/>
- </sequence>
- </process>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+-->
+<process
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+
xsi:schemaLocation="http://docs.oasis-open.org/wsbpel/2.0/process/ex...
../../../../../../../bpel-schemas/src/main/resources/wsbpel_executable.xsd"
+ xmlns:tns="http://ode/bpel/unit-test/TestInsertMissingData"
+ xmlns:prb="http://ode/bpel/unit-test/ProbeService.wsdl"
+ xmlns:types="http://ode/bpel/unit-test/TestInsertMissingData.wsdl.types"
+ xmlns:foo="http://ode/bpel/unit-test/TestInsertMissingData.wsdl.types"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:wns="http://ode/bpel/unit-test/TestInsertMissingData.wsdl"
+
xmlns:ode="http://www.apache.org/ode/type/extension"
+
xmlns:fn="http://www.w3.org/2005/xpath-functions"
+
xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
+ targetNamespace="http://ode/bpel/unit-test/TestInsertMissingData"
+ name="TestInsertMissingData"
+ queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
+ expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
+ suppressJoinFailure="yes">
+
+ <import location="TestInsertMissingData.wsdl"
+ namespace="http://ode/bpel/unit-test/TestInsertMissingData.wsdl"
+
importType="http://schemas.xmlsoap.org/wsdl/" />
+ <import location="../ProbeService/probeService.wsdl"
+ namespace="http://ode/bpel/unit-test/ProbeService.wsdl"
+
importType="http://schemas.xmlsoap.org/wsdl/"/>
+
+ <partnerLinks>
+ <partnerLink name="request"
partnerLinkType="wns:TestInsertMissingDataRequest"
myRole="TestInsertMissingDataService"/>
+ </partnerLinks>
+ <variables>
+ <variable name="request" messageType="wns:requestMessage"/>
+ <variable name="testType" element="types:aTestMessage"/>
+ <variable name="reply" messageType="wns:replyMessage"/>
+ </variables>
+ <sequence>
+ <receive name="receive1" partnerLink="request"
portType="wns:TestInsertMissingDataPT" operation="request"
variable="request" createInstance="yes"/>
+
+ <!-- test cases for ignore missing to data -->
+ <assign name="assign1">
+ <copy insertMissingToData="yes">
+
<from>$request.requestMessageData/typeIndicators/types:indicatorTwo</from>
+ <to>$testType/@xsi:nil</to>
+ </copy>
+ <copy insertMissingToData="yes">
+
<from>$request.requestMessageData/typeIndicators/types:indicatorTwo</from>
+ <to>$testType/typeIndicators/types:indicatorTwo</to>
+ </copy>
+ <copy>
+ <from>ode:delete($testType/typeIndicators)</from>
+ <to>$testType</to>
+ </copy>
+ <copy insertMissingToData="yes">
+
<from>$request.requestMessageData/typeIndicators/types:indicatorTwo</from>
+ <to>$testType/child::typeIndicators/types:indicatorTwo</to>
+ </copy>
+ <copy>
+ <from>ode:delete($testType/typeIndicators)</from>
+ <to>$testType</to>
+ </copy>
+ <copy insertMissingToData="yes">
+
<from>$request.requestMessageData/typeIndicators/types:indicatorTwo</from>
+ <to>$testType/child::typeIndicators/child::types:indicatorTwo</to>
+ </copy>
+ <copy>
+ <from>ode:delete($testType/typeIndicators)</from>
+ <to>$testType</to>
+ </copy>
+ <copy insertMissingToData="yes">
+
<from>$request.requestMessageData/typeIndicators/types:indicatorTwo</from>
+ <to
variable="testType">/typeIndicators/child::types:indicatorTwo</to>
+ </copy>
+ </assign>
+
+ <assign name="assign3">
+ <copy>
+ <from>$request.requestMessageData/requestID</from>
+ <to variable="reply" part="replyID"/>
+ </copy>
+ <copy>
+ <from>
+ <literal><![CDATA[pass]]></literal>
+ </from>
+ <to>$reply.replyText</to>
+ </copy>
+ </assign>
+
+ <reply name="reply" partnerLink="request"
portType="wns:TestInsertMissingDataPT" operation="request"
variable="reply"/>
+ </sequence>
+ </process>
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestInsertMissingData/TestInsertMissingData.wsdl
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestInsertMissingData/TestInsertMissingData.wsdl 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestInsertMissingData/TestInsertMissingData.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -1,102 +1,102 @@
-<!--
- ~ Licensed to the Apache Software Foundation (ASF) under one
- ~ or more contributor license agreements. See the NOTICE file
- ~ distributed with this work for additional information
- ~ regarding copyright ownership. The ASF licenses this file
- ~ to you under the Apache License, Version 2.0 (the
- ~ "License"); you may not use this file except in compliance
- ~ with the License. You may obtain a copy of the License at
- ~
- ~
http://www.apache.org/licenses/LICENSE-2.0
- ~
- ~ Unless required by applicable law or agreed to in writing,
- ~ software distributed under the License is distributed on an
- ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- ~ KIND, either express or implied. See the License for the
- ~ specific language governing permissions and limitations
- ~ under the License.
--->
-<wsdl:definitions
- targetNamespace="http://ode/bpel/unit-test/TestInsertMissingData.wsdl"
- xmlns:tns="http://ode/bpel/unit-test/TestInsertMissingData.wsdl"
- xmlns:typens="http://ode/bpel/unit-test/TestInsertMissingData.wsdl.types"
- xmlns="http://ode/bpel/unit-test/TestInsertMissingData.wsdl"
- xmlns:prb="http://ode/bpel/unit-test/ProbeService.wsdl"
-
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
-
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
-
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
-
xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop">
-
- <wsdl:types>
-
- <xsd:schema
-
targetNamespace="http://ode/bpel/unit-test/TestInsertMissingData.wsdl.types"
- xmlns="http://ode/bpel/unit-test/TestInsertMissingData.wsdl.types"
-
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
-
- <xsd:element name="aTestMessage"
type="testMessage"></xsd:element>
- <xsd:element name="indicator" type="xsd:string"
abstract="true"/>
- <xsd:element name="indicatorOne" type="xsd:string"
substitutionGroup="indicator"/>
- <xsd:element name="indicatorTwo" type="xsd:string"
substitutionGroup="indicator"/>
-
- <xsd:complexType name="typeIndicator">
- <xsd:sequence>
- <xsd:element ref="indicatorOne"/>
- <xsd:element ref="indicatorTwo"/>
- </xsd:sequence>
- </xsd:complexType>
- <xsd:complexType name="testMessage">
- <xsd:sequence>
- <xsd:element name="requestID" type="xsd:string"/>
- <xsd:element name="requestText"
type="xsd:string"/>
- <xsd:element name="typeIndicators"
type="typeIndicator"/>
- </xsd:sequence>
- </xsd:complexType>
-
- </xsd:schema>
- </wsdl:types>
-
- <wsdl:message name="requestMessage">
- <wsdl:part name="requestMessageData"
element="typens:aTestMessage"/>
- </wsdl:message>
-
- <wsdl:message name="replyMessage">
- <wsdl:part name="replyID" type="xsd:string"/>
- <wsdl:part name="replyText" type="xsd:string"/>
- </wsdl:message>
-
- <wsdl:portType name="TestInsertMissingDataPT">
- <wsdl:operation name="request">
- <wsdl:input message="requestMessage"/>
- <wsdl:output message="replyMessage"/>
- </wsdl:operation>
- </wsdl:portType>
-
- <wsdl:binding name="TestInsertMissingDataBinding"
type="tns:TestInsertMissingDataPT">
- <wsdl:operation name="request">
- </wsdl:operation>
- </wsdl:binding>
- <wsdl:service name="TestInsertMissingDataService">
- <wsdl:port name="TestInsertMissingDataPort"
binding="tns:TestInsertMissingDataBinding">
- </wsdl:port>
- </wsdl:service>
-
- <plnk:partnerLinkType name="TestInsertMissingDataRequest">
- <plnk:role name="TestInsertMissingDataService"
portType="TestInsertMissingDataPT"/>
- </plnk:partnerLinkType>
-
- <plnk:partnerLinkType name="probeRequest">
- <plnk:role name="probeService"
portType="prb:probeMessagePT"/>
- </plnk:partnerLinkType>
-
- <vprop:property name="testProbeID" type="xsd:string"/>
- <vprop:propertyAlias propertyName="tns:testProbeID"
messageType="tns:requestMessage"/>
-
- <vprop:property name="testPath" type="xsd:string"/>
- <vprop:propertyAlias propertyName="tns:testPath"
messageType="tns:requestMessage" part="requestMessageData">
- <vprop:query
queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
- typeIndicators/typens:indicatorTwo
- </vprop:query>
- </vprop:propertyAlias>
-
-</wsdl:definitions>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+-->
+<wsdl:definitions
+ targetNamespace="http://ode/bpel/unit-test/TestInsertMissingData.wsdl"
+ xmlns:tns="http://ode/bpel/unit-test/TestInsertMissingData.wsdl"
+ xmlns:typens="http://ode/bpel/unit-test/TestInsertMissingData.wsdl.types"
+ xmlns="http://ode/bpel/unit-test/TestInsertMissingData.wsdl"
+ xmlns:prb="http://ode/bpel/unit-test/ProbeService.wsdl"
+
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+
xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop">
+
+ <wsdl:types>
+
+ <xsd:schema
+
targetNamespace="http://ode/bpel/unit-test/TestInsertMissingData.wsdl.types"
+ xmlns="http://ode/bpel/unit-test/TestInsertMissingData.wsdl.types"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
+
+ <xsd:element name="aTestMessage"
type="testMessage"></xsd:element>
+ <xsd:element name="indicator" type="xsd:string"
abstract="true"/>
+ <xsd:element name="indicatorOne" type="xsd:string"
substitutionGroup="indicator"/>
+ <xsd:element name="indicatorTwo" type="xsd:string"
substitutionGroup="indicator"/>
+
+ <xsd:complexType name="typeIndicator">
+ <xsd:sequence>
+ <xsd:element ref="indicatorOne"/>
+ <xsd:element ref="indicatorTwo"/>
+ </xsd:sequence>
+ </xsd:complexType>
+ <xsd:complexType name="testMessage">
+ <xsd:sequence>
+ <xsd:element name="requestID" type="xsd:string"/>
+ <xsd:element name="requestText"
type="xsd:string"/>
+ <xsd:element name="typeIndicators"
type="typeIndicator"/>
+ </xsd:sequence>
+ </xsd:complexType>
+
+ </xsd:schema>
+ </wsdl:types>
+
+ <wsdl:message name="requestMessage">
+ <wsdl:part name="requestMessageData"
element="typens:aTestMessage"/>
+ </wsdl:message>
+
+ <wsdl:message name="replyMessage">
+ <wsdl:part name="replyID" type="xsd:string"/>
+ <wsdl:part name="replyText" type="xsd:string"/>
+ </wsdl:message>
+
+ <wsdl:portType name="TestInsertMissingDataPT">
+ <wsdl:operation name="request">
+ <wsdl:input message="requestMessage"/>
+ <wsdl:output message="replyMessage"/>
+ </wsdl:operation>
+ </wsdl:portType>
+
+ <wsdl:binding name="TestInsertMissingDataBinding"
type="tns:TestInsertMissingDataPT">
+ <wsdl:operation name="request">
+ </wsdl:operation>
+ </wsdl:binding>
+ <wsdl:service name="TestInsertMissingDataService">
+ <wsdl:port name="TestInsertMissingDataPort"
binding="tns:TestInsertMissingDataBinding">
+ </wsdl:port>
+ </wsdl:service>
+
+ <plnk:partnerLinkType name="TestInsertMissingDataRequest">
+ <plnk:role name="TestInsertMissingDataService"
portType="TestInsertMissingDataPT"/>
+ </plnk:partnerLinkType>
+
+ <plnk:partnerLinkType name="probeRequest">
+ <plnk:role name="probeService"
portType="prb:probeMessagePT"/>
+ </plnk:partnerLinkType>
+
+ <vprop:property name="testProbeID" type="xsd:string"/>
+ <vprop:propertyAlias propertyName="tns:testProbeID"
messageType="tns:requestMessage"/>
+
+ <vprop:property name="testPath" type="xsd:string"/>
+ <vprop:propertyAlias propertyName="tns:testPath"
messageType="tns:requestMessage" part="requestMessageData">
+ <vprop:query
queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ typeIndicators/typens:indicatorTwo
+ </vprop:query>
+ </vprop:propertyAlias>
+
+</wsdl:definitions>
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestInsertMissingData/deploy.xml
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestInsertMissingData/deploy.xml 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestInsertMissingData/deploy.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -1,31 +1,31 @@
-<!--
- ~ Licensed to the Apache Software Foundation (ASF) under one
- ~ or more contributor license agreements. See the NOTICE file
- ~ distributed with this work for additional information
- ~ regarding copyright ownership. The ASF licenses this file
- ~ to you under the Apache License, Version 2.0 (the
- ~ "License"); you may not use this file except in compliance
- ~ with the License. You may obtain a copy of the License at
- ~
- ~
http://www.apache.org/licenses/LICENSE-2.0
- ~
- ~ Unless required by applicable law or agreed to in writing,
- ~ software distributed under the License is distributed on an
- ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- ~ KIND, either express or implied. See the License for the
- ~ specific language governing permissions and limitations
- ~ under the License.
--->
-
-<deploy
xmlns="http://www.apache.org/ode/schemas/dd/2007/03"
- xmlns:pns="http://ode/bpel/unit-test/TestInsertMissingData"
- xmlns:wns="http://ode/bpel/unit-test/TestInsertMissingData.wsdl">
-
-
- <process name="pns:TestInsertMissingData">
- <active>true</active>
- <provide partnerLink="request">
- <service name="wns:TestInsertMissingDataService"
port="wns:TestInsertMissingDataPort"/>
- </provide>
- </process>
-</deploy>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+-->
+
+<deploy
xmlns="http://www.apache.org/ode/schemas/dd/2007/03"
+ xmlns:pns="http://ode/bpel/unit-test/TestInsertMissingData"
+ xmlns:wns="http://ode/bpel/unit-test/TestInsertMissingData.wsdl">
+
+
+ <process name="pns:TestInsertMissingData">
+ <active>true</active>
+ <provide partnerLink="request">
+ <service name="wns:TestInsertMissingDataService"
port="wns:TestInsertMissingDataPort"/>
+ </provide>
+ </process>
+</deploy>
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestInsertMissingData/test1.properties
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestInsertMissingData/test1.properties 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestInsertMissingData/test1.properties 2010-04-14
18:25:55 UTC (rev 620)
@@ -1,22 +1,22 @@
-#
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements. See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-#
-#
http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-namespace=http://ode/bpel/unit-test/TestInsertMissingData.wsdl
-service=TestInsertMissingDataService
-operation=request
-request1=<message><requestMessageData><ens:aTestMessage
xmlns:ens="http://ode/bpel/unit-test/TestInsertMissingData.wsdl.types"><requestID>Start
InsertMissingData</requestID><requestText>Event
InsertMissingData</requestText><typeIndicators
xmlns:foo="http://ode/bpel/unit-test/TestInsertMissingData.wsdl.types"><foo:indicatorOne>fail</foo:indicatorOne><foo:indicatorTwo>fail</foo:indicatorTwo></typeIndicators></ens:aTestMessage></requestMessageData></message>
-response1=.*<replyID>Start
InsertMissingData</replyID><replyText>pass</replyText>.*
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+#
http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+namespace=http://ode/bpel/unit-test/TestInsertMissingData.wsdl
+service=TestInsertMissingDataService
+operation=request
+request1=<message><requestMessageData><ens:aTestMessage
xmlns:ens="http://ode/bpel/unit-test/TestInsertMissingData.wsdl.types"><requestID>Start
InsertMissingData</requestID><requestText>Event
InsertMissingData</requestText><typeIndicators
xmlns:foo="http://ode/bpel/unit-test/TestInsertMissingData.wsdl.types"><foo:indicatorOne>fail</foo:indicatorOne><foo:indicatorTwo>fail</foo:indicatorTwo></typeIndicators></ens:aTestMessage></requestMessageData></message>
+response1=.*<replyID>Start
InsertMissingData</replyID><replyText>pass</replyText>.*
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/PickProcess.bpel
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/PickProcess.bpel 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/PickProcess.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -16,155 +16,155 @@
~ specific language governing permissions and limitations
~ under the License.
-->
-
-<process name="PickProcess" suppressJoinFailure="yes"
exitOnStandardFault="no"
-
xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
-
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
-
xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
-
xmlns:srvns="http://www.stark.com/PickService"
-
xmlns:tns="http://www.stark.com/PickProcess"
-
targetNamespace="http://emcs/www.stark.com/PickProcess">
-
- <import
importType="http://schemas.xmlsoap.org/wsdl/"
location="PickService.wsdl"
namespace="http://www.stark.com/PickService"/>
-
-<partnerLinks>
- <partnerLink name="IncomingLink" myRole="PickServiceProvider"
partnerLinkType="srvns:PickServicePLT"/>
-</partnerLinks>
-
-<correlationSets>
- <correlationSet name="CorrelationByDeck"
properties="srvns:deck"/>
-</correlationSets>
-
-<variables>
- <variable messageType="srvns:dealDeckRequest"
name="deckRequest"/>
- <variable messageType="srvns:pickSpadeRequest"
name="spadeRequest"/>
- <variable messageType="srvns:pickClubRequest"
name="clubRequest"/>
- <variable messageType="srvns:pickHeartRequest"
name="heartRequest"/>
- <variable messageType="srvns:pickDiamondRequest"
name="diamondRequest"/>
- <variable messageType="srvns:dealDeckResponse"
name="deckResponse"/>
- <variable messageType="srvns:pickSpadeResponse"
name="spadeResponse"/>
- <variable messageType="srvns:pickClubResponse"
name="clubResponse"/>
- <variable messageType="srvns:pickHeartResponse"
name="heartResponse"/>
- <!--
- <variable messageType="srvns:pickDiamondResponse"
name="diamondResponse"/>
- -->
-</variables>
-
-<sequence name="DeckLoop">
- <sequence name="initDeck">
- <receive operation="dealDeck" partnerLink="IncomingLink"
variable="deckRequest" createInstance="yes">
- <correlations>
- <correlation initiate="yes" set="CorrelationByDeck"/>
- </correlations>
- </receive>
- <assign>
- <copy>
- <from><literal>
- <dealDeckResponse
xmlns="http://www.stark.com/PickService"><Deck/></d...
- </literal></from>
- <to variable="deckResponse" part="parameters"/>
- </copy>
- <copy>
- <from>bpel:getVariableProperty("deckRequest",
"srvns:deck")</from>
- <to>$deckResponse.parameters/srvns:Deck</to>
- </copy>
- </assign>
- <reply operation="dealDeck" partnerLink="IncomingLink"
variable="deckResponse"/>
- </sequence>
-
-
-<while><condition>1 = 1</condition>
- <sequence name="pickLoop">
- <pick name="suitPicker">
- <onMessage operation="pickSpade" partnerLink="IncomingLink"
variable="spadeRequest">
- <correlations>
- <correlation initiate="no" set="CorrelationByDeck"/>
- </correlations>
- <sequence>
- <assign>
- <copy>
- <from><literal>
- <pickSpadeResponse
xmlns="http://www.stark.com/PickService"><Deck/></p...
- </literal></from>
- <to variable="spadeResponse" part="parameters"/>
- </copy>
- <copy>
- <from>bpel:getVariableProperty("spadeRequest",
"srvns:deck")</from>
- <to>$spadeResponse.parameters/srvns:Deck</to>
- </copy>
- </assign>
- <reply operation="pickSpade" partnerLink="IncomingLink"
variable="spadeResponse"/>
- </sequence>
- </onMessage>
-
- <onMessage operation="pickClub" partnerLink="IncomingLink"
variable="clubRequest">
- <correlations>
- <correlation initiate="no" set="CorrelationByDeck"/>
- </correlations>
- <sequence>
- <assign>
- <copy>
- <from><literal>
- <pickClubResponse
xmlns="http://www.stark.com/PickService"><Deck/></p...
- </literal></from>
- <to variable="clubResponse" part="parameters"/>
- </copy>
- <copy>
- <from>bpel:getVariableProperty("clubRequest",
"srvns:deck")</from>
- <to>$clubResponse.parameters/srvns:Deck</to>
- </copy>
- </assign>
- <reply operation="pickClub" partnerLink="IncomingLink"
variable="clubResponse"/>
- </sequence>
- </onMessage>
-
- <onMessage operation="pickHeart" partnerLink="IncomingLink"
variable="heartRequest">
- <correlations>
- <correlation initiate="no" set="CorrelationByDeck"/>
- </correlations>
- <sequence>
- <assign>
- <copy>
- <from><literal>
- <pickHeartResponse
xmlns="http://www.stark.com/PickService"><Deck/></p...
- </literal></from>
- <to variable="heartResponse" part="parameters"/>
- </copy>
- <copy>
- <from>bpel:getVariableProperty("heartRequest",
"srvns:deck")</from>
- <to>$heartResponse.parameters/srvns:Deck</to>
- </copy>
- </assign>
- <reply operation="pickHeart" partnerLink="IncomingLink"
variable="heartResponse"/>
- </sequence>
- </onMessage>
-
- <onMessage operation="pickDiamond"
partnerLink="IncomingLink" variable="diamondRequest">
- <correlations>
- <correlation initiate="no" set="CorrelationByDeck"/>
- </correlations>
- <sequence>
- <empty/>
- <!--
- <assign>
- <copy>
- <from><literal>
- <pickDiamondResponse
xmlns="http://www.stark.com/PickService"><Deck/></p...
- </literal></from>
- <to variable="diamondResponse" part="parameters"/>
- </copy>
- <copy>
- <from>bpel:getVariableProperty("diamondRequest",
"srvns:deck")</from>
- <to>$diamondResponse.parameters/srvns:Deck</to>
- </copy>
- </assign>
- <reply operation="pickDiamond" partnerLink="IncomingLink"
variable="diamondResponse"/>
- -->
- </sequence>
- </onMessage>
- </pick>
- </sequence>
-</while>
-</sequence>
-
-</process>
+
+<process name="PickProcess" suppressJoinFailure="yes"
exitOnStandardFault="no"
+
xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+
xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
+
xmlns:srvns="http://www.stark.com/PickService"
+
xmlns:tns="http://www.stark.com/PickProcess"
+
targetNamespace="http://emcs/www.stark.com/PickProcess">
+
+ <import
importType="http://schemas.xmlsoap.org/wsdl/"
location="PickService.wsdl"
namespace="http://www.stark.com/PickService"/>
+
+<partnerLinks>
+ <partnerLink name="IncomingLink" myRole="PickServiceProvider"
partnerLinkType="srvns:PickServicePLT"/>
+</partnerLinks>
+
+<correlationSets>
+ <correlationSet name="CorrelationByDeck"
properties="srvns:deck"/>
+</correlationSets>
+
+<variables>
+ <variable messageType="srvns:dealDeckRequest"
name="deckRequest"/>
+ <variable messageType="srvns:pickSpadeRequest"
name="spadeRequest"/>
+ <variable messageType="srvns:pickClubRequest"
name="clubRequest"/>
+ <variable messageType="srvns:pickHeartRequest"
name="heartRequest"/>
+ <variable messageType="srvns:pickDiamondRequest"
name="diamondRequest"/>
+ <variable messageType="srvns:dealDeckResponse"
name="deckResponse"/>
+ <variable messageType="srvns:pickSpadeResponse"
name="spadeResponse"/>
+ <variable messageType="srvns:pickClubResponse"
name="clubResponse"/>
+ <variable messageType="srvns:pickHeartResponse"
name="heartResponse"/>
+ <!--
+ <variable messageType="srvns:pickDiamondResponse"
name="diamondResponse"/>
+ -->
+</variables>
+
+<sequence name="DeckLoop">
+ <sequence name="initDeck">
+ <receive operation="dealDeck" partnerLink="IncomingLink"
variable="deckRequest" createInstance="yes">
+ <correlations>
+ <correlation initiate="yes" set="CorrelationByDeck"/>
+ </correlations>
+ </receive>
+ <assign>
+ <copy>
+ <from><literal>
+ <dealDeckResponse
xmlns="http://www.stark.com/PickService"><Deck/></d...
+ </literal></from>
+ <to variable="deckResponse" part="parameters"/>
+ </copy>
+ <copy>
+ <from>bpel:getVariableProperty("deckRequest",
"srvns:deck")</from>
+ <to>$deckResponse.parameters/srvns:Deck</to>
+ </copy>
+ </assign>
+ <reply operation="dealDeck" partnerLink="IncomingLink"
variable="deckResponse"/>
+ </sequence>
+
+
+<while><condition>1 = 1</condition>
+ <sequence name="pickLoop">
+ <pick name="suitPicker">
+ <onMessage operation="pickSpade" partnerLink="IncomingLink"
variable="spadeRequest">
+ <correlations>
+ <correlation initiate="no" set="CorrelationByDeck"/>
+ </correlations>
+ <sequence>
+ <assign>
+ <copy>
+ <from><literal>
+ <pickSpadeResponse
xmlns="http://www.stark.com/PickService"><Deck/></p...
+ </literal></from>
+ <to variable="spadeResponse" part="parameters"/>
+ </copy>
+ <copy>
+ <from>bpel:getVariableProperty("spadeRequest",
"srvns:deck")</from>
+ <to>$spadeResponse.parameters/srvns:Deck</to>
+ </copy>
+ </assign>
+ <reply operation="pickSpade" partnerLink="IncomingLink"
variable="spadeResponse"/>
+ </sequence>
+ </onMessage>
+
+ <onMessage operation="pickClub" partnerLink="IncomingLink"
variable="clubRequest">
+ <correlations>
+ <correlation initiate="no" set="CorrelationByDeck"/>
+ </correlations>
+ <sequence>
+ <assign>
+ <copy>
+ <from><literal>
+ <pickClubResponse
xmlns="http://www.stark.com/PickService"><Deck/></p...
+ </literal></from>
+ <to variable="clubResponse" part="parameters"/>
+ </copy>
+ <copy>
+ <from>bpel:getVariableProperty("clubRequest",
"srvns:deck")</from>
+ <to>$clubResponse.parameters/srvns:Deck</to>
+ </copy>
+ </assign>
+ <reply operation="pickClub" partnerLink="IncomingLink"
variable="clubResponse"/>
+ </sequence>
+ </onMessage>
+
+ <onMessage operation="pickHeart" partnerLink="IncomingLink"
variable="heartRequest">
+ <correlations>
+ <correlation initiate="no" set="CorrelationByDeck"/>
+ </correlations>
+ <sequence>
+ <assign>
+ <copy>
+ <from><literal>
+ <pickHeartResponse
xmlns="http://www.stark.com/PickService"><Deck/></p...
+ </literal></from>
+ <to variable="heartResponse" part="parameters"/>
+ </copy>
+ <copy>
+ <from>bpel:getVariableProperty("heartRequest",
"srvns:deck")</from>
+ <to>$heartResponse.parameters/srvns:Deck</to>
+ </copy>
+ </assign>
+ <reply operation="pickHeart" partnerLink="IncomingLink"
variable="heartResponse"/>
+ </sequence>
+ </onMessage>
+
+ <onMessage operation="pickDiamond"
partnerLink="IncomingLink" variable="diamondRequest">
+ <correlations>
+ <correlation initiate="no" set="CorrelationByDeck"/>
+ </correlations>
+ <sequence>
+ <empty/>
+ <!--
+ <assign>
+ <copy>
+ <from><literal>
+ <pickDiamondResponse
xmlns="http://www.stark.com/PickService"><Deck/></p...
+ </literal></from>
+ <to variable="diamondResponse" part="parameters"/>
+ </copy>
+ <copy>
+ <from>bpel:getVariableProperty("diamondRequest",
"srvns:deck")</from>
+ <to>$diamondResponse.parameters/srvns:Deck</to>
+ </copy>
+ </assign>
+ <reply operation="pickDiamond" partnerLink="IncomingLink"
variable="diamondResponse"/>
+ -->
+ </sequence>
+ </onMessage>
+ </pick>
+ </sequence>
+</while>
+</sequence>
+
+</process>
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/PickService.wsdl
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/PickService.wsdl 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/PickService.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -16,159 +16,159 @@
~ specific language governing permissions and limitations
~ under the License.
-->
-
-<wsdl:definitions
-
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
-
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
-
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
-
xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop"
-
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
-
xmlns:tns="http://www.stark.com/PickService"
-
targetNamespace="http://www.stark.com/PickService">
-
-<wsdl:types>
- <xsd:schema
targetNamespace="http://www.stark.com/PickService"
elementFormDefault="qualified">
- <xsd:complexType name="DeckType">
- <xsd:sequence>
- <xsd:element name="Deck" type="xsd:token"/>
- </xsd:sequence>
- </xsd:complexType>
-
- <xsd:element name="dealDeck" type="tns:DeckType"/>
- <xsd:element name="dealDeckResponse" type="tns:DeckType"/>
-
- <xsd:element name="pickSpade" type="tns:DeckType"/>
- <xsd:element name="pickSpadeResponse"
type="tns:DeckType"/>
-
- <xsd:element name="pickClub" type="tns:DeckType"/>
- <xsd:element name="pickClubResponse" type="tns:DeckType"/>
-
- <xsd:element name="pickHeart" type="tns:DeckType"/>
- <xsd:element name="pickHeartResponse"
type="tns:DeckType"/>
-
- <xsd:element name="pickDiamond" type="tns:DeckType"/>
- <xsd:element name="pickDiamondResponse"
type="tns:DeckType"/>
- </xsd:schema>
-</wsdl:types>
-
-<wsdl:message name="dealDeckRequest">
- <wsdl:part element="tns:dealDeck" name="parameters"/>
-</wsdl:message>
-<wsdl:message name="dealDeckResponse">
- <wsdl:part element="tns:dealDeckResponse"
name="parameters"/>
-</wsdl:message>
-
-<wsdl:message name="pickSpadeRequest">
- <wsdl:part element="tns:pickSpade" name="parameters"/>
-</wsdl:message>
-<wsdl:message name="pickSpadeResponse">
- <wsdl:part element="tns:pickSpadeResponse"
name="parameters"/>
-</wsdl:message>
-
-<wsdl:message name="pickClubRequest">
- <wsdl:part element="tns:pickClub" name="parameters"/>
-</wsdl:message>
-<wsdl:message name="pickClubResponse">
- <wsdl:part element="tns:pickClubResponse"
name="parameters"/>
-</wsdl:message>
-
-<wsdl:message name="pickHeartRequest">
- <wsdl:part element="tns:pickHeart" name="parameters"/>
-</wsdl:message>
-<wsdl:message name="pickHeartResponse">
- <wsdl:part element="tns:pickHeartResponse"
name="parameters"/>
-</wsdl:message>
-
-<wsdl:message name="pickDiamondRequest">
- <wsdl:part element="tns:pickDiamond" name="parameters"/>
-</wsdl:message>
-<!--
-<wsdl:message name="pickDiamondResponse">
- <wsdl:part element="tns:pickDiamondResponse"
name="parameters"/>
-</wsdl:message>
--->
-
-<wsdl:portType name="PickService">
- <wsdl:operation name="dealDeck">
- <wsdl:input message="tns:dealDeckRequest"/>
- <wsdl:output message="tns:dealDeckResponse"/>
- </wsdl:operation>
- <wsdl:operation name="pickSpade">
- <wsdl:input message="tns:pickSpadeRequest"/>
- <wsdl:output message="tns:pickSpadeResponse"/>
- </wsdl:operation>
- <wsdl:operation name="pickClub">
- <wsdl:input message="tns:pickClubRequest"/>
- <wsdl:output message="tns:pickClubResponse"/>
- </wsdl:operation>
- <wsdl:operation name="pickHeart">
- <wsdl:input message="tns:pickHeartRequest"/>
- <wsdl:output message="tns:pickHeartResponse"/>
- </wsdl:operation>
- <wsdl:operation name="pickDiamond">
- <wsdl:input message="tns:pickDiamondRequest"/>
- <!--
- <wsdl:output message="tns:pickDiamondResponse"/>
- -->
- </wsdl:operation>
-</wsdl:portType>
-
-<wsdl:binding name="PickServiceSoapBinding"
type="tns:PickService">
- <soap:binding style="document"
transport="http://schemas.xmlsoap.org/soap/http"/>
- <wsdl:operation name="dealDeck">
- <soap:operation
soapAction="http://www.stark.com/PickService/dealDeck"/>
- <wsdl:input> <soap:body parts="parameters"
use="literal"/> </wsdl:input>
- <wsdl:output> <soap:body parts="parameters"
use="literal"/> </wsdl:output>
- </wsdl:operation>
- <wsdl:operation name="pickSpade">
- <soap:operation
soapAction="http://www.stark.com/PickService/pickSpade"/>
- <wsdl:input> <soap:body parts="parameters"
use="literal"/> </wsdl:input>
- <wsdl:output> <soap:body parts="parameters"
use="literal"/> </wsdl:output>
- </wsdl:operation>
- <wsdl:operation name="pickClub">
- <soap:operation
soapAction="http://www.stark.com/PickService/pickClub"/>
- <wsdl:input> <soap:body parts="parameters"
use="literal"/> </wsdl:input>
- <wsdl:output> <soap:body parts="parameters"
use="literal"/> </wsdl:output>
- </wsdl:operation>
- <wsdl:operation name="pickHeart">
- <soap:operation
soapAction="http://www.stark.com/PickService/pickHeart"/>
- <wsdl:input> <soap:body parts="parameters"
use="literal"/> </wsdl:input>
- <wsdl:output> <soap:body parts="parameters"
use="literal"/> </wsdl:output>
- </wsdl:operation>
- <wsdl:operation name="pickDiamond">
- <soap:operation
soapAction="http://www.stark.com/PickService/pickDiamond"/>
- <wsdl:input> <soap:body parts="parameters"
use="literal"/> </wsdl:input>
- <!--
- <wsdl:output> <soap:body parts="parameters"
use="literal"/> </wsdl:output>
- -->
- </wsdl:operation>
-</wsdl:binding>
-
-<wsdl:service name="PickService">
- <wsdl:port name="PickServiceSoapPort"
binding="tns:PickServiceSoapBinding">
- <soap:address
location="http://localhost:8080/ode/processes/PickService"/>
- </wsdl:port>
-</wsdl:service>
-
-<plnk:partnerLinkType name="PickServicePLT">
- <plnk:role name="PickServiceProvider"
portType="tns:PickService"/>
-</plnk:partnerLinkType>
-
-<vprop:property name="deck" type="xsd:token"/>
-<vprop:propertyAlias messageType="tns:dealDeckRequest"
part="parameters" propertyName="tns:deck">
- <vprop:query>tns:Deck</vprop:query>
-</vprop:propertyAlias>
-<vprop:propertyAlias messageType="tns:pickSpadeRequest"
part="parameters" propertyName="tns:deck">
- <vprop:query>tns:Deck</vprop:query>
-</vprop:propertyAlias>
-<vprop:propertyAlias messageType="tns:pickClubRequest"
part="parameters" propertyName="tns:deck">
- <vprop:query>tns:Deck</vprop:query>
-</vprop:propertyAlias>
-<vprop:propertyAlias messageType="tns:pickHeartRequest"
part="parameters" propertyName="tns:deck">
- <vprop:query>tns:Deck</vprop:query>
-</vprop:propertyAlias>
-<vprop:propertyAlias messageType="tns:pickDiamondRequest"
part="parameters" propertyName="tns:deck">
- <vprop:query>tns:Deck</vprop:query>
-</vprop:propertyAlias>
-
-</wsdl:definitions>
+
+<wsdl:definitions
+
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+
xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns:tns="http://www.stark.com/PickService"
+
targetNamespace="http://www.stark.com/PickService">
+
+<wsdl:types>
+ <xsd:schema
targetNamespace="http://www.stark.com/PickService"
elementFormDefault="qualified">
+ <xsd:complexType name="DeckType">
+ <xsd:sequence>
+ <xsd:element name="Deck" type="xsd:token"/>
+ </xsd:sequence>
+ </xsd:complexType>
+
+ <xsd:element name="dealDeck" type="tns:DeckType"/>
+ <xsd:element name="dealDeckResponse" type="tns:DeckType"/>
+
+ <xsd:element name="pickSpade" type="tns:DeckType"/>
+ <xsd:element name="pickSpadeResponse"
type="tns:DeckType"/>
+
+ <xsd:element name="pickClub" type="tns:DeckType"/>
+ <xsd:element name="pickClubResponse" type="tns:DeckType"/>
+
+ <xsd:element name="pickHeart" type="tns:DeckType"/>
+ <xsd:element name="pickHeartResponse"
type="tns:DeckType"/>
+
+ <xsd:element name="pickDiamond" type="tns:DeckType"/>
+ <xsd:element name="pickDiamondResponse"
type="tns:DeckType"/>
+ </xsd:schema>
+</wsdl:types>
+
+<wsdl:message name="dealDeckRequest">
+ <wsdl:part element="tns:dealDeck" name="parameters"/>
+</wsdl:message>
+<wsdl:message name="dealDeckResponse">
+ <wsdl:part element="tns:dealDeckResponse"
name="parameters"/>
+</wsdl:message>
+
+<wsdl:message name="pickSpadeRequest">
+ <wsdl:part element="tns:pickSpade" name="parameters"/>
+</wsdl:message>
+<wsdl:message name="pickSpadeResponse">
+ <wsdl:part element="tns:pickSpadeResponse"
name="parameters"/>
+</wsdl:message>
+
+<wsdl:message name="pickClubRequest">
+ <wsdl:part element="tns:pickClub" name="parameters"/>
+</wsdl:message>
+<wsdl:message name="pickClubResponse">
+ <wsdl:part element="tns:pickClubResponse"
name="parameters"/>
+</wsdl:message>
+
+<wsdl:message name="pickHeartRequest">
+ <wsdl:part element="tns:pickHeart" name="parameters"/>
+</wsdl:message>
+<wsdl:message name="pickHeartResponse">
+ <wsdl:part element="tns:pickHeartResponse"
name="parameters"/>
+</wsdl:message>
+
+<wsdl:message name="pickDiamondRequest">
+ <wsdl:part element="tns:pickDiamond" name="parameters"/>
+</wsdl:message>
+<!--
+<wsdl:message name="pickDiamondResponse">
+ <wsdl:part element="tns:pickDiamondResponse"
name="parameters"/>
+</wsdl:message>
+-->
+
+<wsdl:portType name="PickService">
+ <wsdl:operation name="dealDeck">
+ <wsdl:input message="tns:dealDeckRequest"/>
+ <wsdl:output message="tns:dealDeckResponse"/>
+ </wsdl:operation>
+ <wsdl:operation name="pickSpade">
+ <wsdl:input message="tns:pickSpadeRequest"/>
+ <wsdl:output message="tns:pickSpadeResponse"/>
+ </wsdl:operation>
+ <wsdl:operation name="pickClub">
+ <wsdl:input message="tns:pickClubRequest"/>
+ <wsdl:output message="tns:pickClubResponse"/>
+ </wsdl:operation>
+ <wsdl:operation name="pickHeart">
+ <wsdl:input message="tns:pickHeartRequest"/>
+ <wsdl:output message="tns:pickHeartResponse"/>
+ </wsdl:operation>
+ <wsdl:operation name="pickDiamond">
+ <wsdl:input message="tns:pickDiamondRequest"/>
+ <!--
+ <wsdl:output message="tns:pickDiamondResponse"/>
+ -->
+ </wsdl:operation>
+</wsdl:portType>
+
+<wsdl:binding name="PickServiceSoapBinding"
type="tns:PickService">
+ <soap:binding style="document"
transport="http://schemas.xmlsoap.org/soap/http"/>
+ <wsdl:operation name="dealDeck">
+ <soap:operation
soapAction="http://www.stark.com/PickService/dealDeck"/>
+ <wsdl:input> <soap:body parts="parameters"
use="literal"/> </wsdl:input>
+ <wsdl:output> <soap:body parts="parameters"
use="literal"/> </wsdl:output>
+ </wsdl:operation>
+ <wsdl:operation name="pickSpade">
+ <soap:operation
soapAction="http://www.stark.com/PickService/pickSpade"/>
+ <wsdl:input> <soap:body parts="parameters"
use="literal"/> </wsdl:input>
+ <wsdl:output> <soap:body parts="parameters"
use="literal"/> </wsdl:output>
+ </wsdl:operation>
+ <wsdl:operation name="pickClub">
+ <soap:operation
soapAction="http://www.stark.com/PickService/pickClub"/>
+ <wsdl:input> <soap:body parts="parameters"
use="literal"/> </wsdl:input>
+ <wsdl:output> <soap:body parts="parameters"
use="literal"/> </wsdl:output>
+ </wsdl:operation>
+ <wsdl:operation name="pickHeart">
+ <soap:operation
soapAction="http://www.stark.com/PickService/pickHeart"/>
+ <wsdl:input> <soap:body parts="parameters"
use="literal"/> </wsdl:input>
+ <wsdl:output> <soap:body parts="parameters"
use="literal"/> </wsdl:output>
+ </wsdl:operation>
+ <wsdl:operation name="pickDiamond">
+ <soap:operation
soapAction="http://www.stark.com/PickService/pickDiamond"/>
+ <wsdl:input> <soap:body parts="parameters"
use="literal"/> </wsdl:input>
+ <!--
+ <wsdl:output> <soap:body parts="parameters"
use="literal"/> </wsdl:output>
+ -->
+ </wsdl:operation>
+</wsdl:binding>
+
+<wsdl:service name="PickService">
+ <wsdl:port name="PickServiceSoapPort"
binding="tns:PickServiceSoapBinding">
+ <soap:address
location="http://localhost:8080/ode/processes/PickService"/>
+ </wsdl:port>
+</wsdl:service>
+
+<plnk:partnerLinkType name="PickServicePLT">
+ <plnk:role name="PickServiceProvider"
portType="tns:PickService"/>
+</plnk:partnerLinkType>
+
+<vprop:property name="deck" type="xsd:token"/>
+<vprop:propertyAlias messageType="tns:dealDeckRequest"
part="parameters" propertyName="tns:deck">
+ <vprop:query>tns:Deck</vprop:query>
+</vprop:propertyAlias>
+<vprop:propertyAlias messageType="tns:pickSpadeRequest"
part="parameters" propertyName="tns:deck">
+ <vprop:query>tns:Deck</vprop:query>
+</vprop:propertyAlias>
+<vprop:propertyAlias messageType="tns:pickClubRequest"
part="parameters" propertyName="tns:deck">
+ <vprop:query>tns:Deck</vprop:query>
+</vprop:propertyAlias>
+<vprop:propertyAlias messageType="tns:pickHeartRequest"
part="parameters" propertyName="tns:deck">
+ <vprop:query>tns:Deck</vprop:query>
+</vprop:propertyAlias>
+<vprop:propertyAlias messageType="tns:pickDiamondRequest"
part="parameters" propertyName="tns:deck">
+ <vprop:query>tns:Deck</vprop:query>
+</vprop:propertyAlias>
+
+</wsdl:definitions>
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/dealDeck.xml
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/dealDeck.xml 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/dealDeck.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -17,12 +17,12 @@
~ under the License.
-->
-<soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:pic="http://www.stark.com/PickService">
- <soapenv:Header/>
- <soapenv:Body>
- <pic:dealDeck>
- <pic:Deck>One</pic:Deck>
- </pic:dealDeck>
- </soapenv:Body>
-</soapenv:Envelope>
-
+<soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:pic="http://www.stark.com/PickService">
+ <soapenv:Header/>
+ <soapenv:Body>
+ <pic:dealDeck>
+ <pic:Deck>One</pic:Deck>
+ </pic:dealDeck>
+ </soapenv:Body>
+</soapenv:Envelope>
+
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/deploy.xml
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/deploy.xml 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/deploy.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -17,14 +17,14 @@
~ under the License.
-->
-<deploy
xmlns="http://www.apache.org/ode/schemas/dd/2007/03"
-
xmlns:srvns="http://www.stark.com/PickService"
-
xmlns:procns="http://emcs/www.stark.com/PickProcess">
-
- <process name="procns:PickProcess">
- <provide partnerLink="IncomingLink">
- <service name="srvns:PickService"
port="PickServiceSoapPort"/>
- </provide>
- <cleanup on="always"/>
- </process>
-</deploy>
+<deploy
xmlns="http://www.apache.org/ode/schemas/dd/2007/03"
+
xmlns:srvns="http://www.stark.com/PickService"
+
xmlns:procns="http://emcs/www.stark.com/PickProcess">
+
+ <process name="procns:PickProcess">
+ <provide partnerLink="IncomingLink">
+ <service name="srvns:PickService"
port="PickServiceSoapPort"/>
+ </provide>
+ <cleanup on="always"/>
+ </process>
+</deploy>
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/pickClub.xml
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/pickClub.xml 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/pickClub.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -17,12 +17,12 @@
~ under the License.
-->
-<soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:pic="http://www.stark.com/PickService">
- <soapenv:Header/>
- <soapenv:Body>
- <pic:pickClub>
- <pic:Deck>One</pic:Deck>
- </pic:pickClub>
- </soapenv:Body>
-</soapenv:Envelope>
-
+<soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:pic="http://www.stark.com/PickService">
+ <soapenv:Header/>
+ <soapenv:Body>
+ <pic:pickClub>
+ <pic:Deck>One</pic:Deck>
+ </pic:pickClub>
+ </soapenv:Body>
+</soapenv:Envelope>
+
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/pickDiamond.xml
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/pickDiamond.xml 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/pickDiamond.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -17,12 +17,12 @@
~ under the License.
-->
-<soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:pic="http://www.stark.com/PickService">
- <soapenv:Header/>
- <soapenv:Body>
- <pic:pickDiamond>
- <pic:Deck>One</pic:Deck>
- </pic:pickDiamond>
- </soapenv:Body>
-</soapenv:Envelope>
-
+<soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:pic="http://www.stark.com/PickService">
+ <soapenv:Header/>
+ <soapenv:Body>
+ <pic:pickDiamond>
+ <pic:Deck>One</pic:Deck>
+ </pic:pickDiamond>
+ </soapenv:Body>
+</soapenv:Envelope>
+
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/pickHeart.xml
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/pickHeart.xml 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/pickHeart.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -17,12 +17,12 @@
~ under the License.
-->
-<soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:pic="http://www.stark.com/PickService">
- <soapenv:Header/>
- <soapenv:Body>
- <pic:pickHeart>
- <pic:Deck>One</pic:Deck>
- </pic:pickHeart>
- </soapenv:Body>
-</soapenv:Envelope>
-
+<soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:pic="http://www.stark.com/PickService">
+ <soapenv:Header/>
+ <soapenv:Body>
+ <pic:pickHeart>
+ <pic:Deck>One</pic:Deck>
+ </pic:pickHeart>
+ </soapenv:Body>
+</soapenv:Envelope>
+
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/pickSpade.xml
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/pickSpade.xml 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestPickOneWay/pickSpade.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -17,12 +17,12 @@
~ under the License.
-->
-<soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:pic="http://www.stark.com/PickService">
- <soapenv:Header/>
- <soapenv:Body>
- <pic:pickSpade>
- <pic:Deck>One</pic:Deck>
- </pic:pickSpade>
- </soapenv:Body>
-</soapenv:Envelope>
-
+<soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:pic="http://www.stark.com/PickService">
+ <soapenv:Header/>
+ <soapenv:Body>
+ <pic:pickSpade>
+ <pic:Deck>One</pic:Deck>
+ </pic:pickSpade>
+ </soapenv:Body>
+</soapenv:Envelope>
+
Modified:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestXQueryExpression/HelloXQueryWorld.bpel
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestXQueryExpression/HelloXQueryWorld.bpel 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestXQueryExpression/HelloXQueryWorld.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -46,6 +46,9 @@
<variable name="stringVar" type="xsd:string"/>
<variable name="boolVar" type="xsd:boolean"/>
<variable name="i" type="xsd:int"/>
+ <variable name="myVar2"
messageType="test:HelloXQueryMessage"/>
+ <variable name="date1" type="xsd:date"/>
+ <variable name="dateTime1" type="xsd:dateTime"/>
</variables>
<sequence>
@@ -61,6 +64,43 @@
operation="HelloXQuery"
variable="myVar"
createInstance="yes"/>
+
+ <bpws:assign>
+ <copy>
+ <from>''</from>
+ <to variable="date1"/>
+ </copy>
+ </bpws:assign>
+ <if>
+ <condition>not(empty($date1))</condition>
+ <throw faultName="error"/>
+ </if>
+
+ <bpws:assign>
+ <copy>
+ <from>'2009-01-01'</from>
+ <to variable="date1"/>
+ </copy>
+ <copy>
+ <from>'2009-01-02T12:32:32'</from>
+ <to variable="dateTime1"/>
+ </copy>
+ <copy>
+ <bpws:from
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xquery1.0">
+ <![CDATA[
+ <test:test1
xmlns:test="http://test.org">
+ <test:test2>{ if
(string-length(xsd:string($date1)) != 0) then $date1 else $dateTime1 }</test:test2>
+ </test:test1>
+ ]]>
+ </bpws:from>
+ <to variable="myVar2" part="TestPart"/>
+ </copy>
+ </bpws:assign>
+ <if>
+ <condition>not($myVar2.TestPart/*/text() eq
'2009-01-01')</condition>
+ <throw faultName="error"/>
+ </if>
+
<assign name="assign1">
<copy>
<from variable="myVar" part="TestPart"/>
@@ -186,6 +226,12 @@
<throw faultName="selectionFailure"/>
</if>
+ <!-- validate that you can invoke XSLT stylesheets from withing XQuery -->
+ <if>
+ <condition
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xquery1.0">not(string-length(string(bpws:doXslTransform('HelloXQueryWorld.xsl',
$myVar.TestPart))) > 0)</condition>
+ <throw faultName="selectionFailure"/>
+ </if>
+
<assign>
<copy>
<from>$i + 1</from>
Added:
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestXQueryExpression/HelloXQueryWorld.xsl
===================================================================
---
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestXQueryExpression/HelloXQueryWorld.xsl
(rev 0)
+++
branches/ODE/ODE-1.x/bpel-test/src/test/resources/bpel/2.0/TestXQueryExpression/HelloXQueryWorld.xsl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,13 @@
+<xsl:stylesheet
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+
xmlns="http://www.example.org/ProcessData"
+
xmlns:tns="http://www.example.org/ProcessData"
+ version="1.0">
+ <xsl:output method="xml" indent="yes"/>
+
+ <xsl:template match="/">
+ <root>
+ <xsl:text>Hello World</xsl:text>
+ </root>
+ </xsl:template>
+
+</xsl:stylesheet>
\ No newline at end of file
Modified: branches/ODE/ODE-1.x/bpel-test/src/test/resources/log4j.properties
===================================================================
--- branches/ODE/ODE-1.x/bpel-test/src/test/resources/log4j.properties 2010-04-14 15:43:12
UTC (rev 619)
+++ branches/ODE/ODE-1.x/bpel-test/src/test/resources/log4j.properties 2010-04-14 18:25:55
UTC (rev 620)
@@ -27,12 +27,14 @@
log4j.category.org.apache.ode.bpel.epr=INFO
log4j.category.org.apache.ode.bpel.extvar.jdbc=DEBUG
log4j.category.org.apache.ode.bpel.runtime=DEBUG
+log4j.category.org.apache.ode=DEBUG
log4j.category.org.apache.ode.daohib.bpel.CorrelatorDaoImpl=DEBUG
+log4j.category.org.apache.ode.bpel.engine.OutstandingRequestManager=TRACE
# Console appender
-log4j.appender.CONSOLE=org.apache.log4j.ConsoleAppender
-log4j.appender.CONSOLE.layout=org.apache.log4j.PatternLayout
-log4j.appender.CONSOLE.layout.ConversionPattern=%p - %C{1}.%M(%L) | %m%n
+#log4j.appender.CONSOLE=org.apache.log4j.ConsoleAppender
+#log4j.appender.CONSOLE.layout=org.apache.log4j.PatternLayout
+#log4j.appender.CONSOLE.layout.ConversionPattern=%p - %C{1}.%M(%L) | %m%n
log4j.appender.FILE=org.apache.log4j.FileAppender
log4j.appender.FILE.File=target/bpel-test.log
Added: branches/ODE/ODE-1.x/dao-hibernate/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/dao-hibernate/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/dao-hibernate/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,121 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-dao-hibernate</artifactId>
+ <name>ODE :: Hibernate DAO Implementation</name>
+ <packaging>jar</packaging>
+ <modelVersion>4.0.0</modelVersion>
+
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-dao</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-ql</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-epr</artifactId>
+ <version>${project.version}</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>hsqldb</groupId>
+ <artifactId>hsqldb</artifactId>
+ <scope>test</scope>
+ </dependency>
+
+ <dependency>
+ <groupId>org.hibernate</groupId>
+ <artifactId>hibernate</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-log4j12</artifactId>
+ <version>${slf4j.version}</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>xdoclet-maven-plugin</artifactId>
+ <executions>
+ <execution>
+ <phase>generate-sources</phase>
+ <goals>
+ <goal>xdoclet</goal>
+ </goals>
+ <configuration>
+ <tasks>
+ <hibernatedoclet excludedTags="@version,@author,@todo"
verbose="true"
+ destdir="${project.build.outputDirectory}"
force="true">
+ <hibernate version="3.0"/>
+ <fileset dir="${project.build.sourceDirectory}"
includes="org/apache/ode/daohib/bpel/hobj/*.java"/>
+ </hibernatedoclet>
+ </tasks>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ <plugin>
+ <!--doclet does not support not-found="ignore" -->
+ <groupId>org.codehaus.groovy.maven</groupId>
+ <artifactId>gmaven-plugin</artifactId>
+ <executions>
+ <execution>
+ <phase>process-sources</phase>
+ <goals>
+ <goal>execute</goal>
+ </goals>
+ <configuration>
+ <source>
+ import java.io.File
+ def process_instance_hbm_file = new
File('${project.build.outputDirectory}',
'org/apache/ode/daohib/bpel/hobj/HProcessInstance.hbm.xml')
+ def contents = process_instance_hbm_file.text
+ if (!contents.contains('not-found="ignore"')) {
+ process_instance_hbm_file.text =
contents.replace('class="org.apache.ode.daohib.bpel.hobj.HProcess"',
+ 'not-found="ignore"
class="org.apache.ode.daohib.bpel.hobj.HProcess"')
+ }
+ </source>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+</project>
Added:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/NativeHiLoGenerator.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/NativeHiLoGenerator.java
(rev 0)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/NativeHiLoGenerator.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,94 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.ode.daohib;
+
+import java.io.Serializable;
+import java.util.Properties;
+
+import org.hibernate.HibernateException;
+import org.hibernate.MappingException;
+import org.hibernate.dialect.Dialect;
+import org.hibernate.engine.SessionImplementor;
+import org.hibernate.id.Configurable;
+import org.hibernate.id.IdentifierGenerator;
+import org.hibernate.id.PersistentIdentifierGenerator;
+import org.hibernate.id.SequenceHiLoGenerator;
+import org.hibernate.id.TableHiLoGenerator;
+import org.hibernate.type.Type;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+public class NativeHiLoGenerator implements IdentifierGenerator,
PersistentIdentifierGenerator, Configurable {
+ private static final Log __log = LogFactory.getLog(NativeHiLoGenerator.class);
+ private IdentifierGenerator _proxy;
+
+ public NativeHiLoGenerator() {
+ super();
+ }
+
+ public Serializable generate(SessionImplementor session, Object object) throws
HibernateException {
+ return _proxy.generate(session, object);
+ }
+
+ public Object generatorKey() {
+ if (_proxy instanceof PersistentIdentifierGenerator)
+ return ((PersistentIdentifierGenerator) _proxy).generatorKey();
+ else
+ return this;
+ }
+
+ public String[] sqlCreateStrings(Dialect dialect) throws HibernateException {
+ if (_proxy instanceof PersistentIdentifierGenerator)
+ return ((PersistentIdentifierGenerator) _proxy).sqlCreateStrings(dialect);
+ else
+ return new String[] {};
+ }
+
+ public String[] sqlDropStrings(Dialect dialect) throws HibernateException {
+ if (_proxy instanceof PersistentIdentifierGenerator)
+ return ((PersistentIdentifierGenerator) _proxy).sqlDropStrings(dialect);
+ else
+ return null;
+ }
+
+ public void configure(Type type, Properties params, Dialect dialect) throws
MappingException {
+ Class generatorClass = null;
+ if (dialect.supportsSequences()) {
+ __log.debug("Using SequenceHiLoGenerator");
+ generatorClass = SequenceHiLoGenerator.class;
+ } else {
+ generatorClass = TableHiLoGenerator.class;
+ __log.debug("Using native dialect generator " + generatorClass);
+ }
+
+ IdentifierGenerator g = null;
+ try {
+ g = (IdentifierGenerator) generatorClass.newInstance();
+ } catch (Exception e) {
+ throw new MappingException("", e);
+ }
+
+ if (g instanceof Configurable)
+ ((Configurable) g).configure(type, params, dialect);
+
+ this._proxy = g;
+ }
+}
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/SessionManager.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/SessionManager.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/SessionManager.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -139,7 +139,6 @@
.addClass(HBpelEvent.class)
.addClass(HFaultData.class)
.addClass(HActivityRecovery.class)
- .addClass(HLargeData.class)
.addClass(HMessageExchangeProperty.class);
}
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/ActivityRecoveryDaoImpl.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/ActivityRecoveryDaoImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/ActivityRecoveryDaoImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -19,6 +19,9 @@
package org.apache.ode.daohib.bpel;
+import java.io.IOException;
+import java.util.Date;
+
import org.apache.ode.bpel.dao.ActivityRecoveryDAO;
import org.apache.ode.daohib.SessionManager;
import org.apache.ode.daohib.bpel.hobj.HActivityRecovery;
@@ -26,9 +29,6 @@
import org.w3c.dom.Element;
import org.xml.sax.SAXException;
-import java.io.IOException;
-import java.util.Date;
-
/**
* Hibernate based {@link ActivityRecoveryDao} implementation
*/
@@ -56,12 +56,14 @@
public Date getDateTime() {
return _self.getDateTime();
}
-
+
public Element getDetails() {
entering("ActivityRecoveryDaoImpl.getDetails");
- if (_self.getDetails() == null) return null;
+ if (_self.getDetails() == null) {
+ return null;
+ }
try {
- return DOMUtils.stringToDOM(_self.getDetails().getText());
+ return DOMUtils.stringToDOM(_self.getDetails());
} catch (SAXException e) {
throw new RuntimeException(e);
} catch (IOException e) {
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/BpelDAOConnectionImpl.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/BpelDAOConnectionImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/BpelDAOConnectionImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -53,7 +53,6 @@
import org.apache.ode.daohib.SessionManager;
import org.apache.ode.daohib.bpel.hobj.HBpelEvent;
import org.apache.ode.daohib.bpel.hobj.HCorrelationSet;
-import org.apache.ode.daohib.bpel.hobj.HLargeData;
import org.apache.ode.daohib.bpel.hobj.HMessageExchange;
import org.apache.ode.daohib.bpel.hobj.HProcess;
import org.apache.ode.daohib.bpel.hobj.HProcessInstance;
@@ -70,6 +69,7 @@
import org.hibernate.FetchMode;
import org.hibernate.HibernateException;
import org.hibernate.Session;
+import org.hibernate.criterion.DetachedCriteria;
import org.hibernate.criterion.Expression;
import org.hibernate.criterion.Projections;
@@ -92,6 +92,7 @@
public MessageExchangeDAO createMessageExchange(char dir) {
HMessageExchange mex = new HMessageExchange();
mex.setDirection(dir);
+ mex.setInsertTime(new Date(System.currentTimeMillis()));
getSession().save(mex);
return new MessageExchangeDaoImpl(_sm, mex);
}
@@ -191,13 +192,9 @@
@SuppressWarnings("unchecked")
private static List<HProcessInstance> _instanceQueryForList(Session session,
boolean countOnly, InstanceFilter filter) {
- Criteria crit = session.createCriteria(HProcessInstance.class);
CriteriaBuilder cb = new CriteriaBuilder();
- cb.buildCriteria(crit, filter);
- crit.setFetchMode("fault", FetchMode.JOIN);
-
- return crit.list();
+ return cb.buildHQLQuery(session, filter).list();
}
static ProcessInstanceDAO _getInstance(SessionManager sm, Session session, Long iid)
{
@@ -238,9 +235,7 @@
ObjectOutputStream oos = new ObjectOutputStream(bos);
oos.writeObject(event);
oos.flush();
- HLargeData ld = new HLargeData(bos.toByteArray());
- hevent.setData(ld);
- sess.save(ld);
+ hevent.setData(bos.toByteArray());
} catch (Throwable ex) {
// this is really unexpected.
__log.fatal("InternalError: BpelEvent serialization failed.", ex);
@@ -274,7 +269,7 @@
try {
CollectionsX.transformEx(ret, hevents, new UnaryFunctionEx<HBpelEvent,
BpelEvent>() {
public BpelEvent apply(HBpelEvent x) throws Exception {
- return (BpelEvent)
SerializableUtils.toObject(x.getData().getBinary(), BpelEvent.class
+ return (BpelEvent) SerializableUtils.toObject(x.getData(),
BpelEvent.class
.getClassLoader());
}
@@ -311,13 +306,23 @@
if (instances.size() == 0) {
return new HashMap<Long, Collection<CorrelationSetDAO>>();
}
- Long[] iids = new Long[instances.size()];
+ ArrayList<Long> iids = new ArrayList<Long>(instances.size());
int i=0;
for (ProcessInstanceDAO dao: instances) {
- iids[i] = dao.getInstanceId();
+ iids.add(dao.getInstanceId());
i++;
}
- Collection<HCorrelationSet> csets =
getSession().getNamedQuery(HCorrelationSet.SELECT_CORSETS_BY_INSTANCES).setParameterList("instances",
iids).list();
+ Collection<HCorrelationSet> csets = new
ArrayList<HCorrelationSet>();
+ // some databases don't like long lists of values with IN operator
+ // so we select in batches. Oracle 9i, for instance, doesn't support
+ // more than 1000 -- we opt to be conservative.
+ final int batchSize = 100;
+ int index = 0;
+ while (index < iids.size()) {
+ List<Long> subList = iids.subList(index, Math.min(index+batchSize,
iids.size()));
+
csets.addAll(getSession().getNamedQuery(HCorrelationSet.SELECT_CORSETS_BY_INSTANCES).setParameterList("instances",
subList).list());
+ index += batchSize;
+ }
Map<Long, Collection<CorrelationSetDAO>> map = new HashMap<Long,
Collection<CorrelationSetDAO>>();
for (HCorrelationSet cset: csets) {
Long id = cset.getInstance().getId();
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/CorrelatorDaoImpl.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/CorrelatorDaoImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/CorrelatorDaoImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -35,6 +35,7 @@
import org.hibernate.Hibernate;
import org.hibernate.LockMode;
import org.hibernate.Query;
+import org.hibernate.Session;
import javax.xml.namespace.QName;
@@ -46,6 +47,7 @@
/** filter for finding a matching selector. */
private static final String LOCK_SELECTORS = "update from HCorrelatorSelector as
hs set hs.lock = hs.lock+1 where hs.processType = :processType";
+ private static final String CHECK_SELECTORS = "from HCorrelatorSelector as hs
where hs.processType = :processType and hs.correlator.correlatorId = :correlatorId";
private static final String FLTR_SELECTORS = "from HCorrelatorSelector as hs
where hs.processType = :processType and hs.correlator.correlatorId = :correlatorId";
private static final String FLTR_SELECTORS_SUBQUERY = ("from HCorrelatorSelector
as hs where hs.processType = :processType and hs.correlatorId = " +
"(select hc.id from HCorrelator as hc where hc.correlatorId =
:correlatorId )").intern();
@@ -133,6 +135,13 @@
if(__log.isDebugEnabled()) __log.debug(hdr + "found " + routes);
+ // obtain a lock on the correlator to eliminate potential race condition.
+ if(__log.isDebugEnabled()) __log.debug("Obtain record lock on " +
_hobj);
+ Query correlatorLockQuery = getSession().createQuery("from HCorrelator as hc
where id = :id");
+ correlatorLockQuery.setLong("id", _hobj.getId());
+ correlatorLockQuery.setLockMode("hc", LockMode.UPGRADE);
+ correlatorLockQuery.list();
+
return routes;
}
@@ -218,14 +227,13 @@
__log.debug(hdr + "saved " + hsel);
}
- public boolean checkRoute(CorrelationKey ckey) {
+ public boolean checkRoute(CorrelationKeySet correlationKeySet) {
entering("CorrelatorDaoImpl.checkRoute");
- Query lockQry = getSession().createQuery(LOCK_SELECTORS);
- lockQry.setString("ckey", ckey == null ? null :
ckey.toCanonicalString());
- lockQry.setEntity("corr",_hobj);
- lockQry.setReadOnly(true);
- return lockQry.list().isEmpty();
-
+ Query q = getSession().getNamedQuery(HCorrelatorSelector.SELECT_MESSAGE_ROUTE);
+ q.setEntity("corr",_hobj);
+ q.setString("ckey", correlationKeySet.toCanonicalString());
+ q.setReadOnly(true);
+ return q.list().isEmpty();
}
public String getCorrelatorId() {
@@ -240,10 +248,12 @@
entering("CorrelatorDaoImpl.removeRoutes");
String hdr = "removeRoutes(" + routeGroupId + ", iid=" +
target.getInstanceId() + "): ";
__log.debug(hdr);
- Query q = getSession().createQuery(QRY_DELSELECTORS);
+ Session session = getSession();
+ Query q = session.createQuery(QRY_DELSELECTORS);
q.setString(0, routeGroupId); // groupId
q.setEntity(1, ((ProcessInstanceDaoImpl) target).getHibernateObj()); // instance
int updates = q.executeUpdate();
+ session.flush(); // explicit flush to ensure route removed
if (__log.isDebugEnabled())
__log.debug(hdr + "deleted " + updates + " rows");
}
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/CriteriaBuilder.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/CriteriaBuilder.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/CriteriaBuilder.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -19,32 +19,240 @@
package org.apache.ode.daohib.bpel;
+import java.sql.Timestamp;
+import java.text.ParseException;
+import java.util.ArrayList;
+import java.util.Date;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
import org.apache.ode.bpel.common.BpelEventFilter;
import org.apache.ode.bpel.common.Filter;
import org.apache.ode.bpel.common.InstanceFilter;
import org.apache.ode.utils.ISO8601DateParser;
import org.apache.ode.utils.RelativeDateParser;
import org.hibernate.Criteria;
+import org.hibernate.Query;
+import org.hibernate.Session;
import org.hibernate.criterion.Disjunction;
import org.hibernate.criterion.Property;
import org.hibernate.criterion.Restrictions;
-import java.text.ParseException;
-import java.util.Date;
-import java.util.List;
-import java.util.Map;
-
/**
* Class used for converting "filter" objects into Hibernate
* {@link org.hibernate.Criteria} objects.
*/
class CriteriaBuilder {
+ static final Log __log = LogFactory.getLog(CriteriaBuilder.class);
+
+ /**
+ * Build a HQL query from an instance filter.
+ * @param filter filter
+ */
+ Query buildHQLQuery(Session session, InstanceFilter filter) {
+ Map<String, Object> parameters = new HashMap<String, Object>();
+
+ StringBuffer query = new StringBuffer();
+
+ query.append("select pi from HProcessInstance as pi left join fetch pi.fault
");
+
+ if (filter != null) {
+ // Building each clause
+ ArrayList<String> clauses = new ArrayList<String>();
+
+ // iid filter
+ if ( filter.getIidFilter() != null ) {
+ StringBuffer filters = new StringBuffer();
+ List<String> iids = filter.getIidFilter();
+ for (int m = 0; m < iids.size(); m++) {
+ filters.append(" pi.id = :iid").append(m);
+ parameters.put("iid" + m, iids.get(m));
+ if (m < iids.size() - 1) filters.append(" or");
+ }
+ clauses.add(" (" + filters + ")");
+ }
+
+ // pid filter
+ if (filter.getPidFilter() != null) {
+ StringBuffer filters = new StringBuffer();
+ List<String> pids = filter.getPidFilter();
+ String cmp;
+ if (filter.arePidsNegative()) {
+ cmp = " != ";
+ } else {
+ cmp = " = ";
+ }
+ for (int m = 0; m < pids.size(); m++) {
+ filters.append(" pi.process.id ").append(cmp).append("
:pid").append(m);
+ parameters.put("pid" + m, pids.get(m));
+ if (m < pids.size() - 1) filters.append(" or");
+ }
+ clauses.add(" (" + filters + ")");
+ }
+
+ // name filter
+ if (filter.getNameFilter() != null) {
+ clauses.add(" pi.process.typeName like :pname");
+ parameters.put("pname",
filter.getNameFilter().replaceAll("\\*", "%"));
+ }
+
+ // name space filter
+ if (filter.getNamespaceFilter() != null) {
+ clauses.add(" pi.process.typeNamespace like :pnamespace");
+ parameters.put("pnamespace",
filter.getNamespaceFilter().replaceAll("\\*", "%"));
+ }
+
+ // started filter
+ if (filter.getStartedDateFilter() != null) {
+ for ( String ds : filter.getStartedDateFilter() ) {
+ // named parameters not needed as date is parsed and is hence not
+ // prone to HQL injections
+ clauses.add(" pi.created " + dateFilter(ds));
+ }
+ }
+
+ // last-active filter
+ if (filter.getLastActiveDateFilter() != null) {
+ for ( String ds : filter.getLastActiveDateFilter() ) {
+ // named parameters not needed as date is parsed and is hence not
+ // prone to HQL injections
+ clauses.add(" pi.lastActiveTime " + dateFilter(ds));
+ }
+ }
+
+ // status filter
+ if (filter.getStatusFilter() != null) {
+ StringBuffer filters = new StringBuffer();
+ List<Short> states = filter.convertFilterState();
+ for (int m = 0; m < states.size(); m++) {
+ filters.append(" pi.state = :pstate").append(m);
+ parameters.put("pstate" + m, states.get(m));
+ if (m < states.size() - 1) filters.append(" or");
+ }
+ clauses.add(" (" + filters.toString() + ")");
+ }
+
+ // $property filter
+ if (filter.getPropertyValuesFilter() != null) {
+ Map<String,String> props = filter.getPropertyValuesFilter();
+ // join to correlation sets
+ query.append(" inner join pi.correlationSets as cs");
+ int i = 0;
+ for (String propKey : props.keySet()) {
+ i++;
+ // join to props for each prop
+ query.append(" inner join cs.properties as csp"+i);
+ // add clause for prop key and value
+
+ // spaces have to be escaped, might be better handled in
InstanceFilter
+ String value = props.get(propKey).replaceAll(" ",
" ");
+ if (propKey.startsWith("{")) {
+ String namespace = propKey.substring(1,
propKey.lastIndexOf("}"));
+ clauses.add(" csp" + i + ".name = :cspname" +
i +
+ " and csp" + i + ".namespace =
:cspnamespace" + i +
+ " and csp" + i + ".value = :cspvalue"
+ i);
+
+ parameters.put("cspname" + i,
propKey.substring(propKey.lastIndexOf("}") + 1, propKey.length()));
+ parameters.put("cspnamespace" + i, namespace);
+ parameters.put("cspvalue" + i, value);
+ } else {
+ clauses.add(" csp" + i + ".name = :cspname" +
i +
+ " and csp" + i + ".value = :cspvalue"
+ i);
+
+ parameters.put("cspname" + i, propKey);
+ parameters.put("cspvalue" + i, value);
+ }
+ }
+ }
+
+ // order by
+ StringBuffer orderby = new StringBuffer("");
+ if (filter.getOrders() != null) {
+ orderby.append(" order by");
+ List<String> orders = filter.getOrders();
+ for (int m = 0; m < orders.size(); m++) {
+ String field = orders.get(m);
+ String ord = " asc";
+ if (field.startsWith("-")) {
+ ord = " desc";
+ }
+ String fieldName = " pi.id";
+ if (field.endsWith("name")) {
+ fieldName = " pi.process.typeName";
+ }
+ if (field.endsWith("namespace")) {
+ fieldName = " pi.process.typeNamespace";
+ }
+ if ( field.endsWith("version")) {
+ fieldName = " pi.process.version";
+ }
+ if ( field.endsWith("status")) {
+ fieldName = " pi.state";
+ }
+ if ( field.endsWith("started")) {
+ fieldName = " pi.created";
+ }
+ if ( field.endsWith("last-active")) {
+ fieldName = " pi.lastActiveTime";
+ }
+ orderby.append(fieldName + ord);
+ if (m < orders.size() - 1) orderby.append(", ");
+ }
+
+ }
+
+ // Preparing the statement
+ if (clauses.size() > 0) {
+ query.append(" where");
+ for (int m = 0; m < clauses.size(); m++) {
+ query.append(clauses.get(m));
+ if (m < clauses.size() - 1) query.append(" and");
+ }
+ }
+
+ query.append(orderby);
+ }
+
+ if (__log.isDebugEnabled()) {
+ __log.debug(query.toString());
+ }
+
+ Query q = session.createQuery(query.toString());
+
+ for (String p : parameters.keySet()) {
+ q.setParameter(p, parameters.get(p));
+ }
+
+ if (filter.getLimit() != 0) {
+ q.setMaxResults(filter.getLimit());
+ }
+
+ return q;
+ }
+
+ private static String dateFilter(String filter) {
+ String date = Filter.getDateWithoutOp(filter);
+ String op = filter.substring(0,filter.indexOf(date));
+ Date dt = null;
+ try {
+ dt = ISO8601DateParser.parse(date);
+ } catch (ParseException e) {
+ e.printStackTrace();
+ }
+ Timestamp ts = new Timestamp(dt.getTime());
+ return op + " '" + ts.toString() + "'";
+ }
+
+
+
/**
* Build a Hibernate {@link Criteria} from an instance filter.
* @param crit target (destination) criteria
* @param filter filter
*/
- @SuppressWarnings("unchecked")
void buildCriteria(Criteria crit, InstanceFilter filter) {
Criteria processCrit = crit.createCriteria("process");
@@ -66,7 +274,7 @@
if (iids != null && iids.size() > 0) {
Disjunction disj = Restrictions.disjunction();
for (String iid: iids) {
- crit.add(Restrictions.eq("id", new Long(iid)));
+ disj.add(Restrictions.eq("id", new Long(iid)));
}
crit.add(disj);
}
@@ -104,7 +312,7 @@
// Specific filter for correlation properties
if (filter.getPropertyValuesFilter() != null) {
Criteria propCrit =
crit.createCriteria("correlationSets").createCriteria("properties");
- for (Map.Entry corValue : filter.getPropertyValuesFilter().entrySet()) {
+ for (Map.Entry<String, String> corValue :
filter.getPropertyValuesFilter().entrySet()) {
String propName = (String)corValue.getKey();
if (propName.startsWith("{")) {
String namespace = propName.substring(1, propName.lastIndexOf("}"));
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/FaultDAOImpl.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/FaultDAOImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/FaultDAOImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -19,6 +19,10 @@
package org.apache.ode.daohib.bpel;
+import java.io.IOException;
+
+import javax.xml.namespace.QName;
+
import org.apache.ode.bpel.dao.FaultDAO;
import org.apache.ode.daohib.SessionManager;
import org.apache.ode.daohib.bpel.hobj.HFaultData;
@@ -27,9 +31,6 @@
import org.w3c.dom.Element;
import org.xml.sax.SAXException;
-import javax.xml.namespace.QName;
-import java.io.IOException;
-
/**
* Hibernate based {@link FaultDAO} implementation
*/
@@ -52,7 +53,7 @@
entering("FaultDAOImpl.getData");
if (_self.getData() == null) return null;
try {
- return DOMUtils.stringToDOM(_self.getData().getText());
+ return DOMUtils.stringToDOM(_self.getData());
} catch (SAXException e) {
throw new RuntimeException(e);
} catch (IOException e) {
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/HibernateDao.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/HibernateDao.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/HibernateDao.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -95,15 +95,27 @@
@SuppressWarnings("unchecked")
protected void deleteByIds(Class entity, List<Long> ids) {
- if( ids != null && ids.size() > 0 ) {
- StringBuffer buf = new StringBuffer();
- buf.append("delete from ");
- buf.append(entity.getName());
- buf.append(" as e where e.id in(:ids)");
+ deleteByColumn(entity, "id", ids);
+ }
+
+ @SuppressWarnings("unchecked")
+ protected void deleteByColumn(Class entity, String column, List<Long> values)
{
+ if( values != null && values.size() > 0 ) {
+ final String delete = "delete from "+entity.getName()+" as e
where e."+column+" in (:values)";
+
+ // some databases don't like long lists of values with IN operator
+ // so we delete in batches. Oracle 9i, for instance, doesn't support
+ // more than 1000 -- we opt to be conservative.
+ final int batchSize = 100;
- Query query = getSession().createQuery(buf.toString());
- query.setParameterList("ids", ids);
- query.executeUpdate();
+ int index = 0;
+ while (index < values.size()) {
+ List<Long> subList = values.subList(index,
Math.min(index+batchSize, values.size()));
+ Query query = getSession().createQuery(delete);
+ query.setParameterList("values", subList);
+ query.executeUpdate();
+ index += batchSize;
+ }
}
}
}
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/MessageDaoImpl.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/MessageDaoImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/MessageDaoImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -20,18 +20,17 @@
package org.apache.ode.daohib.bpel;
+import javax.xml.namespace.QName;
+
import org.apache.ode.bpel.dao.MessageDAO;
import org.apache.ode.bpel.dao.MessageExchangeDAO;
import org.apache.ode.daohib.SessionManager;
-import org.apache.ode.daohib.bpel.hobj.HLargeData;
import org.apache.ode.daohib.bpel.hobj.HMessage;
import org.apache.ode.utils.DOMUtils;
import org.hibernate.Session;
import org.w3c.dom.Element;
-import javax.xml.namespace.QName;
-
public class MessageDaoImpl extends HibernateDao implements MessageDAO {
private HMessage _hself;
@@ -56,11 +55,7 @@
public void setData(Element value) {
entering("MessageDaoImpl.setData");
if (value == null) return;
- if (_hself.getMessageData() != null)
- _session.delete(_hself.getMessageData());
- HLargeData newdata = new HLargeData(DOMUtils.domToString(value));
- _session.save(newdata);
- _hself.setMessageData(newdata);
+ _hself.setMessageData(DOMUtils.domToBytes(value));
update();
leaving("MessageDaoImpl.setData");
}
@@ -70,7 +65,7 @@
if (_hself.getMessageData() == null)
return null;
try {
- return DOMUtils.stringToDOM(_hself.getMessageData().getText());
+ return DOMUtils.stringToDOM(_hself.getMessageData());
} catch (Exception e) {
throw new RuntimeException(e);
}
@@ -79,11 +74,7 @@
public void setHeader(Element value) {
entering("MessageDaoImpl.setHeader");
if (value == null) return;
- if (_hself.getHeader() != null)
- _session.delete(_hself.getHeader());
- HLargeData newdata = new HLargeData(DOMUtils.domToString(value));
- _session.save(newdata);
- _hself.setHeader(newdata);
+ _hself.setHeader(DOMUtils.domToBytes(value));
update();
leaving("MessageDaoImpl.setHeader");
}
@@ -92,7 +83,7 @@
entering("MessageDaoImpl.getHeader");
if (_hself.getHeader() == null) return null;
try {
- return DOMUtils.stringToDOM(_hself.getHeader().getText());
+ return DOMUtils.stringToDOM(_hself.getHeader());
} catch (Exception e) {
throw new RuntimeException(e);
}
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/MessageExchangeDaoImpl.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/MessageExchangeDaoImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/MessageExchangeDaoImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -19,6 +19,14 @@
package org.apache.ode.daohib.bpel;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.Date;
+import java.util.Set;
+
+import javax.xml.namespace.QName;
+
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.apache.ode.bpel.dao.MessageDAO;
@@ -28,19 +36,15 @@
import org.apache.ode.bpel.dao.ProcessInstanceDAO;
import org.apache.ode.daohib.SessionManager;
import org.apache.ode.daohib.bpel.hobj.HCorrelatorMessage;
-import org.apache.ode.daohib.bpel.hobj.HLargeData;
import org.apache.ode.daohib.bpel.hobj.HMessage;
import org.apache.ode.daohib.bpel.hobj.HMessageExchange;
import org.apache.ode.daohib.bpel.hobj.HProcess;
import org.apache.ode.daohib.bpel.hobj.HProcessInstance;
import org.apache.ode.utils.DOMUtils;
+import org.apache.ode.utils.stl.CollectionsX;
+import org.apache.ode.utils.stl.UnaryFunctionEx;
import org.w3c.dom.Element;
-import javax.xml.namespace.QName;
-import java.util.Collections;
-import java.util.Date;
-import java.util.Set;
-
public class MessageExchangeDaoImpl extends HibernateDao implements
MessageExchangeDAO {
@SuppressWarnings("unused")
@@ -72,6 +76,10 @@
return _hself.getInsertTime();
}
+ public void setCreateTime(Date createTime) {
+ _hself.setInsertTime(createTime);
+ }
+
public MessageDAO getRequest() {
entering("MessageExchangeDaoImpl.getRequest");
return _hself.getRequest() == null ? null : new MessageDaoImpl(_sm,
_hself.getRequest());
@@ -162,9 +170,7 @@
if (source == null)
_hself.setEndpoint(null);
else {
- HLargeData ld = new HLargeData(DOMUtils.domToString(source));
- getSession().save(ld);
- _hself.setEndpoint(ld);
+ _hself.setEndpoint(DOMUtils.domToBytes(source));
}
getSession().saveOrUpdate(_hself);
@@ -173,11 +179,11 @@
public Element getEPR() {
entering("MessageExchangeDaoImpl.getEPR");
- HLargeData ld = _hself.getEndpoint();
- if (ld == null)
+ byte[] endpoint = _hself.getEndpoint();
+ if (endpoint == null)
return null;
try {
- return DOMUtils.stringToDOM(ld.getText());
+ return DOMUtils.stringToDOM(endpoint);
} catch (Exception e) {
throw new RuntimeException(e);
}
@@ -188,9 +194,7 @@
if (source == null)
_hself.setCallbackEndpoint(null);
else {
- HLargeData ld = new HLargeData(DOMUtils.domToString(source));
- getSession().save(ld);
- _hself.setCallbackEndpoint(ld);
+ _hself.setCallbackEndpoint(DOMUtils.domToBytes(source));
}
getSession().saveOrUpdate(_hself);
@@ -199,11 +203,11 @@
public Element getCallbackEPR() {
entering("MessageExchangeDaoImpl.getCallbackEPR");
- HLargeData ld = _hself.getCallbackEndpoint();
- if (ld == null)
+ byte[] endpoint = _hself.getCallbackEndpoint();
+ if (endpoint == null)
return null;
try {
- return DOMUtils.stringToDOM(ld.getText());
+ return DOMUtils.stringToDOM(endpoint);
} catch (Exception e) {
throw new RuntimeException(e);
}
@@ -359,8 +363,6 @@
@SuppressWarnings("unchecked")
public void releasePremieMessages() {
- deleteByIds(HLargeData.class,
getSession().getNamedQuery(HLargeData.SELECT_MESSAGE_LDATA_IDS_BY_MEX_1).setParameter("mex",
_hself).list());
- deleteByIds(HLargeData.class,
getSession().getNamedQuery(HLargeData.SELECT_MESSAGE_LDATA_IDS_BY_MEX_2).setParameter("mex",
_hself).list());
deleteByIds(HCorrelatorMessage.class,
getSession().getNamedQuery(HCorrelatorMessage.SELECT_CORMESSAGE_IDS_BY_MEX).setParameter("mex",
_hself).list());
}
@@ -370,11 +372,10 @@
@SuppressWarnings("unchecked")
public void deleteMessages() {
- deleteByIds(HLargeData.class,
getSession().getNamedQuery(HLargeData.SELECT_MESSAGE_LDATA_IDS_BY_MEX_1).setParameter("mex",
_hself).list());
- deleteByIds(HLargeData.class,
getSession().getNamedQuery(HLargeData.SELECT_MESSAGE_LDATA_IDS_BY_MEX_2).setParameter("mex",
_hself).list());
deleteByIds(HCorrelatorMessage.class,
getSession().getNamedQuery(HCorrelatorMessage.SELECT_CORMESSAGE_IDS_BY_MEX).setParameter("mex",
_hself).list());
getSession().delete(_hself);
// This deletes endpoint LData, callbackEndpoint LData, request HMessage,
response HMessage, HMessageExchangeProperty
}
+
}
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/PartnerLinkDAOImpl.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/PartnerLinkDAOImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/PartnerLinkDAOImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -23,7 +23,6 @@
import org.apache.ode.bpel.dao.PartnerLinkDAO;
import org.apache.ode.daohib.SessionManager;
-import org.apache.ode.daohib.bpel.hobj.HLargeData;
import org.apache.ode.daohib.bpel.hobj.HPartnerLink;
import org.apache.ode.utils.DOMUtils;
import org.w3c.dom.Element;
@@ -84,7 +83,7 @@
if (_self.getMyEPR() == null)
return null;
try {
- return DOMUtils.stringToDOM(_self.getMyEPR().getText());
+ return DOMUtils.stringToDOM(_self.getMyEPR());
} catch (Exception e) {
throw new RuntimeException(e);
}
@@ -93,14 +92,10 @@
public void setMyEPR(Element val) {
entering("PartnerLinkDAOImpl.setMyEPR");
_myEPR = val;
- if (_self.getMyEPR() != null)
- _sm.getSession().delete(_self.getMyEPR());
if (val == null) {
_self.setMyEPR(null);
} else {
- HLargeData ld = new HLargeData(DOMUtils.domToString(val));
- getSession().save(ld);
- _self.setMyEPR(ld);
+ _self.setMyEPR(DOMUtils.domToBytes(val));
}
getSession().update(_self);
}
@@ -112,7 +107,7 @@
if (_self.getPartnerEPR() == null)
return null;
try {
- return _partnerEPR = DOMUtils.stringToDOM(_self.getPartnerEPR().getText());
+ return _partnerEPR = DOMUtils.stringToDOM(_self.getPartnerEPR());
} catch (Exception e) {
throw new RuntimeException(e);
}
@@ -121,14 +116,10 @@
public void setPartnerEPR(Element val) {
entering("PartnerLinkDAOImpl.setPartnerEPR");
_partnerEPR = val;
- if (_self.getPartnerEPR() != null)
- _sm.getSession().delete(_self.getPartnerEPR());
if (val == null) {
_self.setPartnerEPR(null);
} else {
- HLargeData ld = new HLargeData(DOMUtils.domToString(val));
- getSession().save(ld);
- _self.setPartnerEPR(ld);
+ _self.setPartnerEPR(DOMUtils.domToBytes(val));
}
getSession().update(_self);
}
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/ProcessDaoImpl.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/ProcessDaoImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/ProcessDaoImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -18,6 +18,15 @@
*/
package org.apache.ode.daohib.bpel;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Date;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Set;
+
+import javax.xml.namespace.QName;
+
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.apache.ode.bpel.common.CorrelationKey;
@@ -36,11 +45,9 @@
import org.apache.ode.daohib.bpel.hobj.HCorrelatorMessage;
import org.apache.ode.daohib.bpel.hobj.HCorrelatorSelector;
import org.apache.ode.daohib.bpel.hobj.HFaultData;
-import org.apache.ode.daohib.bpel.hobj.HLargeData;
import org.apache.ode.daohib.bpel.hobj.HMessage;
import org.apache.ode.daohib.bpel.hobj.HMessageExchange;
import org.apache.ode.daohib.bpel.hobj.HMessageExchangeProperty;
-import org.apache.ode.daohib.bpel.hobj.HObject;
import org.apache.ode.daohib.bpel.hobj.HPartnerLink;
import org.apache.ode.daohib.bpel.hobj.HProcess;
import org.apache.ode.daohib.bpel.hobj.HProcessInstance;
@@ -50,18 +57,11 @@
import org.hibernate.Criteria;
import org.hibernate.Hibernate;
import org.hibernate.Query;
+import org.hibernate.StaleStateException;
+import org.hibernate.UnresolvableObjectException;
import org.hibernate.criterion.Expression;
import org.hibernate.criterion.Order;
-import javax.xml.namespace.QName;
-
-import java.util.Collection;
-import java.util.Date;
-import java.util.Iterator;
-import java.util.ArrayList;
-import java.util.List;
-import java.util.Set;
-
/**
* Hibernate-based {@link ProcessDAO} implementation.
*/
@@ -155,11 +155,20 @@
// delete process dao
deleteByIds(HCorrelator.class,
getSession().getNamedQuery(HCorrelator.SELECT_CORRELATOR_IDS_BY_PROCESS).setParameter("process",
_process).list());
- getSession().delete(_process); // this deletes HCorrelator ->
HCorrelatorSelector
+ try {
+ getSession().refresh(_process);
+ getSession().delete(_process); // this deletes HCorrelator ->
HCorrelatorSelector
- // after this delete, we have a use case that creates the process with the same
procid.
- // for hibernate to work without the database deferred constraint check,
let's just flush the session.
- getSession().flush();
+ // after this delete, we have a use case that creates the process with the
same procid.
+ // for hibernate to work without the database deferred constraint check,
let's just flush the session.
+ getSession().flush();
+ } catch( UnresolvableObjectException sse ) {
+ __log.debug("Process: " + getProcessId() + " has been already
deleted.");
+ // don't sweat, they already deleted by another thread or process
+ } catch( StaleStateException sse ) {
+ __log.debug("Process: " + getProcessId() + " has been already
deleted.");
+ // don't sweat, they already deleted by another thread or process
+ }
}
@SuppressWarnings("unchecked")
@@ -209,12 +218,9 @@
@SuppressWarnings("unchecked")
private void deleteProcessInstances(Collection<HProcessInstance> instances) {
- deleteByIds(HLargeData.class,
getSession().getNamedQuery(HLargeData.SELECT_ACTIVITY_RECOVERY_LDATA_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
deleteByIds(HActivityRecovery.class,
getSession().getNamedQuery(HActivityRecovery.SELECT_ACTIVITY_RECOVERY_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
- deleteByIds(HLargeData.class,
getSession().getNamedQuery(HLargeData.SELECT_FAULT_LDATA_IDS_BY_INSTANCE_IDS).setParameterList("instanceIds",
HObject.toIdArray(instances)).list());
deleteByIds(HFaultData.class,
getSession().getNamedQuery(HFaultData.SELECT_FAULT_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
- deleteByIds(HLargeData.class,
getSession().getNamedQuery(HLargeData.SELECT_JACOB_LDATA_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
-
+
List<Long> instanceIds = new ArrayList<Long>();
for( HProcessInstance instance : instances ) {
instanceIds.add(instance.getId());
@@ -225,10 +231,7 @@
@SuppressWarnings("unchecked")
private void deleteVariables(Collection<HProcessInstance> instances) {
deleteByIds(HVariableProperty.class,
getSession().getNamedQuery(HVariableProperty.SELECT_VARIABLE_PROPERTY_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
- deleteByIds(HLargeData.class,
getSession().getNamedQuery(HLargeData.SELECT_XMLDATA_LDATA_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
deleteByIds(HXmlData.class,
getSession().getNamedQuery(HXmlData.SELECT_XMLDATA_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
- deleteByIds(HLargeData.class,
getSession().getNamedQuery(HLargeData.SELECT_PARTNER_LINK_LDATA_IDS_BY_INSTANCES_1).setParameterList("instances",
instances).list());
- deleteByIds(HLargeData.class,
getSession().getNamedQuery(HLargeData.SELECT_PARTNER_LINK_LDATA_IDS_BY_INSTANCES_2).setParameterList("instances",
instances).list());
deleteByIds(HPartnerLink.class,
getSession().getNamedQuery(HPartnerLink.SELECT_PARTNER_LINK_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
deleteByIds(HScope.class,
getSession().getNamedQuery(HScope.SELECT_SCOPE_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
}
@@ -236,13 +239,10 @@
@SuppressWarnings("unchecked")
private void deleteMessages(Collection<HProcessInstance> instances) {
deleteByIds(HActivityRecovery.class,
getSession().getNamedQuery(HCorrelatorMessage.SELECT_CORMESSAGE_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
- deleteByIds(HLargeData.class,
getSession().getNamedQuery(HLargeData.SELECT_MESSAGE_LDATA_IDS_BY_INSTANCES_1).setParameterList("instances",
instances).list());
- deleteByIds(HLargeData.class,
getSession().getNamedQuery(HLargeData.SELECT_MESSAGE_LDATA_IDS_BY_INSTANCES_2).setParameterList("instances",
instances).list());
deleteByIds(HMessage.class,
getSession().getNamedQuery(HMessage.SELECT_MESSAGE_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
- deleteByIds(HMessageExchangeProperty.class,
getSession().getNamedQuery(HMessageExchangeProperty.SELECT_MEX_PROPS_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
- deleteByIds(HLargeData.class,
getSession().getNamedQuery(HLargeData.SELECT_MEX_LDATA_IDS_BY_INSTANCES_1).setParameterList("instances",
instances).list());
- deleteByIds(HLargeData.class,
getSession().getNamedQuery(HLargeData.SELECT_MEX_LDATA_IDS_BY_INSTANCES_2).setParameterList("instances",
instances).list());
- deleteByIds(HMessageExchange.class,
getSession().getNamedQuery(HMessageExchange.SELECT_MEX_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
+ List<Long> mex =
getSession().getNamedQuery(HMessageExchange.SELECT_MEX_IDS_BY_INSTANCES).setParameterList("instances",
instances).list();
+ deleteByColumn(HMessageExchangeProperty.class, "mex.id", mex);
+ deleteByIds(HMessageExchange.class, mex);
}
@SuppressWarnings("unchecked")
@@ -253,7 +253,6 @@
@SuppressWarnings("unchecked")
private void deleteEvents(Collection<HProcessInstance> instances) {
- deleteByIds(HLargeData.class,
getSession().getNamedQuery(HLargeData.SELECT_EVENT_LDATA_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
deleteByIds(HBpelEvent.class,
getSession().getNamedQuery(HBpelEvent.SELECT_EVENT_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
}
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/ProcessInstanceDaoImpl.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/ProcessInstanceDaoImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/ProcessInstanceDaoImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -18,14 +18,48 @@
*/
package org.apache.ode.daohib.bpel;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Date;
+import java.util.HashSet;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Set;
+
+import javax.xml.namespace.QName;
+
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.apache.ode.bpel.common.ProcessState;
-import org.apache.ode.bpel.dao.*;
+import org.apache.ode.bpel.dao.ActivityRecoveryDAO;
+import org.apache.ode.bpel.dao.BpelDAOConnection;
+import org.apache.ode.bpel.dao.CorrelationSetDAO;
+import org.apache.ode.bpel.dao.CorrelatorDAO;
+import org.apache.ode.bpel.dao.FaultDAO;
+import org.apache.ode.bpel.dao.MessageExchangeDAO;
+import org.apache.ode.bpel.dao.ProcessDAO;
+import org.apache.ode.bpel.dao.ProcessInstanceDAO;
+import org.apache.ode.bpel.dao.ScopeDAO;
+import org.apache.ode.bpel.dao.ScopeStateEnum;
+import org.apache.ode.bpel.dao.XmlDataDAO;
import org.apache.ode.bpel.evt.ProcessInstanceEvent;
import org.apache.ode.bpel.iapi.ProcessConf.CLEANUP_CATEGORY;
import org.apache.ode.daohib.SessionManager;
-import org.apache.ode.daohib.bpel.hobj.*;
+import org.apache.ode.daohib.bpel.hobj.HActivityRecovery;
+import org.apache.ode.daohib.bpel.hobj.HBpelEvent;
+import org.apache.ode.daohib.bpel.hobj.HCorrelationProperty;
+import org.apache.ode.daohib.bpel.hobj.HCorrelationSet;
+import org.apache.ode.daohib.bpel.hobj.HCorrelatorMessage;
+import org.apache.ode.daohib.bpel.hobj.HCorrelatorSelector;
+import org.apache.ode.daohib.bpel.hobj.HFaultData;
+import org.apache.ode.daohib.bpel.hobj.HMessage;
+import org.apache.ode.daohib.bpel.hobj.HMessageExchange;
+import org.apache.ode.daohib.bpel.hobj.HMessageExchangeProperty;
+import org.apache.ode.daohib.bpel.hobj.HPartnerLink;
+import org.apache.ode.daohib.bpel.hobj.HProcessInstance;
+import org.apache.ode.daohib.bpel.hobj.HScope;
+import org.apache.ode.daohib.bpel.hobj.HVariableProperty;
+import org.apache.ode.daohib.bpel.hobj.HXmlData;
import org.apache.ode.utils.DOMUtils;
import org.apache.ode.utils.QNameUtils;
import org.apache.ode.utils.stl.CollectionsX;
@@ -37,9 +71,6 @@
import org.hibernate.criterion.Restrictions;
import org.w3c.dom.Element;
-import javax.xml.namespace.QName;
-import java.util.*;
-
/**
* Hibernate-based {@link ProcessInstanceDAO} implementation.
*/
@@ -95,9 +126,7 @@
fault.setLineNo(lineNo);
fault.setActivityId(activityId);
if (faultData != null) {
- HLargeData ld = new HLargeData(DOMUtils.domToString(faultData));
- fault.setData(ld);
- getSession().save(ld);
+ fault.setData(DOMUtils.domToBytes(faultData));
}
_instance.setFault(fault);
@@ -119,7 +148,7 @@
public byte[] getExecutionState() {
entering("ProcessInstanceDaoImpl.getExecutionState");
if (_instance.getJacobState() == null) return null;
- return _instance.getJacobState().getBinary();
+ return _instance.getJacobState();
}
/**
@@ -127,12 +156,8 @@
*/
public void setExecutionState(byte[] bytes) {
entering("ProcessInstanceDaoImpl.setExecutionState");
- if (_instance.getJacobState() != null)
- getSession().delete(_instance.getJacobState());
if (bytes.length > 0) {
- HLargeData ld = new HLargeData(bytes);
- _instance.setJacobState(ld);
- getSession().save(ld);
+ _instance.setJacobState(bytes);
}
getSession().update(_instance);
}
@@ -326,12 +351,15 @@
}
public void delete(Set<CLEANUP_CATEGORY> cleanupCategories) {
+ delete(cleanupCategories, true);
+ }
+
+ public void delete(Set<CLEANUP_CATEGORY> cleanupCategories, boolean
deleteMyRoleMex) {
entering("ProcessInstanceDaoImpl.delete");
if(__log.isDebugEnabled()) __log.debug("Cleaning up instance data with
categories = " + cleanupCategories);
if( _instance.getJacobState() != null ) {
- getSession().delete(_instance.getJacobState());
- _instance.setJacobState(null);
+ _instance.setJacobState(null);
}
HProcessInstance[] instances = new HProcessInstance[] {_instance};
@@ -345,7 +373,7 @@
}
if( cleanupCategories.contains(CLEANUP_CATEGORY.MESSAGES) ) {
- deleteMessages(instances);
+ deleteMessages(instances, deleteMyRoleMex);
}
if( cleanupCategories.contains(CLEANUP_CATEGORY.VARIABLES) ) {
@@ -363,7 +391,6 @@
@SuppressWarnings("unchecked")
private void deleteInstances(HProcessInstance[] instances) {
- deleteByIds(HLargeData.class,
getSession().getNamedQuery(HLargeData.SELECT_FAULT_LDATA_IDS_BY_INSTANCE_IDS).setParameterList("instanceIds",
HObject.toIdArray(instances)).list());
deleteByIds(HFaultData.class,
getSession().getNamedQuery(HFaultData.SELECT_FAULT_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
getSession().delete(_instance); // this deletes JcobState, HActivityRecovery ->
ActivityRecovery-LData
@@ -375,30 +402,43 @@
deleteByIds(HCorrelationSet.class,
getSession().getNamedQuery(HCorrelationSet.SELECT_CORSET_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
deleteByIds(HVariableProperty.class,
getSession().getNamedQuery(HVariableProperty.SELECT_VARIABLE_PROPERTY_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
- deleteByIds(HLargeData.class,
getSession().getNamedQuery(HLargeData.SELECT_XMLDATA_LDATA_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
deleteByIds(HXmlData.class,
getSession().getNamedQuery(HXmlData.SELECT_XMLDATA_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
- deleteByIds(HLargeData.class,
getSession().getNamedQuery(HLargeData.SELECT_PARTNER_LINK_LDATA_IDS_BY_INSTANCES_1).setParameterList("instances",
instances).list());
- deleteByIds(HLargeData.class,
getSession().getNamedQuery(HLargeData.SELECT_PARTNER_LINK_LDATA_IDS_BY_INSTANCES_2).setParameterList("instances",
instances).list());
deleteByIds(HPartnerLink.class,
getSession().getNamedQuery(HPartnerLink.SELECT_PARTNER_LINK_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
deleteByIds(HScope.class,
getSession().getNamedQuery(HScope.SELECT_SCOPE_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
}
@SuppressWarnings("unchecked")
- private void deleteMessages(HProcessInstance[] instances) {
- // there are chances that some unmatched messages are still there
- deleteByIds(HLargeData.class,
getSession().getNamedQuery(HLargeData.SELECT_UNMATCHED_MESSAGE_LDATA_IDS_BY_INSTANCES_1).setParameterList("instances",
instances).list());
- deleteByIds(HLargeData.class,
getSession().getNamedQuery(HLargeData.SELECT_UNMATCHED_MESSAGE_LDATA_IDS_BY_INSTANCES_2).setParameterList("instances",
instances).list());
+ private void deleteMessages(HProcessInstance[] instances, boolean deleteMyRoleMex) {
+ // Let's delete ALL mex properties here
+ List<Long> allMexes =
getSession().getNamedQuery(HMessageExchange.SELECT_MEX_IDS_BY_INSTANCES).setParameterList("instances",
instances).list();
+ deleteByColumn(HMessageExchangeProperty.class, "mex.id", allMexes);
- Collection unmatchedMex =
getSession().getNamedQuery(HMessageExchange.SELECT_UNMATCHED_MEX_BY_INSTANCES).setParameterList("instances",
instances).list();
- if( !unmatchedMex.isEmpty() ) {
- getSession().delete(unmatchedMex);
+ if( deleteMyRoleMex ) { // Delete my role mex and partner role mexes
+ // delete messages
+ deleteByIds(HMessage.class,
getSession().getNamedQuery(HMessage.SELECT_MESSAGE_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
+
+ // delete all mexes
+ deleteByIds(HMessageExchange.class, allMexes);
+ } else { // Delete only the unmatched mexes, there are chances that some unmatched
messages are still there
+ Collection<HMessageExchange> unmatchedMex =
getSession().getNamedQuery(HMessageExchange.SELECT_UNMATCHED_MEX_BY_INSTANCES).setParameterList("instances",
instances).list();
+ if( !unmatchedMex.isEmpty() ) {
+ List<Long> mexIdList = new ArrayList<Long>();
+ for( HMessageExchange mex : unmatchedMex ) {
+ mexIdList.add(mex.getId());
+ }
+
+ // delete unmatched mexes
+ getSession().delete(unmatchedMex);
+ }
}
+
+ // Delete routes and unmatched messages
deleteByIds(HCorrelatorMessage.class,
getSession().getNamedQuery(HCorrelatorMessage.SELECT_CORMESSAGE_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
deleteByIds(HCorrelatorSelector.class,
getSession().getNamedQuery(HCorrelatorSelector.SELECT_MESSAGE_ROUTE_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
}
-
+
@SuppressWarnings("unchecked")
private void deleteCorrelations(HProcessInstance[] instances) {
deleteByIds(HCorrelationProperty.class,
getSession().getNamedQuery(HCorrelationProperty.SELECT_CORPROP_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
@@ -407,7 +447,6 @@
@SuppressWarnings("unchecked")
private void deleteEvents(HProcessInstance[] instances) {
- deleteByIds(HLargeData.class,
getSession().getNamedQuery(HLargeData.SELECT_EVENT_LDATA_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
deleteByIds(HBpelEvent.class,
getSession().getNamedQuery(HBpelEvent.SELECT_EVENT_IDS_BY_INSTANCES).setParameterList("instances",
instances).list());
}
@@ -490,9 +529,7 @@
recovery.setDateTime(dateTime);
recovery.setRetries(retries);
if (data != null) {
- HLargeData ld = new HLargeData(DOMUtils.domToString(data));
- recovery.setDetails(ld);
- getSession().save(ld);
+ recovery.setDetails(DOMUtils.domToBytes(data));
}
String list = actions[0];
for (int i = 1; i < actions.length; ++i)
@@ -524,5 +561,13 @@
entering("ProcessInstanceDaoImpl.getConnection");
return new BpelDAOConnectionImpl(_sm);
}
+
+ public Collection<String> getMessageExchangeIds() {
+ Collection<String> c = new HashSet<String>();
+ for (HMessageExchange m : _instance.getMessageExchanges()) {
+ c.add(m.getId().toString());
+ }
+ return c;
+ }
}
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/ProcessManagementDaoImpl.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/ProcessManagementDaoImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/ProcessManagementDaoImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -19,50 +19,50 @@
package org.apache.ode.daohib.bpel;
-import java.util.Collection;
-import java.util.List;
+import java.util.Date;
+import java.util.HashMap;
+import java.util.Map;
+import java.util.Set;
import org.apache.ode.bpel.common.InstanceFilter;
-import org.apache.ode.bpel.dao.BpelDAOConnection;
-import org.apache.ode.bpel.dao.ProcessInstanceDAO;
+import org.apache.ode.bpel.common.InstanceFilter.StatusKeys;
import org.apache.ode.bpel.dao.ProcessManagementDAO;
import org.apache.ode.daohib.SessionManager;
import org.apache.ode.daohib.bpel.hobj.HProcessInstance;
import org.hibernate.Query;
-import org.hibernate.transform.ResultTransformer;
public class ProcessManagementDaoImpl extends HibernateDao implements
ProcessManagementDAO {
protected ProcessManagementDaoImpl(SessionManager sessionManager) {
super(sessionManager, null);
}
- @SuppressWarnings("unchecked")
- public Object[] findFailedCountAndLastFailedDateForProcessId(BpelDAOConnection conn,
String status, String processId) {
- Object[] results = new Object[] {0, null};
-
- Query query =
getSession().getNamedQuery(HProcessInstance.COUNT_FAILED_INSTANCES_BY_PROCESS_IDS_AND_STATES);
- query.setParameterList("states", new InstanceFilter("status="
+ status).convertFilterState());
- query.setParameterList("processIds", new String[] {processId});
- query.setResultTransformer(new ResultTransformer() {
- private static final long serialVersionUID = 8034301512569916379L;
-
- public List transformList(List collection) {
- return collection;
+ public Map<InstanceSummaryKey, Long> countInstancesSummary(Set<String>
pids) {
+ Map<InstanceSummaryKey, Long> result = new HashMap<InstanceSummaryKey,
Long>();
+ if (!pids.isEmpty()) {
+ for (StatusKeys status : InstanceFilter.StatusKeys.values()) {
+ Query query =
getSession().getNamedQuery(HProcessInstance.COUNT_INSTANCES_BY_PROCESSES_IDS_AND_STATES);
+ query.setParameterList("states", new
InstanceFilter("status=" + status.toString()).convertFilterState());
+ query.setParameterList("processIds", pids);
+ for (Object o : query.list()) {
+ Object[] row = (Object[]) o;
+ InstanceSummaryKey key = new InstanceSummaryKey(row[0].toString(),
status.toString());
+ result.put(key, (Long) row[1]);
+ }
}
- public Object transformTuple(Object[] tuple, String[] aliases) {
- return tuple;
- }
- });
-
- List result = query.list();
- if( !result.isEmpty() ) {
- results = (Object[])result.iterator().next();
}
-
- return results;
+ return result;
}
- public void prefetchActivityFailureCounts(Collection<ProcessInstanceDAO>
instances) {
- // do nothing; activity failures counts are already in a column
+ public Map<String, FailedSummaryValue>
findFailedCountAndLastFailedDateForProcessIds(Set<String> pids) {
+ Map<String, FailedSummaryValue> result = new HashMap<String,
FailedSummaryValue>();
+ if (!pids.isEmpty()) {
+ Query query =
getSession().getNamedQuery(HProcessInstance.COUNT_FAILED_INSTANCES_BY_PROCESSES_IDS_AND_STATES);
+ query.setParameterList("processIds", pids);
+ for (Object o : query.list()) {
+ Object[] row = (Object[]) o;
+ result.put(row[0].toString(), new FailedSummaryValue((Long) row[1],
(Date) row[2]));
+ }
+ }
+ return result;
}
}
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/ScopeDaoImpl.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/ScopeDaoImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/ScopeDaoImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -18,6 +18,14 @@
*/
package org.apache.ode.daohib.bpel;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.LinkedList;
+import java.util.List;
+import java.util.Set;
+
import org.apache.ode.bpel.dao.CorrelationSetDAO;
import org.apache.ode.bpel.dao.PartnerLinkDAO;
import org.apache.ode.bpel.dao.ProcessInstanceDAO;
@@ -39,12 +47,10 @@
import org.hibernate.Query;
import org.hibernate.criterion.Restrictions;
-import java.util.*;
-
/**
* Hibernate-based {@link ScopeDAO} implementation.
*/
-class ScopeDaoImpl extends HibernateDao implements ScopeDAO {
+public class ScopeDaoImpl extends HibernateDao implements ScopeDAO {
private static final String QRY_VARIABLE = "from " +
HXmlData.class.getName() +
@@ -143,7 +149,7 @@
data.setScope(_scope);
_scope.getVariables().add(data);
}
-
+
XmlDataDaoImpl varDao = new XmlDataDaoImpl(_sm, data);
_variables.put(varName, varDao);
return varDao;
@@ -248,7 +254,7 @@
try {
CollectionsX.transformEx(ret,hevents,new
UnaryFunctionEx<HBpelEvent,BpelEvent>() {
public BpelEvent apply(HBpelEvent x) throws Exception{
- return (BpelEvent)
SerializableUtils.toObject(x.getData().getBinary(),BpelEvent.class.getClassLoader());
+ return (BpelEvent)
SerializableUtils.toObject(x.getData(),BpelEvent.class.getClassLoader());
}
});
@@ -257,5 +263,4 @@
}
return ret;
}
-
}
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/XmlDataDaoImpl.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/XmlDataDaoImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/XmlDataDaoImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -18,16 +18,14 @@
*/
package org.apache.ode.daohib.bpel;
+import java.util.Iterator;
+
import org.apache.ode.bpel.dao.ScopeDAO;
import org.apache.ode.bpel.dao.XmlDataDAO;
import org.apache.ode.daohib.SessionManager;
-import org.apache.ode.daohib.bpel.hobj.HLargeData;
import org.apache.ode.daohib.bpel.hobj.HVariableProperty;
import org.apache.ode.daohib.bpel.hobj.HXmlData;
import org.apache.ode.utils.DOMUtils;
-
-import java.util.Iterator;
-
import org.hibernate.Query;
import org.w3c.dom.Document;
import org.w3c.dom.Element;
@@ -37,7 +35,7 @@
/**
* Hibernate-based {@link XmlDataDAO} implementation.
*/
-class XmlDataDaoImpl extends HibernateDao implements XmlDataDAO {
+public class XmlDataDaoImpl extends HibernateDao implements XmlDataDAO {
private static final String QUERY_PROPERTY =
@@ -60,7 +58,7 @@
*/
public boolean isNull() {
entering("XmlDataDaoImpl.isNull");
- return _data.getData() == null;
+ return (_data.getData() == null || _data.getData().length == 0);
}
/**
@@ -73,6 +71,7 @@
}
return _node;
}
+
/**
* @see org.apache.ode.bpel.dao.XmlDataDAO#remove()
*/
@@ -87,22 +86,12 @@
_node = val;
_data.setSimpleType(!(val instanceof Element));
- HLargeData ld = _data.getData();
-
- if (ld == null) {
- ld = new HLargeData();
- } else {
- ld.setBinary(null);
- }
-
if(_data.isSimpleType()) {
- ld.setBinary(_node.getNodeValue().getBytes());
- _data.setData(ld);
+ _data.setData(_node.getNodeValue().getBytes());
} else {
- ld.setBinary(DOMUtils.domToString(_node).getBytes());
- _data.setData(ld);
+ _data.setData(DOMUtils.domToString(_node).getBytes());
}
- getSession().saveOrUpdate(ld);
+
getSession().saveOrUpdate(_data);
leaving("XmlDataDaoImpl.set");
}
@@ -154,9 +143,9 @@
}
private Node prepare(){
- if(_data.getData() == null)
+ if(_data.getData() == null || _data.getData().length == 0)
return null;
- String data = _data.getData().getText();
+ String data = new String(_data.getData());
if(_data.isSimpleType()){
Document d = DOMUtils.newDocument();
// we create a dummy wrapper element
Added:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/GZipDataType.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/GZipDataType.java
(rev 0)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/GZipDataType.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,221 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.ode.daohib.bpel.hobj;
+
+import java.io.ByteArrayInputStream;
+import java.io.ByteArrayOutputStream;
+import java.io.InputStream;
+import java.io.IOException;
+import java.io.OutputStream;
+import java.io.Serializable;
+import java.sql.SQLException;
+import java.sql.PreparedStatement;
+import java.sql.ResultSet;
+import java.sql.Types;
+import java.util.zip.GZIPInputStream;
+import java.util.zip.GZIPOutputStream;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+import org.hibernate.usertype.UserType;
+
+/**
+ * Custom Hibernate datatype that compresses (GZip) byte arrays
+ * to increase performance and save disk space.
+ */
+public class GZipDataType implements UserType {
+ private static final Log log = LogFactory.getLog(GZipDataType.class);
+
+ public static final int[] SQL_TYPES = new int[] { Types.BLOB };
+
+ public static final Class RETURNED_CLASS = new byte[0].getClass();
+
+ /** For backward compatibility with non-zipped data, prefix the gzip stream with a
magic sequence */
+ public static final byte[] GZIP_PREFIX = new byte[] { 0x01, 0x02, 0x03, 0x04, 0x03,
0x02, 0x01, 0x00 };
+
+ // Compression statistics
+ private static long _totalBytesBefore = 0;
+ private static long _totalBytesAfter = 0;
+ private static volatile long _lastLogTime = 0;
+ private static final Object STATS_LOCK = new Object();
+
+ private static volatile boolean _compressionEnabled =
System.getProperty("org.apache.ode.daohib.bpel.hobj.GZipDataType.enabled",
"true").equalsIgnoreCase("true");
+
+ /** Reconstruct an object from the cacheable representation */
+ public Object assemble(Serializable cached, Object owner) {
+ // serializable representation is same
+ return cached;
+ }
+
+ /** Transform the object into its cacheable representation */
+ public Serializable disassemble(Object value) {
+ // as-is
+ return (Serializable) value;
+ }
+
+ /** Return a deep copy of the persistent state */
+ public Object deepCopy(Object value) {
+ if (value == null) return null;
+ return ((byte[]) value).clone();
+ }
+
+ /** Compare two instances of the class mapped by this type for persistence
"equality". */
+ public boolean equals(Object x, Object y) {
+ byte[] buf1 = (byte[]) x;
+ byte[] buf2 = (byte[]) y;
+ if (buf1 == buf2) return true;
+ if (buf1 == null && buf2 != null) return false;
+ if (buf1 != null && buf2 == null) return false;
+ if (buf1.length != buf2.length) return false;
+ for (int i=0; i<buf1.length; i++) {
+ if (buf1[i] != buf2[i]) return false;
+ }
+ return true;
+ }
+
+ /** Get a hashcode for the instance, consistent with persistence "equality"
*/
+ public int hashCode(Object x) {
+ if (x == null) return 0;
+ byte[] buf = (byte[]) x;
+ int hash = 0;
+ for (int i=0; i<buf.length; i++) {
+ hash += buf[i];
+ }
+ return hash;
+ }
+
+ /** Are objects of this type mutable? */
+ public boolean isMutable() {
+ return false;
+ }
+
+ /** Retrieve an instance of the mapped class from a JDBC resultset. */
+ public Object nullSafeGet(ResultSet rs, String[] names, Object owner) throws
SQLException {
+ if (names.length != 1) throw new IllegalStateException("Expected a single
column name instead of "+names.length);
+ byte[] buf = rs.getBytes(names[0]);
+ if (buf == null) {
+ return null;
+ }
+ if (buf.length >= GZIP_PREFIX.length) {
+ boolean gzip = true;
+ for (int i=0; i<GZIP_PREFIX.length; i++) {
+ if (buf[i] != GZIP_PREFIX[i]) {
+ gzip = false;
+ break;
+ }
+ }
+ if (gzip) {
+ buf = gunzip(new ByteArrayInputStream(buf, GZIP_PREFIX.length,
buf.length-GZIP_PREFIX.length));
+ }
+ }
+ return buf;
+ }
+
+ /** Write an instance of the mapped class to a prepared statement. */
+ public void nullSafeSet(PreparedStatement st, Object value, int index) throws
SQLException {
+ byte[] buf = (byte[]) value;
+ if (buf != null) {
+ synchronized (STATS_LOCK) {
+ if (_totalBytesBefore > Integer.MAX_VALUE) {
+ // prevent overflow - renormalize to percent value
+ _totalBytesAfter = _totalBytesAfter*100/_totalBytesBefore;
+ _totalBytesBefore = 100;
+ }
+ _totalBytesBefore += buf.length;
+ }
+ // only try to zip if we have more than 100 bytes
+ if (buf != null && buf.length > 100 &&
_compressionEnabled) {
+ ByteArrayOutputStream baos = new ByteArrayOutputStream(buf.length);
+ for (int i=0; i<GZIP_PREFIX.length; i++) {
+ baos.write(GZIP_PREFIX[i]);
+ }
+ gzip((byte[]) value, baos);
+ byte[] zipped = baos.toByteArray();
+ // only use zipped representation if we gain 2% or more
+ if (zipped.length*100/buf.length < 99) {
+ buf = zipped;
+ }
+ }
+ synchronized (STATS_LOCK) {
+ _totalBytesAfter += buf.length;
+ }
+ if (log.isDebugEnabled()) {
+ long now = System.currentTimeMillis();
+ if (_lastLogTime+5000 < now) {
+ log.debug("Average compression ratio: "+
(_totalBytesAfter*100/_totalBytesBefore)+"%");
+ _lastLogTime = now;
+ }
+ }
+ }
+ st.setBytes(index, buf);
+ }
+
+ /** During merge, replace the existing (target) value in the entity we are
+ * merging to with a new (original) value from the detached entity we are merging.
+ */
+ public Object replace(Object original, Object target, Object owner) {
+ return original;
+ }
+
+ /** The class returned by nullSafeGet(). */
+ public Class returnedClass() {
+ return RETURNED_CLASS;
+ }
+
+ /** Return the SQL type codes for the columns mapped by this type. */
+ public int[] sqlTypes() {
+ return SQL_TYPES;
+ }
+
+ /**
+ * Compress (using gzip algorithm) a byte array into an output stream.
+ */
+ public static void gzip(byte[] content, OutputStream out) {
+ try {
+ GZIPOutputStream zip = new GZIPOutputStream(out);
+ zip.write(content, 0, content.length);
+ zip.finish();
+ zip.close();
+ } catch (IOException ex) {
+ throw new RuntimeException(ex);
+ }
+ }
+
+ /**
+ * Decompress (using gzip algorithm) a byte array.
+ */
+ public static byte[] gunzip(InputStream input) {
+ try {
+ GZIPInputStream unzip = new GZIPInputStream(input);
+ ByteArrayOutputStream baos = new ByteArrayOutputStream(32*1024);
+ byte[] buf = new byte[4096];
+ int len;
+ while ((len = unzip.read(buf)) > 0) {
+ baos.write(buf, 0, len);
+ }
+ unzip.close();
+ return baos.toByteArray();
+ } catch (IOException ex) {
+ throw new RuntimeException(ex);
+ }
+ }
+
+}
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HActivityRecovery.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HActivityRecovery.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HActivityRecovery.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -35,7 +35,7 @@
private String _channel;
private String _reason;
private Date _dateTime;
- private HLargeData _details;
+ private byte[] _details;
private String _actions;
private int _retries;
@@ -98,13 +98,15 @@
}
/**
- * @hibernate.many-to-one column="LDATA_ID" cascade="delete"
foreign-key="none"
+ * @hibernate.property type="org.apache.ode.daohib.bpel.hobj.GZipDataType"
+ *
+ * @hibernate.column name="DETAILS" sql-type="blob(2G)"
*/
- public HLargeData getDetails() {
+ public byte[] getDetails() {
return _details;
}
- public void setDetails(HLargeData details) {
+ public void setDetails(byte[] details) {
_details = details;
}
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HBpelEvent.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HBpelEvent.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HBpelEvent.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -38,7 +38,7 @@
private HProcess _process;
private HProcessInstance _instance;
- private HLargeData _data;
+ private byte[] _data;
/** Scope identifier, possibly null. */
private Long _scopeId;
@@ -108,13 +108,15 @@
/**
- * @hibernate.many-to-one column="LDATA_ID" cascade="delete"
foreign-key="none"
+ * @hibernate.property type="org.apache.ode.daohib.bpel.hobj.GZipDataType"
+ *
+ * @hibernate.column name="DATA" sql-type="blob(2G)"
*/
- public HLargeData getData() {
+ public byte[] getData() {
return _data;
}
- public void setData(HLargeData data) {
+ public void setData(byte[] data) {
_data = data;
}
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HCorrelationProperty.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HCorrelationProperty.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HCorrelationProperty.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -46,6 +46,7 @@
_namespace = namespace;
_value = value;
_correlationSet = correlationSet;
+ _correlationSet.getProperties().add(this);
}
public HCorrelationProperty(QName qname, String value, HCorrelationSet
correlationSet) {
@@ -54,6 +55,7 @@
_namespace = qname.getNamespaceURI();
_value = value;
_correlationSet = correlationSet;
+ _correlationSet.getProperties().add(this);
}
/**
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HCorrelatorSelector.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HCorrelatorSelector.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HCorrelatorSelector.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -22,16 +22,19 @@
/**
* @hibernate.class table="BPEL_SELECTORS" lazy="true"
* @hibernate.query name="SELECT_MESSAGE_ROUTE_IDS_BY_PROCESS"
query="select id from HCorrelatorSelector as m where m.correlator in(select c from
HCorrelator c where c.process = :process)"
- * @hibernate.query name="SELECT_MESSAGE_ROUTE_IDS_BY_INSTANCES"
query="select id from HCorrelatorSelector as m where m.instance in
(:instances))"
+ * @hibernate.query name="SELECT_MESSAGE_ROUTE_IDS_BY_INSTANCES"
query="select id from HCorrelatorSelector as m where m.instance in
(:instances)"
+ * @hibernate.query name="SELECT_MESSAGE_ROUTE" query="select m.id from
HCorrelatorSelector as m where m.correlator = :corr and m.correlationKey = :ckey"
*/
public class HCorrelatorSelector extends HObject {
public static final String SELECT_MESSAGE_ROUTE_IDS_BY_PROCESS =
"SELECT_MESSAGE_ROUTE_IDS_BY_PROCESS";
public static final String SELECT_MESSAGE_ROUTE_IDS_BY_INSTANCES =
"SELECT_MESSAGE_ROUTE_IDS_BY_INSTANCES";
+ public static final String SELECT_MESSAGE_ROUTE = "SELECT_MESSAGE_ROUTE";
private HProcessInstance _instance;
private String _groupId;
private int _idx;
private HCorrelator _correlator;
+ private String _correlatorId;
private String _correlationKey;
private String _processType;
private String _routePolicy;
@@ -128,4 +131,15 @@
_correlator = correlator;
}
+ /**
+ * @hibernate.property column="CORRELATOR" not-null="true"
insert="false" update="false"
+ */
+ public String getCorrelatorId() {
+ return _correlatorId;
+ }
+
+ public void setCorrelatorId(String correlatorId) {
+ this._correlatorId = correlatorId;
+ }
+
}
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HFaultData.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HFaultData.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HFaultData.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -30,7 +30,7 @@
private String _name;
private String _explanation;
- private HLargeData _data;
+ private byte[] _data;
private int _lineNo;
private int _activityId;
@@ -46,16 +46,18 @@
}
/**
- * @hibernate.many-to-one column="LDATA_ID" cascade="delete"
foreign-key="none"
+ * @hibernate.property type="org.apache.ode.daohib.bpel.hobj.GZipDataType"
+ *
+ * @hibernate.column name="DATA" sql-type="blob(2G)"
*/
- public HLargeData getData() {
+ public byte[] getData() {
return _data;
}
- public void setData(HLargeData data) {
+ public void setData(byte[] data) {
_data = data;
}
-
+
/**
* @hibernate.property column="EXPLANATION" length="4000"
*/
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HLargeData.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HLargeData.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HLargeData.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -1,96 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- *
http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-package org.apache.ode.daohib.bpel.hobj;
-
-/**
- * Used to store large data sets into a single table. When an HObject
- * instance needs to store as part of its state large binary or text
- * data, a reference to an instance of this class must be created.
- * @hibernate.class table="LARGE_DATA"
- * @hibernate.query name="SELECT_ACTIVITY_RECOVERY_LDATA_IDS_BY_INSTANCES"
query="select a.details.id from HActivityRecovery as a where a.instance in
(:instances)"
- * @hibernate.query name="SELECT_JACOB_LDATA_IDS_BY_INSTANCES"
query="select i.jacobState.id from HProcessInstance as i where i in
(:instances)"
- * @hibernate.query name="SELECT_MESSAGE_LDATA_IDS_BY_INSTANCES_1"
query="select m.messageData.id from HMessage m where m.messageExchange.instance in
(:instances)"
- * @hibernate.query name="SELECT_MESSAGE_LDATA_IDS_BY_INSTANCES_2"
query="select m.header.id from HMessage m where m.messageExchange.instance in
(:instances)"
- * @hibernate.query name="SELECT_MEX_LDATA_IDS_BY_INSTANCES_1"
query="select e.endpoint.id from HMessageExchange as e where e.instance in
(:instances)"
- * @hibernate.query name="SELECT_MEX_LDATA_IDS_BY_INSTANCES_2"
query="select e.callbackEndpoint.id from HMessageExchange as e where e.instance in
(:instances)"
- *
- * @hibernate.query name="SELECT_EVENT_LDATA_IDS_BY_INSTANCES"
query="select e.data.id from HBpelEvent as e where e.instance in (:instances)"
- * @hibernate.query name="SELECT_UNMATCHED_MESSAGE_LDATA_IDS_BY_INSTANCES_1"
query="select m.messageData.id from HMessage m, HCorrelatorMessage cm where
m.messageExchange = cm.messageExchange and m.messageExchange.instance in
(:instances)"
- * @hibernate.query name="SELECT_UNMATCHED_MESSAGE_LDATA_IDS_BY_INSTANCES_2"
query="select m.header.id from HMessage m, HCorrelatorMessage cm where
m.messageExchange = cm.messageExchange and m.messageExchange.instance in
(:instances)"
- * @hibernate.query name="SELECT_XMLDATA_LDATA_IDS_BY_INSTANCES"
query="select x.data.id from HXmlData as x where x.instance in (:instances)"
- * @hibernate.query name="SELECT_PARTNER_LINK_LDATA_IDS_BY_INSTANCES_1"
query="select l.myEPR.id from HPartnerLink as l where l.scope.instance in
(:instances)"
- * @hibernate.query name="SELECT_PARTNER_LINK_LDATA_IDS_BY_INSTANCES_2"
query="select l.partnerEPR.id from HPartnerLink as l where l.scope.instance in
(:instances)"
- * @hibernate.query name="SELECT_FAULT_LDATA_IDS_BY_INSTANCE_IDS"
query="select f.data.id from HFaultData as f, HProcessInstance as i where f.id =
i.fault and i.id in (:instanceIds)"
-
- * @hibernate.query name="SELECT_MESSAGE_LDATA_IDS_BY_MEX_1" query="select
m.messageData.id from HMessage m where m.messageExchange = :mex"
- * @hibernate.query name="SELECT_MESSAGE_LDATA_IDS_BY_MEX_2" query="select
m.header.id from HMessage m where m.messageExchange = :mex"
- */
-public class HLargeData extends HObject {
- public final static String SELECT_ACTIVITY_RECOVERY_LDATA_IDS_BY_INSTANCES =
"SELECT_ACTIVITY_RECOVERY_LDATA_IDS_BY_INSTANCES";
- public final static String SELECT_JACOB_LDATA_IDS_BY_INSTANCES =
"SELECT_JACOB_LDATA_IDS_BY_INSTANCES";
- public final static String SELECT_MESSAGE_LDATA_IDS_BY_INSTANCES_1 =
"SELECT_MESSAGE_LDATA_IDS_BY_INSTANCES_1";
- public final static String SELECT_MESSAGE_LDATA_IDS_BY_INSTANCES_2 =
"SELECT_MESSAGE_LDATA_IDS_BY_INSTANCES_2";
- public final static String SELECT_MEX_LDATA_IDS_BY_INSTANCES_1 =
"SELECT_MEX_LDATA_IDS_BY_INSTANCES_1";
- public final static String SELECT_MEX_LDATA_IDS_BY_INSTANCES_2 =
"SELECT_MEX_LDATA_IDS_BY_INSTANCES_2";
-
- public final static String SELECT_EVENT_LDATA_IDS_BY_INSTANCES =
"SELECT_EVENT_LDATA_IDS_BY_INSTANCES";
- public final static String SELECT_UNMATCHED_MESSAGE_LDATA_IDS_BY_INSTANCES_1 =
"SELECT_UNMATCHED_MESSAGE_LDATA_IDS_BY_INSTANCES_1";
- public final static String SELECT_UNMATCHED_MESSAGE_LDATA_IDS_BY_INSTANCES_2 =
"SELECT_UNMATCHED_MESSAGE_LDATA_IDS_BY_INSTANCES_2";
- public final static String SELECT_XMLDATA_LDATA_IDS_BY_INSTANCES =
"SELECT_XMLDATA_LDATA_IDS_BY_INSTANCES";
- public final static String SELECT_PARTNER_LINK_LDATA_IDS_BY_INSTANCES_1 =
"SELECT_PARTNER_LINK_LDATA_IDS_BY_INSTANCES_1";
- public final static String SELECT_PARTNER_LINK_LDATA_IDS_BY_INSTANCES_2 =
"SELECT_PARTNER_LINK_LDATA_IDS_BY_INSTANCES_2";
- public final static String SELECT_FAULT_LDATA_IDS_BY_INSTANCE_IDS =
"SELECT_FAULT_LDATA_IDS_BY_INSTANCE_IDS";
-
- public final static String SELECT_MESSAGE_LDATA_IDS_BY_MEX_1 =
"SELECT_MESSAGE_LDATA_IDS_BY_MEX_1";
- public final static String SELECT_MESSAGE_LDATA_IDS_BY_MEX_2 =
"SELECT_MESSAGE_LDATA_IDS_BY_MEX_2";
-
- private byte[] binary = null;
-
- public HLargeData() {
- super();
- }
-
- public HLargeData(byte[] binary) {
- super();
- this.binary = binary;
- }
-
- public HLargeData(String text) {
- super();
- this.binary = text.getBytes();
- }
-
- /**
- * @hibernate.property type="binary" length="2G"
- *
- * @hibernate.column name="BIN_DATA" sql-type="blob(2G)"
- */
- public byte[] getBinary() {
- return binary;
- }
-
- public void setBinary(byte[] binary) {
- this.binary = binary;
- }
-
- public String getText() {
- return new String(binary);
- }
-}
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HMessage.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HMessage.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HMessage.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -24,15 +24,17 @@
* @hibernate.class table="BPEL_MESSAGE"
* @hibernate.query name="SELECT_MESSAGE_IDS_BY_MEX" query="select id from
HMessage as m WHERE m.messageExchange = :messageExchange"
* @hibernate.query name="SELECT_MESSAGE_IDS_BY_INSTANCES" query="select
m.id from HMessage m, HMessageExchange mex WHERE m.messageExchange = mex and mex.instance
in (:instances)"
+ * @hibernate.query name="SELECT_MESSAGES_BY_INSTANCES" query="select m
from HMessage m, HMessageExchange mex WHERE m.messageExchange = :mex"
*/
public class HMessage extends HObject {
public final static String SELECT_MESSAGE_IDS_BY_MEX =
"SELECT_MESSAGE_IDS_BY_MEX";
public final static String SELECT_MESSAGE_IDS_BY_INSTANCES =
"SELECT_MESSAGE_IDS_BY_INSTANCES";
+ public final static String SELECT_MESSAGES_BY_INSTANCES =
"SELECT_MESSAGES_BY_INSTANCES";
private HMessageExchange _mex;
private String _type;
- private HLargeData _data;
- private HLargeData _header;
+ private byte[] _data;
+ private byte[] _header;
public void setMessageExchange(HMessageExchange mex) {
_mex = mex;
@@ -53,22 +55,28 @@
}
/**
- * @hibernate.many-to-one column="DATA" lazy="false"
outer-join="true" foreign-key="none"
- * */
- public HLargeData getMessageData() {
+ * @hibernate.property type="org.apache.ode.daohib.bpel.hobj.GZipDataType"
+ *
+ * @hibernate.column name="MESSAGE_DATA" sql-type="blob(2G)"
+ */
+ public byte[] getMessageData() {
return _data;
}
- public void setMessageData(HLargeData data) {
+ public void setMessageData(byte[] data) {
_data = data;
}
- /** @hibernate.many-to-one column="HEADER" lazy="false"
outer-join="true" foreign-key="none" */
- public HLargeData getHeader() {
+ /**
+ * @hibernate.property type="org.apache.ode.daohib.bpel.hobj.GZipDataType"
+ *
+ * @hibernate.column name="MESSAGE_HEADER" sql-type="blob(2G)"
+ */
+ public byte[] getHeader() {
return _header;
}
- public void setHeader(HLargeData header) {
+ public void setHeader(byte[] header) {
_header = header;
}
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HMessageExchange.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HMessageExchange.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HMessageExchange.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -44,10 +44,10 @@
private String _portType;
- private HLargeData _endpoint;
-
- private HLargeData _callbackEndpoint;
-
+ private byte[] _endpoint;
+
+ private byte[] _callbackEndpoint;
+
private HMessage _request;
private HMessage _response;
@@ -121,24 +121,28 @@
}
/**
- * @hibernate.many-to-one column="LDATA_EPR_ID" cascade="delete"
foreign-key="none"
+ * @hibernate.property type="org.apache.ode.daohib.bpel.hobj.GZipDataType"
+ *
+ * @hibernate.column name="ENDPOINT" sql-type="blob(2G)"
*/
- public HLargeData getEndpoint() {
+ public byte[] getEndpoint() {
return _endpoint;
}
- public void setEndpoint(HLargeData endpoint) {
+ public void setEndpoint(byte[] endpoint) {
_endpoint = endpoint;
}
- /**
- * @hibernate.many-to-one column="LDATA_CEPR_ID" cascade="delete"
foreign-key="none"
+ /**
+ * @hibernate.property type="org.apache.ode.daohib.bpel.hobj.GZipDataType"
+ *
+ * @hibernate.column name="CALLBACK_ENDPOINT"
sql-type="blob(2G)"
*/
- public HLargeData getCallbackEndpoint() {
+ public byte[] getCallbackEndpoint() {
return _callbackEndpoint;
}
- public void setCallbackEndpoint(HLargeData endpoint) {
+ public void setCallbackEndpoint(byte[] endpoint) {
_callbackEndpoint = endpoint;
}
@@ -305,8 +309,7 @@
}
/**
- * @hibernate.map name="properties" table="BPEL_MEX_PROPS"
lazy="true"
- * cascade="delete"
+ * @hibernate.map name="properties" table="BPEL_MEX_PROPS"
lazy="true" cascade="delete"
* @hibernate.collection-key name="mex" column="MEX"
foreign-key="none"
* @hibernate.collection-index column="NAME" type="string"
* @hibernate.collection-element column="VALUE" type="string"
length="8000"
@@ -355,4 +358,5 @@
public void incrementSubscriberCount() {
setSubscriberCount(getSubscriberCount() + 1);
}
+
}
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HObject.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HObject.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HObject.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -54,7 +54,9 @@
/**
* Auto-generated primary key.
*
- * @hibernate.id generator-class="native" column="ID"
+ * @hibernate.id
generator-class="org.apache.ode.daohib.NativeHiLoGenerator"
column="ID"
+ * @hibernate.generator-param name="sequence"
value="hibernate_seqhilo"
+ * @hibernate.generator-param name="max_lo" value="99"
*/
public Long getId() {
return _id;
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HPartnerLink.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HPartnerLink.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HPartnerLink.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -41,10 +41,10 @@
private String _svcName;
- private HLargeData _myEPR;
-
- private HLargeData _partnerEPR;
-
+ private byte[] _myEPR;
+
+ private byte[] _partnerEPR;
+
private HScope _scope;
private HProcess _process;
@@ -84,25 +84,29 @@
}
/**
- * @hibernate.many-to-one column="MYROLE_EPR" cascade="delete"
foreign-key="none"
+ * @hibernate.property type="org.apache.ode.daohib.bpel.hobj.GZipDataType"
+ *
+ * @hibernate.column name="MYROLE_EPR_DATA" sql-type="blob(2G)"
*/
- public HLargeData getMyEPR() {
+ public byte[] getMyEPR() {
return _myEPR;
}
- public void setMyEPR(HLargeData data) {
- _myEPR = data;
+ public void setMyEPR(byte[] myEPR) {
+ _myEPR = myEPR;
}
/**
- * @hibernate.many-to-one column="PARTNERROLE_EPR"
cascade="delete" foreign-key="none"
+ * @hibernate.property type="org.apache.ode.daohib.bpel.hobj.GZipDataType"
+ *
+ * @hibernate.column name="PARTNERROLE_EPR_DATA"
sql-type="blob(2G)"
*/
- public HLargeData getPartnerEPR() {
+ public byte[] getPartnerEPR() {
return _partnerEPR;
}
- public void setPartnerEPR(HLargeData data) {
- _partnerEPR = data;
+ public void setPartnerEPR(byte[] partnerEPR) {
+ _partnerEPR = partnerEPR;
}
/**
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HProcessInstance.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HProcessInstance.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HProcessInstance.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -28,14 +28,16 @@
* Hibernate table representing a BPEL process instance.
*
* @hibernate.class table="BPEL_INSTANCE" dynamic-update="true"
lazy="true"
- * @hibernate.query name="COUNT_FAILED_INSTANCES_BY_PROCESS_IDS_AND_STATES"
query="select count(i.id) as cnt, max(i.activityFailureDateTime) as lastFailureDt
from HProcessInstance as i where i.process.processId in (:processIds) and i.state
in(:states) and i.activityFailureCount > 0"
+ * @hibernate.query name="COUNT_FAILED_INSTANCES_BY_PROCESSES_IDS_AND_STATES"
query="select i.process.processId as pid, count(i.id) as cnt,
max(i.activityFailureDateTime) as lastFailureDt from HProcessInstance as i where
i.process.processId in (:processIds) and i.state = 20 and i.activityFailureCount > 0
group by i.process.processId"
* @hibernate.query name="SELECT_INSTANCES_BY_PROCESS" query="from
HProcessInstance as i where i.process = :process)"
* @hibernate.query name="SELECT_INSTANCES_BY_PROCESS_AND_STATES"
query="from HProcessInstance as i where i.process = :process and i.state in
(:states)"
+ * @hibernate.query name="COUNT_INSTANCES_BY_PROCESSES_IDS_AND_STATES"
query="select i.process.processId as pid, count(i.id) as cnt from HProcessInstance as
i where i.process.processId in (:processIds) and i.state in(:states) group by
i.process.processId"
*/
public class HProcessInstance extends HObject {
- public static final String
COUNT_FAILED_INSTANCES_BY_PROCESS_IDS_AND_STATES="COUNT_FAILED_INSTANCES_BY_PROCESS_IDS_AND_STATES";
+ public static final String
COUNT_FAILED_INSTANCES_BY_PROCESSES_IDS_AND_STATES="COUNT_FAILED_INSTANCES_BY_PROCESSES_IDS_AND_STATES";
public static final String
SELECT_INSTANCES_BY_PROCESS="SELECT_INSTANCES_BY_PROCESS";
public static final String
SELECT_INSTANCES_BY_PROCESS_AND_STATES="SELECT_INSTANCES_BY_PROCESS_AND_STATES";
+ public static final String COUNT_INSTANCES_BY_PROCESSES_IDS_AND_STATES =
"COUNT_INSTANCES_BY_PROCESSES_IDS_AND_STATES";
/** Foreign key to owner {@link HProcess}. */
private HProcess _process;
@@ -59,8 +61,8 @@
private HFaultData _fault;
- private HLargeData _jacobState;
-
+ private byte[] _jacobState;
+
private short _previousState;
private short _state;
@@ -105,13 +107,15 @@
}
/**
- * @hibernate.many-to-one column="JACOB_STATE"
foreign-key="none"
+ * @hibernate.property type="org.apache.ode.daohib.bpel.hobj.GZipDataType"
+ *
+ * @hibernate.column name="JACOB_STATE_DATA" sql-type="blob(2G)"
*/
- public HLargeData getJacobState() {
+ public byte[] getJacobState() {
return _jacobState;
}
- public void setJacobState(HLargeData jacobState) {
+ public void setJacobState(byte[] jacobState) {
_jacobState = jacobState;
}
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HXmlData.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HXmlData.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/main/java/org/apache/ode/daohib/bpel/hobj/HXmlData.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -26,11 +26,11 @@
* @hibernate.class table="BPEL_XML_DATA"
* @hibernate.query name="SELECT_XMLDATA_IDS_BY_INSTANCES" query="select
id from HXmlData as x where x.instance in (:instances)"
*/
-public class HXmlData extends HObject{
+public class HXmlData extends HObject {
public static final String SELECT_XMLDATA_IDS_BY_INSTANCES =
"SELECT_XMLDATA_IDS_BY_INSTANCES";
private boolean _simpleType;
- private HLargeData _data;
+ private byte[] _data;
private Collection<HVariableProperty> _properties = new
HashSet<HVariableProperty>();
private String _name;
private HScope _scope;
@@ -42,13 +42,15 @@
}
/**
- * @hibernate.many-to-one column="LDATA_ID" cascade="delete"
foreign-key="none"
+ * @hibernate.property type="org.apache.ode.daohib.bpel.hobj.GZipDataType"
+ *
+ * @hibernate.column name="DATA" sql-type="blob(2G)"
*/
- public HLargeData getData() {
+ public byte[] getData() {
return _data;
}
- public void setData(HLargeData data) {
+ public void setData(byte[] data) {
_data = data;
}
Modified:
branches/ODE/ODE-1.x/dao-hibernate/src/test/java/org/apache/ode/daohib/bpel/BaseTestDAO.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/test/java/org/apache/ode/daohib/bpel/BaseTestDAO.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/test/java/org/apache/ode/daohib/bpel/BaseTestDAO.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -19,15 +19,15 @@
package org.apache.ode.daohib.bpel;
+import javax.resource.spi.ConnectionManager;
import javax.sql.DataSource;
import javax.transaction.TransactionManager;
import junit.framework.TestCase;
+import org.apache.derby.jdbc.EmbeddedXADataSource;
import org.apache.ode.bpel.dao.BpelDAOConnection;
import org.apache.ode.il.EmbeddedGeronimoFactory;
-import org.apache.ode.utils.GUID;
-import org.hsqldb.jdbc.jdbcDataSource;
import org.hibernate.cfg.Environment;
import java.util.Properties;
@@ -38,14 +38,16 @@
* test that the result is the one expected would take a huge test database
* (with at least a process and an instance for every possible combination).
*/
-public class BaseTestDAO extends TestCase {
+public abstract class BaseTestDAO extends TestCase {
protected BpelDAOConnection daoConn;
- private TransactionManager txm;
+ protected TransactionManager txm;
+ protected ConnectionManager connectionManager;
private DataSource ds;
protected void initTM() throws Exception {
EmbeddedGeronimoFactory factory = new EmbeddedGeronimoFactory();
+ connectionManager = new
org.apache.geronimo.connector.outbound.GenericConnectionManager();
txm = factory.getTransactionManager();
ds = getDataSource();
txm.begin();
@@ -66,11 +68,12 @@
protected DataSource getDataSource() {
if (ds == null) {
- jdbcDataSource hsqlds = new jdbcDataSource();
- hsqlds.setDatabase("jdbc:hsqldb:mem:" + new GUID().toString());
- hsqlds.setUser("sa");
- hsqlds.setPassword("");
- ds = hsqlds;
+ EmbeddedXADataSource ds = new EmbeddedXADataSource();
+ ds.setCreateDatabase("create");
+ ds.setDatabaseName("target/testdb");
+ ds.setUser("sa");
+ ds.setPassword("");
+ this.ds = ds;
}
return ds;
}
Added:
branches/ODE/ODE-1.x/dao-hibernate/src/test/java/org/apache/ode/daohib/bpel/ProcessManagementDaoTest.java
===================================================================
---
branches/ODE/ODE-1.x/dao-hibernate/src/test/java/org/apache/ode/daohib/bpel/ProcessManagementDaoTest.java
(rev 0)
+++
branches/ODE/ODE-1.x/dao-hibernate/src/test/java/org/apache/ode/daohib/bpel/ProcessManagementDaoTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,76 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.ode.daohib.bpel;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+
+import javax.xml.namespace.QName;
+
+import org.apache.ode.bpel.common.InstanceFilter;
+import org.apache.ode.bpel.common.ProcessState;
+import org.apache.ode.bpel.dao.ProcessDAO;
+import org.apache.ode.bpel.dao.ProcessInstanceDAO;
+import org.apache.ode.bpel.dao.ProcessManagementDAO.FailedSummaryValue;
+import org.apache.ode.bpel.dao.ProcessManagementDAO.InstanceSummaryKey;
+
+/**
+ * Testing BpelDAOConnectionImpl.listInstance. We're just producing a lot of
+ * different filter combinations and test if they execute ok. To really test
+ * that the result is the one expected would take a huge test database (with at
+ * least a process and an instance for every possible combination).
+ */
+public class ProcessManagementDaoTest extends BaseTestDAO {
+
+ protected void setUp() throws Exception {
+ initTM();
+ }
+
+ protected void tearDown() throws Exception {
+ stopTM();
+ }
+
+ public void testInstanceSummary() throws Exception {
+ Set<String> pids = new HashSet<String>();
+ QName pid = QName.valueOf("{ns}pid");
+ pids.add(pid.toString());
+ ProcessDAO p = daoConn.createProcess(pid, QName.valueOf("{ns}type"),
"abc", 1);
+ ProcessInstanceDAO i = p.createInstance(p.addCorrelator("cor"));
+ i.setState(ProcessState.STATE_COMPLETED_OK);
+ Map<InstanceSummaryKey, Long> r =
daoConn.getProcessManagement().countInstancesSummary(pids);
+ System.out.println("resultSummary:" + r);
+ assertEquals(1, r.size());
+ }
+
+ public void testInstanceSummaryFailures() throws Exception {
+ Set<String> pids = new HashSet<String>();
+ QName pid = QName.valueOf("{ns}pid");
+ pids.add(pid.toString());
+ ProcessDAO p = daoConn.createProcess(pid, QName.valueOf("{ns}type"),
"abc", 1);
+ ProcessInstanceDAO i = p.createInstance(p.addCorrelator("cor"));
+ Map<String, FailedSummaryValue> r =
daoConn.getProcessManagement().findFailedCountAndLastFailedDateForProcessIds(pids);
+ System.out.println("resultSummary:" + r);
+ assertEquals(0, r.size());
+ }
+}
Added: branches/ODE/ODE-1.x/dao-hibernate/src/test/resources/log4j.properties
===================================================================
--- branches/ODE/ODE-1.x/dao-hibernate/src/test/resources/log4j.properties
(rev 0)
+++ branches/ODE/ODE-1.x/dao-hibernate/src/test/resources/log4j.properties 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,33 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+#
http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+# implied.
+#
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+#
+
+#
+# The logging properties used during tests..
+#
+log4j.rootLogger=DEBUG, file
+#log4j.rootLogger=INFO, file
+
+log4j.appender.file=org.apache.log4j.FileAppender
+log4j.appender.file.File=target/test/test.log
+log4j.appender.file.layout=org.apache.log4j.PatternLayout
+log4j.appender.file.layout.ConversionPattern=%d{MM-dd@HH:mm:ss} %-5p (%13F:%L) %3x - %m%n
+
+log4j.category.org.apache.ode=DEBUG
+
Added: branches/ODE/ODE-1.x/dao-hibernate-db/build.xml
===================================================================
--- branches/ODE/ODE-1.x/dao-hibernate-db/build.xml (rev 0)
+++ branches/ODE/ODE-1.x/dao-hibernate-db/build.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,105 @@
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+
+ <property name="db.scripts.dir" value="${basedir}/target" />
+ <property name="sql.dir" value="${basedir}/src/main/sql"/>
+ <property name="dao-hibernate.classes"
value="${basedir}/../dao-hibernate/target/classes" />
+ <property name="bpel-store.classes"
value="${basedir}/../bpel-store/target/classes" />
+
+ <path id="classpath">
+ <pathelement path="${maven.runtime.classpath}"/>
+ </path>
+
+ <target name="create-schema">
+
+ <taskdef name="schemaexport"
classname="org.hibernate.tool.hbm2ddl.SchemaExportTask"
+ classpathref="classpath"/>
+
+ <mkdir dir="target"/>
+ <mkdir dir="${db.scripts.dir}" />
+
+ <!-- Derby -->
+ <create-ddl db="derby"/>
+
+ <!-- MySQL -->
+ <create-ddl db="mysql"/>
+
+ <!-- Oracle -->
+ <create-ddl db="oracle"/>
+
+ <!-- PostgreSQL -->
+ <create-ddl db="postgres"/>
+
+ <!-- Sybase -->
+ <create-ddl db="hsql" />
+
+ <!-- MSSQL -->
+ <create-ddl db="sqlserver" />
+
+ <!-- Firebird -->
+ <create-ddl db="firebird" />
+
+ </target>
+
+ <target name="zip-derby-db">
+ <zip
destfile="${basedir}/target/ode-dao-hibernate-db-${ode.version}.zip"
basedir="${basedir}/target/derby/" />
+
+ </target>
+
+ <!--
+ ============================================
+ Macro defs, no need to change anything below
+ ============================================
+ -->
+
+ <macrodef name="create-ddl">
+ <attribute name="db"/>
+
+ <sequential>
+ <echo></echo>
+ <echo>=====================</echo>
+ <echo>Create DDL @{db}</echo>
+ <schemaexport
+ properties="${sql.dir}/ode.(a){db}.properties"
+ quiet="yes"
+ text="yes"
+ create="yes"
+ delimiter=";"
+ output="${db.scripts.dir}/partial.(a){db}.sql">
+ <fileset dir="${dao-hibernate.classes}/">
+ <include name="**/*.hbm.xml"/>
+ <exclude name="**/HMessageExchangeProperty.hbm.xml"
/>
+ </fileset>
+ <fileset dir="${bpel-store.classes}/">
+ <include name="**/*.hbm.xml"/>
+ </fileset>
+ </schemaexport>
+ <concat destfile="${db.scripts.dir}/(a){db}.sql">
+ <fileset file="${sql.dir}/simplesched-(a){db}.sql"/>
+ <fileset file="${db.scripts.dir}/partial.(a){db}.sql"/>
+ </concat>
+ <echo>Done.</echo>
+ <echo>=====================</echo>
+ </sequential>
+ </macrodef>
+
+</project>
+
Added: branches/ODE/ODE-1.x/dao-hibernate-db/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/dao-hibernate-db/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/dao-hibernate-db/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,130 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-dao-hibernate-db</artifactId>
+ <name>ODE :: Hibernate DAO DDL Generation</name>
+
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.hibernate</groupId>
+ <artifactId>hibernate</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-log4j12</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>log4j</groupId>
+ <artifactId>log4j</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.derby</groupId>
+ <artifactId>derby</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.derby</groupId>
+ <artifactId>derbytools</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-dao-hibernate</artifactId>
+ </dependency>
+ </dependencies>
+ <build>
+
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-antrun-plugin</artifactId>
+ <version>1.0</version>
+ <executions>
+ <execution>
+ <id>schemagen</id>
+ <phase>generate-sources</phase>
+ <configuration>
+ <tasks>
+ <property name="maven.runtime.classpath"
refid="maven.compile.classpath"/>
+ <ant antfile="build.xml" target="create-schema"
inheritRefs="true"/>
+ </tasks>
+ </configuration>
+ <goals>
+ <goal>run</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>sql-maven-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>create-derby-db</id>
+ <phase>process-resources</phase>
+ <goals>
+ <goal>execute</goal>
+ </goals>
+ <configuration>
+ <driver>org.apache.derby.jdbc.EmbeddedDriver</driver>
+
<url>jdbc:derby:${basedir}/target/derby/hibdb;create=true</url>
+ <username>sa</username>
+ <password />
+ <autocommit>true</autocommit>
+ <onError>continue</onError>
+ <srcFiles>
+ <srcFile>target/derby.sql</srcFile>
+ </srcFiles>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ <plugin>
+ <artifactId>maven-antrun-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>zip-derby-db</id>
+ <phase>package</phase>
+ <goals>
+ <goal>run</goal>
+ </goals>
+ <configuration>
+ <tasks>
+ <property name="ode.version"
value="${project.version}"/>
+ <ant antfile="build.xml" target="zip-derby-db" />
+ </tasks>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+</project>
Modified: branches/ODE/ODE-1.x/dao-hibernate-db/src/main/sql/common.sql
===================================================================
--- branches/ODE/ODE-1.x/dao-hibernate-db/src/main/sql/common.sql 2010-04-14 15:43:12 UTC
(rev 619)
+++ branches/ODE/ODE-1.x/dao-hibernate-db/src/main/sql/common.sql 2010-04-14 18:25:55 UTC
(rev 620)
@@ -1,2 +1,2 @@
create table ODE_SCHEMA_VERSION(VERSION integer);
-insert into ODE_SCHEMA_VERSION values (5);
+insert into ODE_SCHEMA_VERSION values (6);
Added: branches/ODE/ODE-1.x/dao-jpa/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/dao-jpa/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/dao-jpa/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,124 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<project>
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-dao-jpa</artifactId>
+ <name>ODE :: OpenJPA DAO Impl</name>
+
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <dependencies>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-j2ee-connector_1.5_spec</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-jta_1.1_spec</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>javax.persistence</groupId>
+ <artifactId>persistence-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-logging</groupId>
+ <artifactId>commons-logging</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-collections</groupId>
+ <artifactId>commons-collections</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-dao</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-utils</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>xerces</groupId>
+ <artifactId>xercesImpl</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>xerces</groupId>
+ <artifactId>xmlParserAPIs</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.openjpa</groupId>
+ <artifactId>openjpa</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>net.sourceforge.serp</groupId>
+ <artifactId>serp</artifactId>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <artifactId>maven-antrun-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>openjpa-enhancer</id>
+ <phase>process-classes</phase>
+ <goals>
+ <goal>run</goal>
+ </goals>
+ <configuration>
+ <tasks>
+ <property name="maven.runtime.classpath"
refid="maven.compile.classpath"/>
+ <path id="classpath">
+ <pathelement path="${maven.runtime.classpath}"/>
+ </path>
+ <taskdef name="openjpac"
classname="org.apache.openjpa.ant.PCEnhancerTask"
classpathref="classpath"/>
+ <openjpac>
+ <fileset dir="${basedir}/src/main">
+ <include name="**/*.java" />
+ </fileset>
+ <classpath>
+ <pathelement location="${basedir}/target/classes"/>
+ <pathelement path="${maven.runtime.classpath}"/>
+ </classpath>
+ </openjpac>
+ </tasks>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+
+
+</project>
Modified:
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/BPELDAOConnectionFactoryImpl.java
===================================================================
---
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/BPELDAOConnectionFactoryImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/BPELDAOConnectionFactoryImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -93,13 +93,13 @@
HashMap<String, Object> propMap = new HashMap<String,Object>();
// propMap.put("openjpa.Log", "DefaultLevel=TRACE");
- propMap.put("openjpa.Log", "log4j");
+ propMap.put("openjpa.Log", "commons");
// propMap.put("openjpa.jdbc.DBDictionary",
"org.apache.openjpa.jdbc.sql.DerbyDictionary");
propMap.put("openjpa.ManagedRuntime", new JpaTxMgrProvider(_tm));
propMap.put("openjpa.ConnectionFactory", _ds);
propMap.put("openjpa.ConnectionFactoryMode", "managed");
- propMap.put("openjpa.FlushBeforeQueries", "false");
+// propMap.put("openjpa.FlushBeforeQueries", "false");
propMap.put("openjpa.FetchBatchSize", 1000);
propMap.put("openjpa.jdbc.TransactionIsolation",
"read-committed");
@@ -141,4 +141,4 @@
public DataSource getDataSource() {
return _ds;
}
-}
\ No newline at end of file
+}
Modified:
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/CorrelatorDAOImpl.java
===================================================================
---
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/CorrelatorDAOImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/CorrelatorDAOImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -19,6 +19,8 @@
package org.apache.ode.dao.jpa;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
import org.apache.ode.bpel.common.CorrelationKeySet;
import org.apache.ode.bpel.dao.*;
@@ -29,42 +31,49 @@
import java.util.List;
@Entity
-@Table(name="ODE_CORRELATOR")
-@NamedQueries({
- @NamedQuery(name=CorrelatorDAOImpl.DELETE_CORRELATORS_BY_PROCESS, query="delete
from CorrelatorDAOImpl as c where c._process = :process")
-})
+@Table(name = "ODE_CORRELATOR")
+@NamedQueries( { @NamedQuery(name = CorrelatorDAOImpl.DELETE_CORRELATORS_BY_PROCESS,
query = "delete from CorrelatorDAOImpl as c where c._process = :process") })
public class CorrelatorDAOImpl extends OpenJPADAO implements CorrelatorDAO {
- public final static String DELETE_CORRELATORS_BY_PROCESS =
"DELETE_CORRELATORS_BY_PROCESS";
- private final static String ROUTE_BY_CKEY_HEADER = "select route from
MessageRouteDAOImpl as route where route._correlator._process._processType = :ptype and
route._correlator._correlatorKey = :corrkey";
-
- @Id @Column(name="CORRELATOR_ID")
- @GeneratedValue(strategy=GenerationType.AUTO)
+ private static Log __log = LogFactory.getLog(CorrelatorDAOImpl.class);
+ public final static String DELETE_CORRELATORS_BY_PROCESS =
"DELETE_CORRELATORS_BY_PROCESS";
+ private final static String ROUTE_BY_CKEY_HEADER = "select route from
MessageRouteDAOImpl as route where route._correlator._process._processType = :ptype and
route._correlator._correlatorKey = :corrkey";
+
+ @Id
+ @Column(name = "CORRELATOR_ID")
+ @GeneratedValue(strategy = GenerationType.AUTO)
@SuppressWarnings("unused")
private Long _correlatorId;
- @Basic @Column(name="CORRELATOR_KEY")
+ @Basic
+ @Column(name = "CORRELATOR_KEY")
private String _correlatorKey;
-
@OneToMany(targetEntity=MessageRouteDAOImpl.class,mappedBy="_correlator",fetch=FetchType.EAGER,cascade={CascadeType.MERGE,
CascadeType.PERSIST, CascadeType.REFRESH})
+ @OneToMany(targetEntity = MessageRouteDAOImpl.class, mappedBy =
"_correlator", fetch = FetchType.EAGER, cascade = { CascadeType.MERGE,
CascadeType.PERSIST, CascadeType.REFRESH })
private Collection<MessageRouteDAOImpl> _routes = new
ArrayList<MessageRouteDAOImpl>();
-
@OneToMany(targetEntity=MessageExchangeDAOImpl.class,mappedBy="_correlator",fetch=FetchType.LAZY,cascade={CascadeType.MERGE,
CascadeType.PERSIST, CascadeType.REFRESH})
+ @OneToMany(targetEntity = MessageExchangeDAOImpl.class, mappedBy =
"_correlator", fetch = FetchType.LAZY, cascade = { CascadeType.MERGE,
CascadeType.PERSIST, CascadeType.REFRESH })
private Collection<MessageExchangeDAOImpl> _exchanges = new
ArrayList<MessageExchangeDAOImpl>();
- @ManyToOne(fetch= FetchType.LAZY,cascade={CascadeType.PERSIST})
@Column(name="PROC_ID")
+ @ManyToOne(fetch = FetchType.LAZY, cascade = { CascadeType.PERSIST })
+ @Column(name = "PROC_ID")
private ProcessDAOImpl _process;
- public CorrelatorDAOImpl(){}
+ public CorrelatorDAOImpl() {
+ }
+
public CorrelatorDAOImpl(String correlatorKey, ProcessDAOImpl process) {
_correlatorKey = correlatorKey;
_process = process;
}
public void addRoute(String routeGroupId, ProcessInstanceDAO target, int index,
CorrelationKeySet correlationKeySet, String routePolicy) {
- MessageRouteDAOImpl mr = new MessageRouteDAOImpl(correlationKeySet,
- routeGroupId, index, (ProcessInstanceDAOImpl) target, this,
routePolicy);
+ if (__log.isDebugEnabled()) {
+ __log.debug("addRoute " + routeGroupId + " " + target +
" " + index + " " + correlationKeySet + " " + routePolicy);
+ }
+ MessageRouteDAOImpl mr = new MessageRouteDAOImpl(correlationKeySet, routeGroupId,
index, (ProcessInstanceDAOImpl) target, this, routePolicy);
_routes.add(mr);
+ getEM().flush();
}
public MessageExchangeDAO dequeueMessage(CorrelationKeySet correlationKeySet) {
- // TODO: this thing does not seem to be scalable: loading up based on a
correlator???
- for (Iterator<MessageExchangeDAOImpl> itr=_exchanges.iterator();
itr.hasNext();){
+ // TODO: this thing does not seem to be scalable: loading up based on a
correlator???
+ for (Iterator<MessageExchangeDAOImpl> itr = _exchanges.iterator();
itr.hasNext();) {
MessageExchangeDAOImpl mex = itr.next();
if (mex.getCorrelationKeySet().isRoutableTo(correlationKeySet, false)) {
itr.remove();
@@ -74,8 +83,7 @@
return null;
}
- public void enqueueMessage(MessageExchangeDAO mex,
- CorrelationKeySet correlationKeySet) {
+ public void enqueueMessage(MessageExchangeDAO mex, CorrelationKeySet
correlationKeySet) {
MessageExchangeDAOImpl mexImpl = (MessageExchangeDAOImpl) mex;
mexImpl.setCorrelationKeySet(correlationKeySet);
_exchanges.add(mexImpl);
@@ -88,52 +96,61 @@
@SuppressWarnings("unchecked")
public List<MessageRouteDAO> findRoute(CorrelationKeySet correlationKeySet) {
- List<CorrelationKeySet> subSets = correlationKeySet.findSubSets();
- Query qry = getEM().createQuery(generateSelectorQuery(ROUTE_BY_CKEY_HEADER,
subSets));
+ if (__log.isDebugEnabled()) {
+ __log.debug("findRoute " + correlationKeySet);
+ }
+ List<CorrelationKeySet> subSets = correlationKeySet.findSubSets();
+ Query qry = getEM().createQuery(generateSelectorQuery(ROUTE_BY_CKEY_HEADER,
subSets));
qry.setParameter("ptype", _process.getType().toString());
qry.setParameter("corrkey", _correlatorKey);
- for( int i = 0; i < subSets.size(); i++ ) {
- qry.setParameter("s" + i, subSets.get(i).toCanonicalString());
- }
-
+ for (int i = 0; i < subSets.size(); i++) {
+ qry.setParameter("s" + i, subSets.get(i).toCanonicalString());
+ }
+
List<MessageRouteDAO> candidateRoutes = (List<MessageRouteDAO>)
qry.getResultList();
if (candidateRoutes.size() > 0) {
- List<MessageRouteDAO> matchingRoutes = new
ArrayList<MessageRouteDAO>();
- boolean routed = false;
+ List<MessageRouteDAO> matchingRoutes = new
ArrayList<MessageRouteDAO>();
+ boolean routed = false;
for (int i = 0; i < candidateRoutes.size(); i++) {
- MessageRouteDAO route = candidateRoutes.get(i);
- if ("all".equals(route.getRoute())) {
- matchingRoutes.add(route);
- } else {
- if (!routed) {
- matchingRoutes.add(route);
- }
- routed = true;
- }
+ MessageRouteDAO route = candidateRoutes.get(i);
+ if ("all".equals(route.getRoute())) {
+ matchingRoutes.add(route);
+ } else {
+ if (!routed) {
+ matchingRoutes.add(route);
+ }
+ routed = true;
+ }
}
+ if (__log.isDebugEnabled()) {
+ __log.debug("findRoute found " + matchingRoutes);
+ }
return matchingRoutes;
} else {
- return null;
+ if (__log.isDebugEnabled()) {
+ __log.debug("findRoute found nothing");
+ }
+ return null;
}
}
private String generateSelectorQuery(String header, List<CorrelationKeySet>
subSets) {
- StringBuffer filterQuery = new StringBuffer(header);
-
- if( subSets.size() == 1 ) {
- filterQuery.append(" and route._correlationKey = :s0");
- } else if( subSets.size() > 1 ) {
- filterQuery.append(" and route._correlationKey in(");
- for( int i = 0; i < subSets.size(); i++ ) {
- if( i > 0 ) {
- filterQuery.append(", ");
- }
- filterQuery.append(":s").append(i);
- }
- filterQuery.append(")");
- }
-
- return filterQuery.toString();
+ StringBuffer filterQuery = new StringBuffer(header);
+
+ if (subSets.size() == 1) {
+ filterQuery.append(" and route._correlationKey = :s0");
+ } else if (subSets.size() > 1) {
+ filterQuery.append(" and route._correlationKey in(");
+ for (int i = 0; i < subSets.size(); i++) {
+ if (i > 0) {
+ filterQuery.append(", ");
+ }
+ filterQuery.append(":s").append(i);
+ }
+ filterQuery.append(")");
+ }
+
+ return filterQuery.toString();
}
public String getCorrelatorId() {
@@ -146,20 +163,36 @@
public void removeRoutes(String routeGroupId, ProcessInstanceDAO target) {
// remove route across all correlators of the process
- ((ProcessInstanceDAOImpl)target).removeRoutes(routeGroupId);
+ ((ProcessInstanceDAOImpl) target).removeRoutes(routeGroupId);
}
void removeLocalRoutes(String routeGroupId, ProcessInstanceDAO target) {
- for (Iterator<MessageRouteDAOImpl> itr=_routes.iterator(); itr.hasNext(); )
{
+ if (__log.isDebugEnabled()) {
+ __log.debug("removeLocalRoutes " + routeGroupId);
+ }
+ boolean flush = false;
+ for (Iterator<MessageRouteDAOImpl> itr = _routes.iterator();
itr.hasNext();) {
MessageRouteDAOImpl mr = itr.next();
- if ( mr.getGroupId().equals(routeGroupId) &&
mr.getTargetInstance().equals(target)) {
+ if (mr.getGroupId().equals(routeGroupId) &&
mr.getTargetInstance().equals(target)) {
+ if (__log.isDebugEnabled()) {
+ __log.debug("removing " + mr.getCorrelationKey() + "
" + mr.getIndex() + " " + mr.getRoute());
+ }
itr.remove();
getEM().remove(mr);
+ flush = true;
}
}
+ if (flush) {
+ getEM().flush();
+ }
}
public Collection<MessageRouteDAO> getAllRoutes() {
return new ArrayList<MessageRouteDAO>(_routes);
}
+
+ public boolean checkRoute(CorrelationKeySet correlationKeySet) {
+ // TODO Auto-generated method stub
+ return true;
+ }
}
Modified:
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/MessageDAOImpl.java
===================================================================
---
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/MessageDAOImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/MessageDAOImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -19,7 +19,8 @@
package org.apache.ode.dao.jpa;
-
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
import org.apache.ode.bpel.dao.MessageDAO;
import org.apache.ode.bpel.dao.MessageExchangeDAO;
import org.apache.ode.utils.DOMUtils;
@@ -42,71 +43,76 @@
import javax.xml.namespace.QName;
@Entity
-@Table(name="ODE_MESSAGE")
-@NamedQueries({
- @NamedQuery(name=MessageDAOImpl.DELETE_MESSAGES_BY_PROCESS, query="delete from
MessageDAOImpl as m where m._messageExchange._process = :process")
-})
+@Table(name = "ODE_MESSAGE")
+@NamedQueries( { @NamedQuery(name = MessageDAOImpl.DELETE_MESSAGES_BY_PROCESS, query =
"delete from MessageDAOImpl as m where m._messageExchange._process = :process")
})
public class MessageDAOImpl implements MessageDAO {
- public final static String DELETE_MESSAGES_BY_PROCESS =
"DELETE_MESSAGES_BY_PROCESS";
-
- @Id @Column(name="MESSAGE_ID")
- @GeneratedValue(strategy=GenerationType.AUTO)
- @SuppressWarnings("unused")
- private Long _id;
- @Basic @Column(name="TYPE")
+ private static Log __log = LogFactory.getLog(MessageDAOImpl.class);
+ public final static String DELETE_MESSAGES_BY_PROCESS =
"DELETE_MESSAGES_BY_PROCESS";
+
+ @Id
+ @Column(name = "MESSAGE_ID")
+ @GeneratedValue(strategy = GenerationType.AUTO)
+ @SuppressWarnings("unused")
+ private Long _id;
+ @Basic
+ @Column(name = "TYPE")
private String _type;
- @Lob @Column(name="DATA")
+ @Lob
+ @Column(name = "DATA")
private String _data;
- @Lob @Column(name="HEADER")
+ @Lob
+ @Column(name = "HEADER")
private String _header;
- @Transient
- private Element _element;
- @Transient
- private Element _headerElement;
- @ManyToOne(fetch=FetchType.LAZY,cascade={CascadeType.ALL})
@Column(name="MESSAGE_EXCHANGE_ID")
- private MessageExchangeDAOImpl _messageExchange;
+ @ManyToOne(fetch = FetchType.LAZY, cascade = { CascadeType.ALL })
+ @Column(name = "MESSAGE_EXCHANGE_ID")
+ private MessageExchangeDAOImpl _messageExchange;
- public MessageDAOImpl() {
- }
-
- public MessageDAOImpl(QName type, MessageExchangeDAOImpl me) {
- _type = type.toString();
- _messageExchange = me;
- }
-
- public Element getData() {
- if ( _element == null && _data != null && !"".equals(_data))
{
- try {
- _element = DOMUtils.stringToDOM(_data);
- } catch (Exception e) {
- throw new RuntimeException(e);
- }
- }
- return _element;
- }
+ public MessageDAOImpl() {
+ }
- public void setData(Element value) {
- if (value == null) return;
+ public MessageDAOImpl(QName type, MessageExchangeDAOImpl me) {
+ _type = type.toString();
+ _messageExchange = me;
+ }
+
+ public Element getData() {
+ if (__log.isDebugEnabled()) {
+ __log.debug("getData " + _id + " " + _data);
+ }
+ try {
+ return _data == null ? null : DOMUtils.stringToDOM(_data);
+ } catch (Exception e) {
+ throw new RuntimeException(e);
+ }
+ }
+
+ public void setData(Element value) {
+ if (value == null) {
+ if (__log.isDebugEnabled()) {
+ __log.debug("setData " + _id + " null");
+ }
+ return;
+ }
_data = DOMUtils.domToString(value);
- _element = value;
- }
+
+ if (__log.isDebugEnabled()) {
+ __log.debug("setData " + _id + " " + _data);
+ }
+ }
- public Element getHeader() {
- if ( _headerElement == null && _header != null &&
!"".equals(_header)) {
- try {
- _headerElement = DOMUtils.stringToDOM(_header);
- } catch (Exception e) {
- throw new RuntimeException(e);
- }
- }
- return _headerElement;
- }
+ public Element getHeader() {
+ try {
+ return _header == null ? null : DOMUtils.stringToDOM(_header);
+ } catch (Exception e) {
+ throw new RuntimeException(e);
+ }
+ }
- public void setHeader(Element value) {
- if (value == null) return;
+ public void setHeader(Element value) {
+ if (value == null)
+ return;
_header = DOMUtils.domToString(value);
- _headerElement = value;
- }
+ }
public MessageExchangeDAO getMessageExchange() {
return _messageExchange;
@@ -116,8 +122,8 @@
return _type == null ? null : QName.valueOf(_type);
}
- public void setType(QName type) {
- _type = type.toString();
- }
+ public void setType(QName type) {
+ _type = type.toString();
+ }
}
Modified:
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/MessageExchangeDAOImpl.java
===================================================================
---
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/MessageExchangeDAOImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/MessageExchangeDAOImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -56,44 +56,44 @@
@NamedQuery(name=MessageExchangeDAOImpl.SELECT_MEX_IDS_BY_PROCESS, query="select
m._id from MessageExchangeDAOImpl as m where m._process = :process")
})
public class MessageExchangeDAOImpl extends OpenJPADAO implements MessageExchangeDAO,
CorrelatorMessageDAO {
- private static final Log __log = LogFactory.getLog(MessageExchangeDAOImpl.class);
-
- public final static String DELETE_MEXS_BY_PROCESS = "DELETE_MEXS_BY_PROCESS";
- public final static String SELECT_MEX_IDS_BY_PROCESS =
"SELECT_MEX_IDS_BY_PROCESS";
-
- @Id @Column(name="MESSAGE_EXCHANGE_ID")
- private String _id;
- @Basic @Column(name="CALLEE")
+ private static final Log __log = LogFactory.getLog(MessageExchangeDAOImpl.class);
+
+ public final static String DELETE_MEXS_BY_PROCESS =
"DELETE_MEXS_BY_PROCESS";
+ public final static String SELECT_MEX_IDS_BY_PROCESS =
"SELECT_MEX_IDS_BY_PROCESS";
+
+ @Id @Column(name="MESSAGE_EXCHANGE_ID")
+ private String _id;
+ @Basic @Column(name="CALLEE")
private String _callee;
- @Basic @Column(name="CHANNEL")
+ @Basic @Column(name="CHANNEL")
private String _channel;
- @Basic @Column(name="CORRELATION_ID")
+ @Basic @Column(name="CORRELATION_ID")
private String _correlationId;
- @Basic @Column(name="CORRELATION_STATUS")
+ @Basic @Column(name="CORRELATION_STATUS")
private String _correlationStatus;
- @Basic @Column(name="CREATE_TIME")
+ @Basic @Column(name="CREATE_TIME")
private Date _createTime;
- @Basic @Column(name="DIRECTION")
+ @Basic @Column(name="DIRECTION")
private char _direction;
- @Lob @Column(name="EPR")
+ @Lob @Column(name="EPR")
private String _epr;
- @Transient private
+ @Transient private
Element _eprElement;
- @Basic @Column(name="FAULT")
+ @Basic @Column(name="FAULT")
private String _fault;
- @Basic @Column(name="FAULT_EXPLANATION")
+ @Basic @Column(name="FAULT_EXPLANATION")
private String _faultExplanation;
- @Basic @Column(name="OPERATION")
+ @Basic @Column(name="OPERATION")
private String _operation;
- @Basic @Column(name="PARTNER_LINK_MODEL_ID")
+ @Basic @Column(name="PARTNER_LINK_MODEL_ID")
private int _partnerLinkModelId;
- @Basic @Column(name="PATTERN")
+ @Basic @Column(name="PATTERN")
private String _pattern;
- @Basic @Column(name="PORT_TYPE")
+ @Basic @Column(name="PORT_TYPE")
private String _portType;
- @Basic @Column(name="PROPAGATE_TRANS")
+ @Basic @Column(name="PROPAGATE_TRANS")
private boolean _propagateTransactionFlag;
- @Basic @Column(name="STATUS")
+ @Basic @Column(name="STATUS")
private String _status;
@Basic @Column(name="CORRELATION_KEYS")
private String _correlationKeys;
@@ -104,16 +104,16 @@
@OneToMany(targetEntity=MexProperty.class,mappedBy="_mex",fetch=FetchType.EAGER,cascade={CascadeType.ALL})
private Collection<MexProperty> _props = new ArrayList<MexProperty>();
- @ManyToOne(fetch=FetchType.LAZY,cascade={CascadeType.PERSIST})
@Column(name="PROCESS_INSTANCE_ID")
- private ProcessInstanceDAOImpl _processInst;
- @ManyToOne(fetch=FetchType.LAZY,cascade={CascadeType.PERSIST})
@Column(name="PARTNER_LINK_ID")
- private PartnerLinkDAOImpl _partnerLink;
- @ManyToOne(fetch=FetchType.LAZY,cascade={CascadeType.PERSIST})
@Column(name="PROCESS_ID")
- private ProcessDAOImpl _process;
- @OneToOne(fetch=FetchType.LAZY,cascade={CascadeType.ALL})
@Column(name="REQUEST_MESSAGE_ID")
- private MessageDAOImpl _request;
- @OneToOne(fetch=FetchType.LAZY,cascade={CascadeType.ALL})
@Column(name="RESPONSE_MESSAGE_ID")
- private MessageDAOImpl _response;
+ @ManyToOne(fetch=FetchType.LAZY,cascade={CascadeType.PERSIST})
@Column(name="PROCESS_INSTANCE_ID")
+ private ProcessInstanceDAOImpl _processInst;
+ @ManyToOne(fetch=FetchType.LAZY,cascade={CascadeType.PERSIST})
@Column(name="PARTNER_LINK_ID")
+ private PartnerLinkDAOImpl _partnerLink;
+ @ManyToOne(fetch=FetchType.LAZY,cascade={CascadeType.PERSIST})
@Column(name="PROCESS_ID")
+ private ProcessDAOImpl _process;
+ @OneToOne(fetch=FetchType.LAZY,cascade={CascadeType.ALL})
@Column(name="REQUEST_MESSAGE_ID")
+ private MessageDAOImpl _request;
+ @OneToOne(fetch=FetchType.LAZY,cascade={CascadeType.ALL})
@Column(name="RESPONSE_MESSAGE_ID")
+ private MessageDAOImpl _response;
@ManyToOne(fetch= FetchType.LAZY,cascade={CascadeType.PERSIST})
@Column(name="CORR_ID")
private CorrelatorDAOImpl _correlator;
@@ -121,195 +121,197 @@
public MessageExchangeDAOImpl() {
}
- public MessageExchangeDAOImpl(char direction){
- _direction = direction;
- _id = new UUID().toString();
- }
-
- public MessageDAO createMessage(QName type) {
- MessageDAOImpl ret = new MessageDAOImpl(type,this);
- return ret ;
- }
+ public MessageExchangeDAOImpl(char direction){
+ _direction = direction;
+ _id = new UUID().toString();
+ }
+
+ public MessageDAO createMessage(QName type) {
+ MessageDAOImpl ret = new MessageDAOImpl(type,this);
+ return ret ;
+ }
- public QName getCallee() {
- return _callee == null ? null : QName.valueOf(_callee);
- }
+ public QName getCallee() {
+ return _callee == null ? null : QName.valueOf(_callee);
+ }
- public String getChannel() {
- return _channel;
- }
+ public String getChannel() {
+ return _channel;
+ }
- public String getCorrelationId() {
- return _correlationId;
- }
+ public String getCorrelationId() {
+ return _correlationId;
+ }
- public String getCorrelationStatus() {
- return _correlationStatus;
- }
+ public String getCorrelationStatus() {
+ return _correlationStatus;
+ }
- public Date getCreateTime() {
- return _createTime;
- }
+ public Date getCreateTime() {
+ return _createTime;
+ }
- public char getDirection() {
- return _direction;
- }
+ public char getDirection() {
+ return _direction;
+ }
- public Element getEPR() {
- if ( _eprElement == null && _epr != null && !"".equals(_epr))
{
- try {
- _eprElement = DOMUtils.stringToDOM(_epr);
- } catch (Exception e) {
- throw new RuntimeException(e);
- }
- }
- return _eprElement;
- }
+ public Element getEPR() {
+ if ( _eprElement == null && _epr != null &&
!"".equals(_epr)) {
+ try {
+ _eprElement = DOMUtils.stringToDOM(_epr);
+ } catch (Exception e) {
+ throw new RuntimeException(e);
+ }
+ }
+ return _eprElement;
+ }
- public QName getFault() {
- return _fault == null ? null : QName.valueOf(_fault);
- }
+ public QName getFault() {
+ return _fault == null ? null : QName.valueOf(_fault);
+ }
- public String getFaultExplanation() {
- return _faultExplanation;
- }
+ public String getFaultExplanation() {
+ return _faultExplanation;
+ }
- public ProcessInstanceDAO getInstance() {
- return _processInst;
- }
+ public ProcessInstanceDAO getInstance() {
+ return _processInst;
+ }
- public String getMessageExchangeId() {
- //return _messageExchangeId;
- return _id.toString();
- }
+ public String getMessageExchangeId() {
+ //return _messageExchangeId;
+ return _id.toString();
+ }
- public String getOperation() {
- return _operation;
- }
+ public String getOperation() {
+ return _operation;
+ }
- public PartnerLinkDAO getPartnerLink() {
- return _partnerLink;
- }
+ public PartnerLinkDAO getPartnerLink() {
+ return _partnerLink;
+ }
- public int getPartnerLinkModelId() {
- return _partnerLinkModelId;
- }
+ public int getPartnerLinkModelId() {
+ return _partnerLinkModelId;
+ }
- public String getPattern() {
- return _pattern;
- }
+ public String getPattern() {
+ return _pattern;
+ }
- public QName getPortType() {
- return _portType == null ? null : QName.valueOf(_portType);
- }
+ public QName getPortType() {
+ return _portType == null ? null : QName.valueOf(_portType);
+ }
- public ProcessDAO getProcess() {
- return _process;
- }
+ public ProcessDAO getProcess() {
+ return _process;
+ }
- public boolean getPropagateTransactionFlag() {
- return _propagateTransactionFlag;
- }
+ public boolean getPropagateTransactionFlag() {
+ return _propagateTransactionFlag;
+ }
- public String getProperty(String key) {
+ public String getProperty(String key) {
for (MexProperty prop : _props) {
if (prop.getPropertyKey().equals(key)) return prop.getPropertyValue();
}
return null;
- }
+ }
- public Set<String> getPropertyNames() {
+ public Set<String> getPropertyNames() {
HashSet<String> propNames = new HashSet<String>();
for (MexProperty prop : _props) {
propNames.add(prop.getPropertyKey());
}
return propNames;
- }
+ }
- public MessageDAO getRequest() {
- return _request;
- }
+ public MessageDAO getRequest() {
+ return _request;
+ }
- public MessageDAO getResponse() {
- return _response;
- }
+ public MessageDAO getResponse() {
+ return _response;
+ }
- public String getStatus() {
- return _status;
- }
+ public String getStatus() {
+ return _status;
+ }
- public void setCallee(QName callee) {
- _callee = callee.toString();
- }
+ public void setCallee(QName callee) {
+ _callee = callee.toString();
+ }
- public void setChannel(String channel) {
- _channel = channel;
- }
+ public void setChannel(String channel) {
+ _channel = channel;
+ }
- public void setCorrelationId(String correlationId) {
- _correlationId = correlationId;
- }
+ public void setCorrelationId(String correlationId) {
+ _correlationId = correlationId;
+ }
- public void setCorrelationStatus(String cstatus) {
- _correlationStatus = cstatus;
- }
+ public void setCorrelationStatus(String cstatus) {
+ _correlationStatus = cstatus;
+ }
- public void setEPR(Element epr) {
- _eprElement = epr;
- _epr = DOMUtils.domToString(epr);
- }
+ public void setEPR(Element epr) {
+ _eprElement = epr;
+ _epr = DOMUtils.domToString(epr);
+ }
- public void setFault(QName faultType) {
- _fault = faultType == null ? null : faultType.toString();
- }
+ public void setFault(QName faultType) {
+ _fault = faultType == null ? null : faultType.toString();
+ }
- public void setFaultExplanation(String explanation) {
- _faultExplanation = explanation;
- }
+ public void setFaultExplanation(String explanation) {
+ if(explanation != null && explanation.length() > 255)
+ explanation = explanation.substring(0,254);
+ _faultExplanation = explanation;
+ }
- public void setInstance(ProcessInstanceDAO dao) {
- _processInst = (ProcessInstanceDAOImpl)dao;
- }
+ public void setInstance(ProcessInstanceDAO dao) {
+ _processInst = (ProcessInstanceDAOImpl)dao;
+ }
- public void setOperation(String opname) {
- _operation = opname;
- }
+ public void setOperation(String opname) {
+ _operation = opname;
+ }
- public void setPartnerLink(PartnerLinkDAO plinkDAO) {
- _partnerLink = (PartnerLinkDAOImpl)plinkDAO;
- }
+ public void setPartnerLink(PartnerLinkDAO plinkDAO) {
+ _partnerLink = (PartnerLinkDAOImpl)plinkDAO;
+ }
- public void setPartnerLinkModelId(int modelId) {
- _partnerLinkModelId = modelId;
- }
+ public void setPartnerLinkModelId(int modelId) {
+ _partnerLinkModelId = modelId;
+ }
- public void setPattern(String pattern) {
- _pattern = pattern;
- }
+ public void setPattern(String pattern) {
+ _pattern = pattern;
+ }
- public void setPortType(QName porttype) {
- _portType = porttype.toString();
- }
+ public void setPortType(QName porttype) {
+ _portType = porttype.toString();
+ }
- public void setProcess(ProcessDAO process) {
- _process = (ProcessDAOImpl)process;
- }
+ public void setProcess(ProcessDAO process) {
+ _process = (ProcessDAOImpl)process;
+ }
- public void setProperty(String key, String value) {
+ public void setProperty(String key, String value) {
_props.add(new MexProperty(key, value, this));
- }
+ }
- public void setRequest(MessageDAO msg) {
- _request = (MessageDAOImpl)msg;
- }
+ public void setRequest(MessageDAO msg) {
+ _request = (MessageDAOImpl)msg;
+ }
- public void setResponse(MessageDAO msg) {
- _response = (MessageDAOImpl)msg;
- }
+ public void setResponse(MessageDAO msg) {
+ _response = (MessageDAOImpl)msg;
+ }
- public void setStatus(String status) {
- _status = status;
- }
+ public void setStatus(String status) {
+ _status = status;
+ }
public String getPipedMessageExchangeId() {
return _pipedMessageExchangeId;
@@ -320,11 +322,11 @@
}
void setCorrelationKeySet(CorrelationKeySet correlationKeySet) {
- _correlationKeys = correlationKeySet.toCanonicalString();
- }
+ _correlationKeys = correlationKeySet.toCanonicalString();
+ }
- CorrelationKeySet getCorrelationKeySet() {
- return new CorrelationKeySet(_correlationKeys);
+ CorrelationKeySet getCorrelationKeySet() {
+ return new CorrelationKeySet(_correlationKeys);
}
public CorrelationKey getCorrelationKey() {
@@ -337,23 +339,23 @@
}
- public void release(boolean doClean) {
- if( doClean ) {
- deleteMessages();
- }
- }
+ public void release(boolean doClean) {
+ if( doClean ) {
+ deleteMessages();
+ }
+ }
public void releasePremieMessages() {
- // do nothing; early messages are deleted during
CorrelatorDaoImpl().dequeueMessage()
+ // do nothing; early messages are deleted during
CorrelatorDaoImpl().dequeueMessage()
}
public void deleteMessages() {
- if( __log.isDebugEnabled() ) __log.debug("Deleting message on MEX
release.");
-
- getEM().remove(this); // This deletes MexProperty, REQUEST MessageDAO, RESPONSE
MessageDAO
- }
+ if( __log.isDebugEnabled() ) __log.debug("Deleting message on MEX
release.");
+
+ getEM().remove(this); // This deletes MexProperty, REQUEST MessageDAO, RESPONSE
MessageDAO
+ }
- public CorrelatorDAOImpl getCorrelator() {
+ public CorrelatorDAOImpl getCorrelator() {
return _correlator;
}
@@ -361,19 +363,23 @@
_correlator = correlator;
}
- public int getSubscriberCount() {
- return _subscriberCount;
- }
-
- public void setSubscriberCount(int subscriberCount) {
- this._subscriberCount = subscriberCount;
- }
+ public int getSubscriberCount() {
+ return _subscriberCount;
+ }
+
+ public void setSubscriberCount(int subscriberCount) {
+ this._subscriberCount = subscriberCount;
+ }
- public void incrementSubscriberCount() {
- ++_subscriberCount;
- }
-
+ public void incrementSubscriberCount() {
+ ++_subscriberCount;
+ }
+
public void release() {
// no-op for now, could be used to do some cleanup
}
+
+ public void setCreateTime(Date createTime) {
+ _createTime = createTime;
+ }
}
Modified:
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/ProcessInstanceDAOImpl.java
===================================================================
---
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/ProcessInstanceDAOImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/ProcessInstanceDAOImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -74,7 +74,8 @@
private static final Log __log = LogFactory.getLog(ProcessInstanceDAOImpl.class);
public final static String DELETE_INSTANCES_BY_PROCESS =
"DELETE_INSTANCES_BY_PROCESS";
- public final static String SELECT_INSTANCE_IDS_BY_PROCESS =
"SELECT_INSTANCE_IDS_BY_PROCESS"; public final static String
COUNT_INSTANCE_IDS_BY_PROCESS = "COUNT_INSTANCE_IDS_BY_PROCESS";
+ public final static String SELECT_INSTANCE_IDS_BY_PROCESS =
"SELECT_INSTANCE_IDS_BY_PROCESS";
+ public final static String COUNT_INSTANCE_IDS_BY_PROCESS =
"COUNT_INSTANCE_IDS_BY_PROCESS";
public final static String SELECT_FAULT_IDS_BY_PROCESS =
"SELECT_FAULT_IDS_BY_PROCESS";
public final static String COUNT_FAILED_INSTANCES_BY_STATUS_AND_PROCESS_ID =
"COUNT_FAILED_INSTANCES_BY_STATUS_AND_PROCESS_ID";
@@ -152,6 +153,10 @@
}
public void delete(Set<CLEANUP_CATEGORY> cleanupCategories) {
+ delete(cleanupCategories, true);
+ }
+
+ public void delete(Set<CLEANUP_CATEGORY> cleanupCategories, boolean
deleteMyRoleMex) {
if(__log.isDebugEnabled()) __log.debug("Cleaning up instance Data with
" + cleanupCategories);
// remove jacob state
@@ -391,4 +396,12 @@
public BpelDAOConnection getConnection() {
return new BPELDAOConnectionImpl(getEM());
}
+
+ public Collection<String> getMessageExchangeIds() {
+ Collection<String> c = new HashSet<String>();
+ for (MessageExchangeDAO m : _messageExchanges) {
+ c.add(m.getMessageExchangeId());
+ }
+ return c;
+ }
}
Modified:
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/ProcessManagementDAOImpl.java
===================================================================
---
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/ProcessManagementDAOImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/ProcessManagementDAOImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -22,6 +22,8 @@
import java.util.Collection;
import java.util.HashMap;
import java.util.Map;
+import java.util.Set;
+import javax.xml.namespace.QName;
import javax.persistence.EntityManager;
import javax.persistence.Query;
@@ -32,6 +34,8 @@
import org.apache.ode.bpel.dao.BpelDAOConnection;
import org.apache.ode.bpel.dao.ProcessInstanceDAO;
import org.apache.ode.bpel.dao.ProcessManagementDAO;
+import org.apache.ode.bpel.dao.ProcessManagementDAO.FailedSummaryValue;
+import org.apache.ode.bpel.dao.ProcessManagementDAO.InstanceSummaryKey;
public class ProcessManagementDAOImpl implements ProcessManagementDAO {
private static final Log __log = LogFactory.getLog(ProcessManagementDAOImpl.class);
@@ -72,4 +76,19 @@
}
}
}
+
+ public int countInstancesByPidAndString(BpelDAOConnection conn, QName pid, String
status) {
+ InstanceFilter instanceFilter = new InstanceFilter("status=" + status +
" pid="+ pid);
+
+ // TODO: this is grossly inefficient
+ return conn.instanceQuery(instanceFilter).size();
+ }
+
+ public Map<InstanceSummaryKey, Long> countInstancesSummary(Set<String>
pids) {
+ return new HashMap<InstanceSummaryKey, Long>();
+ }
+
+ public Map<String, FailedSummaryValue>
findFailedCountAndLastFailedDateForProcessIds(Set<String> pids) {
+ return new HashMap<String, FailedSummaryValue>();
+ }
}
Modified:
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/XmlDataDAOImpl.java
===================================================================
---
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/XmlDataDAOImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/dao-jpa/src/main/java/org/apache/ode/dao/jpa/XmlDataDAOImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -123,6 +123,13 @@
return null;
}
+ private XmlDataProperty getPropertyObject(String propertyName) {
+ for (XmlDataProperty prop : _props) {
+ if (prop.getPropertyKey().equals(propertyName)) return prop;
+ }
+ return null;
+ }
+
public ScopeDAO getScopeDAO() {
return _scope;
}
@@ -147,7 +154,12 @@
}
public void setProperty(String pname, String pvalue) {
- _props.add(new XmlDataProperty(pname, pvalue, this));
+ XmlDataProperty prop = getPropertyObject(pname);
+ if (prop == null) {
+ _props.add(new XmlDataProperty(pname, pvalue, this));
+ } else {
+ prop.setPropertyValue(pvalue);
+ }
}
}
Added: branches/ODE/ODE-1.x/dao-jpa-ojpa-derby/build.xml
===================================================================
--- branches/ODE/ODE-1.x/dao-jpa-ojpa-derby/build.xml (rev 0)
+++ branches/ODE/ODE-1.x/dao-jpa-ojpa-derby/build.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,86 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<project>
+
+ <property name="db.scripts.dir" value="${basedir}/target" />
+ <property name="descriptor.dir"
value="${basedir}/src/main/descriptors"/>
+ <property name="scripts.dir"
value="${basedir}/src/main/scripts"/>
+
+ <path id="classpath">
+ <pathelement path="${maven.runtime.classpath}"/>
+ </path>
+
+ <target name="create-schema">
+
+ <taskdef name="mappingtool"
classname="org.apache.openjpa.jdbc.ant.MappingToolTask"
classpathref="classpath"/>
+
+ <mkdir dir="target"/>
+ <mkdir dir="${db.scripts.dir}" />
+
+ <!-- Derby -->
+ <create-ddl db="derby"/>
+
+ <!-- MySQL -->
+ <create-ddl db="mysql"/>
+
+ <!-- Oracle -->
+ <create-ddl db="oracle"/>
+
+ <!-- Postgres -->
+<!--
+<create-ddl db="postgres"/>
+-->
+
+ </target>
+
+ <target name="zip-derby-db">
+ <zip
destfile="${basedir}/target/ode-dao-jpa-ojpa-derby-${ode.version}.zip"
basedir="${basedir}/target/derby" />
+ </target>
+
+ <!--
+ ============================================
+ Macro defs, no need to change anything below
+ ============================================
+ -->
+
+ <macrodef name="create-ddl">
+ <attribute name="db"/>
+
+ <sequential>
+ <echo></echo>
+ <echo>=====================</echo>
+ <echo>Create DDL @{db}</echo>
+ <mappingtool schemaAction="build"
sqlFile="${db.scripts.dir}/partial.(a){db}.sql" readSchema="false">
+ <config propertiesFile="${descriptor.dir}/persistence.(a){db}.xml"/>
+ <classpath>
+ <path refid="classpath"/>
+ </classpath>
+ </mappingtool>
+ <concat destfile="${db.scripts.dir}/(a){db}.sql">
+ <fileset file="${scripts.dir}/license-header.sql"/>
+ <fileset file="${scripts.dir}/simplesched-(a){db}.sql"/>
+ <fileset file="${db.scripts.dir}/partial.(a){db}.sql"/>
+ </concat>
+ <echo>Done.</echo>
+ <echo>=====================</echo>
+ </sequential>
+ </macrodef>
+
+</project>
Added: branches/ODE/ODE-1.x/dao-jpa-ojpa-derby/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/dao-jpa-ojpa-derby/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/dao-jpa-ojpa-derby/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,219 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<project>
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-dao-jpa-ojpa-derby</artifactId>
+ <name>ODE :: OpenJPA DDL Generation</name>
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <dependencies>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-j2ee-connector_1.5_spec</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-jta_1.1_spec</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>javax.persistence</groupId>
+ <artifactId>persistence-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-logging</groupId>
+ <artifactId>commons-logging</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-lang</groupId>
+ <artifactId>commons-lang</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-collections</groupId>
+ <artifactId>commons-collections</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-dao</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-utils</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-runtime</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-epr</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-dao-jpa</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-store</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>xerces</groupId>
+ <artifactId>xercesImpl</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.openjpa</groupId>
+ <artifactId>openjpa</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>net.sourceforge.serp</groupId>
+ <artifactId>serp</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>log4j</groupId>
+ <artifactId>log4j</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>wsdl4j</groupId>
+ <artifactId>wsdl4j</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-ejb_2.1_spec</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>hsqldb</groupId>
+ <artifactId>hsqldb</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.derby</groupId>
+ <artifactId>derby</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.derby</groupId>
+ <artifactId>derbytools</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.modules</groupId>
+ <artifactId>geronimo-kernel</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.components</groupId>
+ <artifactId>geronimo-transaction</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.components</groupId>
+ <artifactId>geronimo-connector</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>backport-util-concurrent</groupId>
+ <artifactId>backport-util-concurrent</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-dbcp</groupId>
+ <artifactId>commons-dbcp</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-pool</groupId>
+ <artifactId>commons-pool</artifactId>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <artifactId>maven-antrun-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>create-db-schemas</id>
+ <phase>process-resources</phase>
+ <goals>
+ <goal>run</goal>
+ </goals>
+ <configuration>
+ <tasks>
+ <property name="maven.runtime.classpath"
refid="maven.compile.classpath"/>
+ <ant antfile="build.xml" target="create-schema"
/>
+ </tasks>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>sql-maven-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>create-derby-db</id>
+ <phase>process-resources</phase>
+ <goals>
+ <goal>execute</goal>
+ </goals>
+ <configuration>
+ <driver>org.apache.derby.jdbc.EmbeddedDriver</driver>
+
<url>jdbc:derby:${basedir}/target/derby/jpadb;create=true</url>
+ <username>sa</username>
+ <password />
+ <autocommit>true</autocommit>
+ <onError>continue</onError>
+ <srcFiles>
+ <srcFile>target/derby.sql</srcFile>
+ </srcFiles>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ <plugin>
+ <artifactId>maven-antrun-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>zip-derby-db</id>
+ <phase>package</phase>
+ <goals>
+ <goal>run</goal>
+ </goals>
+ <configuration>
+ <tasks>
+ <property name="ode.version"
value="${project.version}"/>
+ <ant antfile="build.xml" target="zip-derby-db" />
+ </tasks>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+
+ </plugins>
+ </build>
+
+
+</project>
Modified: branches/ODE/ODE-1.x/dao-jpa-ojpa-derby/src/main/scripts/common.sql
===================================================================
--- branches/ODE/ODE-1.x/dao-jpa-ojpa-derby/src/main/scripts/common.sql 2010-04-14
15:43:12 UTC (rev 619)
+++ branches/ODE/ODE-1.x/dao-jpa-ojpa-derby/src/main/scripts/common.sql 2010-04-14
18:25:55 UTC (rev 620)
@@ -1,2 +1,2 @@
create table ODE_SCHEMA_VERSION (VERSION integer);
-insert into ODE_SCHEMA_VERSION values (5);
+insert into ODE_SCHEMA_VERSION values (6);
Added: branches/ODE/ODE-1.x/dependencies.rb
===================================================================
--- branches/ODE/ODE-1.x/dependencies.rb (rev 0)
+++ branches/ODE/ODE-1.x/dependencies.rb 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,136 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+#
http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+ANNONGEN = "annogen:annogen:jar:0.1.0"
+ANT = "ant:ant:jar:1.6.5"
+AXIOM = [ group("axiom-api", "axiom-impl",
"axiom-dom",
+ :under=>"org.apache.ws.commons.axiom",
:version=>"1.2.5") ]
+AXIS2_ALL = group("axis2-adb", "axis2-codegen",
"axis2-kernel",
+ "axis2-java2wsdl", "axis2-jibx",
"axis2-saaj", "axis2-xmlbeans",
+ :under=>"org.apache.axis2",
:version=>"1.3")
+AXIS2_TEST = group("httpcore", "httpcore-nio",
"httpcore-niossl",
+ :under=>"org.apache.httpcomponents",
:version=>"4.0-alpha5")
+AXIS2_MODULES = struct(
+ :mods => ["org.apache.rampart:rampart:mar:1.3",
+ "org.apache.rampart:rahas:mar:1.3",
+ "org.apache.axis2:addressing:mar:1.3"],
+ :libs => [group("rampart-core", "rampart-policy",
"rampart-trust",
+ :under=>"org.apache.rampart",
+ :version=>"1.3"),
+ "org.apache.ws.security:wss4j:jar:1.5.3",
+ "org.apache.santuario:xmlsec:jar:1.4.0",
+ "org.opensaml:opensaml:jar:1.1",
+ "bouncycastle:bcprov-jdk15:jar:140"]
+)
+AXIS2_WAR = "org.apache.axis2:axis2-webapp:war:1.3"
+BACKPORT =
"backport-util-concurrent:backport-util-concurrent:jar:3.0"
+COMMONS = struct(
+ :codec =>"commons-codec:commons-codec:jar:1.3",
+ :collections =>"commons-collections:commons-collections:jar:3.2.1",
+ :dbcp =>"commons-dbcp:commons-dbcp:jar:1.2.2",
+ :fileupload =>"commons-fileupload:commons-fileupload:jar:1.1.1",
+ :httpclient =>"commons-httpclient:commons-httpclient:jar:3.1",
+ :lang =>"commons-lang:commons-lang:jar:2.4",
+ :logging =>"commons-logging:commons-logging:jar:1.1",
+ :io =>"commons-io:commons-io:jar:1.4",
+ :pool =>"commons-pool:commons-pool:jar:1.4",
+ :primitives =>"commons-primitives:commons-primitives:jar:1.0",
+ :beanutils =>"commons-beanutils:commons-beanutils:jar:1.8.2"
+)
+DERBY = "org.apache.derby:derby:jar:10.5.3.0_1"
+DERBY_TOOLS = "org.apache.derby:derbytools:jar:10.5.3.0_1"
+DOM4J = "dom4j:dom4j:jar:1.6.1"
+GERONIMO = struct(
+ :kernel
=>"org.apache.geronimo.modules:geronimo-kernel:jar:2.0.1",
+ :transaction
=>"org.apache.geronimo.components:geronimo-transaction:jar:2.0.1",
+ :connector
=>"org.apache.geronimo.components:geronimo-connector:jar:2.0.1"
+)
+HIBERNATE = [ "org.hibernate:hibernate:jar:3.2.5.ga",
"asm:asm:jar:1.5.3",
+ "antlr:antlr:jar:2.7.6",
"cglib:cglib:jar:2.1_3", "net.sf.ehcache:ehcache:jar:1.2.3" ]
+HSQLDB = "hsqldb:hsqldb:jar:1.8.0.7"
+JAVAX = struct(
+ :activation =>"javax.activation:activation:jar:1.1",
+ #:activation
=>"geronimo-spec:geronimo-spec-activation:jar:1.0.2-rc4",
+ :connector
=>"org.apache.geronimo.specs:geronimo-j2ee-connector_1.5_spec:jar:1.0",
+ :ejb
=>"org.apache.geronimo.specs:geronimo-ejb_2.1_spec:jar:1.1",
+ :javamail =>"geronimo-spec:geronimo-spec-javamail:jar:1.3.1-rc5",
+ :jms =>"geronimo-spec:geronimo-spec-jms:jar:1.1-rc4",
+ :persistence =>"javax.persistence:persistence-api:jar:1.0",
+ :servlet
=>"org.apache.geronimo.specs:geronimo-servlet_2.4_spec:jar:1.0",
+ :stream =>"stax:stax-api:jar:1.0.1",
+ :transaction
=>"org.apache.geronimo.specs:geronimo-jta_1.1_spec:jar:1.1",
+ :resource
=>"org.apache.geronimo.specs:geronimo-j2ee-connector_1.5_spec:jar:1.0"
+)
+JAXEN = "jaxen:jaxen:jar:1.1.1"
+JBI = group("org.apache.servicemix.specs.jbi-api-1.0",
:under=>"org.apache.servicemix.specs", :version=>"1.1.0")
+JENCKS = "org.jencks:jencks:jar:all:1.3"
+JIBX = "jibx:jibx-run:jar:1.1-beta3"
+KARAF = [
+ "org.apache.felix:org.osgi.core:jar:1.4.0",
+
"org.apache.felix.karaf.shell:org.apache.felix.karaf.shell.console:jar:1.0.0",
+
group("org.apache.felix.gogo.commands","org.apache.felix.gogo.runtime",
+ :under=>"org.apache.felix.gogo",
:version=>"0.2.0")
+ ]
+LOG4J = "log4j:log4j:jar:1.2.13"
+OPENJPA = ["org.apache.openjpa:openjpa:jar:1.2.1",
+ "net.sourceforge.serp:serp:jar:1.13.1"]
+
+SAXON = group("saxon", "saxon-xpath",
"saxon-dom", "saxon-xqj", :under=>"net.sf.saxon",
:version=>"9.x")
+SERVICEMIX = [
+ group("servicemix-core",
+ :under=>"org.apache.servicemix",
:version=>"3.3"),
+ group("servicemix-soap", "servicemix-common",
"servicemix-shared", "servicemix-http", "servicemix-eip",
+ :under=>"org.apache.servicemix",
:version=>"2008.01"),
+ group("servicemix-utils",
+ :under=>"org.apache.servicemix",
:version=>"1.0.0"),
+ "commons-httpclient:commons-httpclient:jar:3.0",
+ "commons-codec:commons-codec:jar:1.2",
+ "org.mortbay.jetty:jetty:jar:6.1.12rc1",
+ "org.mortbay.jetty:jetty-client:jar:6.1.12rc1",
+ "org.mortbay.jetty:jetty-sslengine:jar:6.1.12rc1",
+ "org.mortbay.jetty:servlet-api-2.5:jar:6.1.12rc1",
+ "org.mortbay.jetty:jetty-util:jar:6.1.12rc1",
+ "org.codehaus.woodstox:wstx-asl:jar:3.2.2",
+
"org.apache.geronimo.specs:geronimo-activation_1.1_spec:jar:1.0.1",
+
"org.apache.geronimo.specs:geronimo-annotation_1.0_spec:jar:1.1",
+
"org.apache.geronimo.specs:geronimo-javamail_1.4_spec:jar:1.2",
+
"org.apache.geronimo.specs:geronimo-stax-api_1.0_spec:jar:1.0.1",
+
"org.apache.geronimo.specs:geronimo-jms_1.1_spec:jar:1.1",
+ "org.jencks:jencks:jar:2.1",
+ "org.objectweb.howl:howl:jar:1.0.1-1",
+ "org.apache.activemq:activemq-core:jar:4.1.1",
+ "org.apache.activemq:activemq-ra:jar:4.1.1",
+ "commons-beanutils:commons-beanutils:jar:1.7.0",
+ "tranql:tranql-connector-derby-common:jar:1.1"
+ ]
+SLF4J = group(%w{ slf4j-api slf4j-log4j12 jcl104-over-slf4j },
:under=>"org.slf4j", :version=>"1.4.3")
+SPRING = ["org.springframework:spring:jar:2.5.6"]
+TRANQL = [ "tranql:tranql-connector:jar:1.1", COMMONS.primitives
]
+WOODSTOX = "woodstox:wstx-asl:jar:3.2.1"
+WSDL4J = "wsdl4j:wsdl4j:jar:1.6.1"
+XALAN = "xalan:xalan:jar:2.7.1"
+XERCES = "xerces:xercesImpl:jar:2.9.0"
+WS_COMMONS = struct(
+ :axiom =>AXIOM,
+ :neethi =>"org.apache.neethi:neethi:jar:2.0.2",
+ :xml_schema =>"org.apache.ws.commons.schema:XmlSchema:jar:1.3.2"
+)
+XBEAN = [
+ "org.apache.xbean:xbean-kernel:jar:3.3",
+ "org.apache.xbean:xbean-server:jar:3.3",
+ "org.apache.xbean:xbean-spring:jar:3.4.3",
+ "org.apache.xbean:xbean-classloader:jar:3.4.3"
+]
+XMLBEANS = "org.apache.xmlbeans:xmlbeans:jar:2.3.0"
Added: branches/ODE/ODE-1.x/distro/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/distro/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/distro/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,123 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-distro</artifactId>
+ <name>ODE :: Distribution</name>
+ <packaging>pom</packaging>
+
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <properties>
+ </properties>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-utils</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-tools</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-compiler</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-runtime</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-schemas</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-pool</groupId>
+ <artifactId>commons-pool</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-logging</groupId>
+ <artifactId>commons-logging</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>rhino</groupId>
+ <artifactId>js</artifactId>
+ <version>1.7R1</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.activemq</groupId>
+ <artifactId>apache-activemq</artifactId>
+ </dependency>
+ </dependencies>
+
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-assembly-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>war-distro</id>
+ <phase>package</phase>
+ <goals>
+ <goal>single</goal>
+ </goals>
+ <configuration>
+ <finalName>apache-ode-war-${project.version}</finalName>
+ <appendAssemblyId>false</appendAssemblyId>
+ <descriptors>
+ <descriptor>src/main/assembly/war.xml</descriptor>
+ </descriptors>
+ <tarLongFileMode>gnu</tarLongFileMode>
+ </configuration>
+ </execution>
+ <execution>
+ <id>jbi-distro</id>
+ <phase>package</phase>
+ <goals>
+ <goal>single</goal>
+ </goals>
+ <configuration>
+ <finalName>apache-ode-jbi-${project.version}</finalName>
+ <appendAssemblyId>false</appendAssemblyId>
+ <descriptors>
+ <descriptor>src/main/assembly/jbi.xml</descriptor>
+ </descriptors>
+ <tarLongFileMode>gnu</tarLongFileMode>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+
+</project>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/HelloWorld2-http/HelloWorld2.wsdl
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/HelloWorld2-http/HelloWorld2.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/HelloWorld2-http/HelloWorld2.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,86 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions name="Hello"
+ targetNamespace="urn:/HelloWorld2.wsdl"
+ xmlns:tns="urn:/HelloWorld2.wsdl"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+
xmlns:smix="http://servicemix.org/wsdl/jbi/"
+
xmlns="http://schemas.xmlsoap.org/wsdl/">
+
+ <types>
+ <schema targetNamespace="urn:/HelloWorld2.wsdl"
+
xmlns="http://www.w3.org/2001/XMLSchema">
+ <element name="HelloRequest">
+ <complexType>
+ <all>
+ <element name="text" type="string"/>
+ </all>
+ </complexType>
+ </element>
+ <element name="HelloResponse">
+ <complexType>
+ <all>
+ <element name="text" type="string"/>
+ </all>
+ </complexType>
+ </element>
+ </schema>
+ </types>
+
+ <message name="HelloRequest">
+ <part name="body" element="tns:HelloRequest"/>
+ </message>
+
+ <message name="HelloResponse">
+ <part name="body" element="tns:HelloResponse"/>
+ </message>
+
+ <portType name="HelloPortType">
+ <operation name="Hello">
+ <input message="tns:HelloRequest"/>
+ <output message="tns:HelloResponse"/>
+ </operation>
+ </portType>
+
+ <binding name="HelloSoapBinding" type="tns:HelloPortType">
+ <soap:binding style="document"
transport="http://schemas.xmlsoap.org/soap/http"/>
+ <operation name="Hello">
+ <soap:operation soapAction=""/>
+ <input>
+ <soap:body use="literal"/>
+ </input>
+ <output>
+ <soap:body use="literal"/>
+ </output>
+ </operation>
+ </binding>
+
+ <service name="HelloService">
+ <port name="HelloPort" binding="tns:HelloSoapBinding">
+ <soap:address location="http://localhost:8080/hello-doc"/>
+
+ <!-- Connect this external HTTP endpoint to the process internal
+ JBI endpoint defined in HelloWorld2-process/HelloWorld2.dd -->
+ <smix:endpoint role="consumer"
defaultMep="in-out"/>
+
+ </port>
+ </service>
+
+</definitions>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/HelloWorld2-http/build.xml
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/HelloWorld2-http/build.xml
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/HelloWorld2-http/build.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<project name="HelloWorld2-HTTP" default="service-unit">
+
+ <import file="../../base-su.xml" />
+
+</project>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/HelloWorld2-process/HelloWorld2.bpel
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/HelloWorld2-process/HelloWorld2.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/HelloWorld2-process/HelloWorld2.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,79 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<process name="HelloWorld2"
+ targetNamespace="urn:/HeaderTest.bpel"
+
xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
+ xmlns:tns="urn:/HeaderTest.bpel"
+ xmlns:hello="urn:/HelloWorld2.wsdl"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
+
+ <import location="HelloWorld2.wsdl"
+ namespace="urn:/HelloWorld2.wsdl"
+
importType="http://schemas.xmlsoap.org/wsdl/" />
+
+ <partnerLinks>
+ <partnerLink name="helloPartnerLink"
+ partnerLinkType="hello:HelloPartnerLinkType"
+ myRole="Provider" />
+ </partnerLinks>
+
+ <variables>
+ <variable name="request"
messageType="hello:HelloRequest"/>
+ <variable name="response"
messageType="hello:HelloResponse"/>
+ <variable name="text" type="xsd:string"/>
+ </variables>
+
+ <sequence>
+ <receive
+ name="start"
+ partnerLink="helloPartnerLink"
+ portType="hello:HelloPortType"
+ operation="Hello"
+ variable="request"
+ createInstance="yes"/>
+
+ <assign name="assign1">
+ <copy>
+ <from>$request.body/hello:text</from>
+ <to variable="text"/>
+ </copy>
+ <copy>
+ <from>
+ <literal>
+ <hello:HelloResponse>
+ <hello:text/>
+ </hello:HelloResponse>
+ </literal>
+ </from>
+ <to>$response.body</to>
+ </copy>
+ <copy>
+ <from>concat($text,' World')</from>
+ <to>$response.body/hello:text</to>
+ </copy>
+ </assign>
+
+ <reply name="end"
+ partnerLink="helloPartnerLink"
+ portType="hello:HelloPortType"
+ operation="Hello"
+ variable="response"/>
+ </sequence>
+</process>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/HelloWorld2-process/HelloWorld2.wsdl
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/HelloWorld2-process/HelloWorld2.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/HelloWorld2-process/HelloWorld2.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,74 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions name="Hello"
+ targetNamespace="urn:/HelloWorld2.wsdl"
+ xmlns:tns="urn:/HelloWorld2.wsdl"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns="http://schemas.xmlsoap.org/wsdl/">
+
+ <types>
+ <schema targetNamespace="urn:/HelloWorld2.wsdl"
+
xmlns="http://www.w3.org/2001/XMLSchema">
+ <element name="HelloRequest">
+ <complexType>
+ <all>
+ <element name="text" type="string"/>
+ </all>
+ </complexType>
+ </element>
+ <element name="HelloResponse">
+ <complexType>
+ <all>
+ <element name="text" type="string"/>
+ </all>
+ </complexType>
+ </element>
+ </schema>
+ </types>
+
+ <message name="HelloRequest">
+ <part name="body" element="tns:HelloRequest"/>
+ </message>
+
+ <message name="HelloResponse">
+ <part name="body" element="tns:HelloResponse"/>
+ </message>
+
+ <portType name="HelloPortType">
+ <operation name="Hello">
+ <input message="tns:HelloRequest"/>
+ <output message="tns:HelloResponse"/>
+ </operation>
+ </portType>
+
+ <plnk:partnerLinkType name="HelloPartnerLinkType">
+ <plnk:role name="Provider"
portType="tns:HelloPortType"/>
+ </plnk:partnerLinkType>
+
+ <!--
+
+ This is an abstract interface/portType definition. Note the lack of
+ binding and service: these are defined by the HTTP binding component.
+ See HelloWorld2-http/HelloWorld2.wsdl for details.
+
+ -->
+
+</definitions>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/HelloWorld2-process/build.xml
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/HelloWorld2-process/build.xml
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/HelloWorld2-process/build.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<project name="HelloWorld2-Process" default="service-unit">
+
+ <import file="../../base-su.xml" />
+
+</project>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/HelloWorld2-process/deploy.xml
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/HelloWorld2-process/deploy.xml
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/HelloWorld2-process/deploy.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,30 @@
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<deploy
xmlns="http://www.apache.org/ode/schemas/dd/2007/03"
+ xmlns:pns="urn:/HeaderTest.bpel"
+ xmlns:sns="urn:/HelloWorld2.wsdl" >
+
+
+ <process name="pns:HelloWorld2">
+ <active>true</active>
+ <provide partnerLink="helloPartnerLink">
+ <service name="sns:HelloService" port="HelloPort"/>
+ </provide>
+ </process>
+</deploy>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/build.xml
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/build.xml
(rev 0)
+++ branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/build.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<project name="HelloWorld2" default="assembly">
+
+ <import file="../base-sa.xml" />
+
+ <target name="test" depends="init">
+ <antcall target="_sendsoap">
+ <param name="ode.sendsoap.url"
value="http://localhost:${ode.http.port}/hello-doc/"/>
+ <param name="ode.sendsoap.filename"
location="message.soap"/>
+ </antcall>
+ </target>
+
+</project>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/jbi.xml
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/jbi.xml
(rev 0)
+++ branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/jbi.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,52 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<jbi version="1.0"
xmlns="http://java.sun.com/xml/ns/jbi">
+ <service-assembly>
+ <identification>
+ <name>HelloWorld2-SA</name>
+ <description>HelloWorld2 Service Assembly</description>
+ </identification>
+
+ <service-unit>
+ <identification>
+ <name>HelloWorld2-HTTP</name>
+ <description>HelloWorld2 HTTP Binding</description>
+ </identification>
+
+ <target>
+ <artifacts-zip>HelloWorld2-HTTP.zip</artifacts-zip>
+ <component-name>servicemix-http</component-name>
+ </target>
+ </service-unit>
+
+ <service-unit>
+ <identification>
+ <name>HelloWorld2-process</name>
+ <description>HelloWorld2 BPEL Service Unit</description>
+ </identification>
+ <target>
+ <artifacts-zip>HelloWorld2-Process.zip</artifacts-zip>
+ <component-name>OdeBpelEngine</component-name>
+ </target>
+ </service-unit>
+
+ </service-assembly>
+</jbi>
+
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/message.soap
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/message.soap
(rev 0)
+++ branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2/message.soap 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<SOAP-ENV:Envelope
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
+ <SOAP-ENV:Body>
+ <HelloRequest xmlns="urn:/HelloWorld2.wsdl">
+ <text>hello</text>
+ </HelloRequest>
+ </SOAP-ENV:Body>
+</SOAP-ENV:Envelope>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/HelloWorld2-RPC-http/HelloWorld2-RPC.wsdl
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/HelloWorld2-RPC-http/HelloWorld2-RPC.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/HelloWorld2-RPC-http/HelloWorld2-RPC.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,67 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions name="Hello"
+ targetNamespace="urn:/HelloWorld2-RPC.wsdl"
+ xmlns:tns="urn:/HelloWorld2-RPC.wsdl"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+
xmlns:smix="http://servicemix.org/wsdl/jbi/"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+
xmlns="http://schemas.xmlsoap.org/wsdl/">
+
+ <message name="HelloRequest">
+ <part name="text" type="xsd:string"/>
+ </message>
+
+ <message name="HelloResponse">
+ <part name="text" type="xsd:string"/>
+ </message>
+
+ <portType name="HelloPortType">
+ <operation name="Hello">
+ <input message="tns:HelloRequest"/>
+ <output message="tns:HelloResponse"/>
+ </operation>
+ </portType>
+
+ <binding name="HelloSoapBinding" type="tns:HelloPortType">
+ <soap:binding style="rpc"
transport="http://schemas.xmlsoap.org/soap/http"/>
+ <operation name="Hello">
+ <soap:operation soapAction=""/>
+ <input>
+ <soap:body use="literal" parts="text"/>
+ </input>
+ <output>
+ <soap:body use="literal" parts="text"/>
+ </output>
+ </operation>
+ </binding>
+
+ <service name="HelloRPCService">
+ <port name="HelloPort" binding="tns:HelloSoapBinding">
+ <soap:address location="http://localhost:8080/hello-rpc"/>
+
+ <!-- Connect this external HTTP endpoint to the process internal
+ JBI endpoint defined in HelloWorld2-RPC-process/deploy.xml -->
+ <smix:endpoint role="consumer"
defaultMep="in-out"/>
+
+ </port>
+ </service>
+
+</definitions>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/HelloWorld2-RPC-http/build.xml
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/HelloWorld2-RPC-http/build.xml
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/HelloWorld2-RPC-http/build.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<project name="HelloWorld2-RPC-HTTP" default="service-unit">
+
+ <import file="../../base-su.xml" />
+
+</project>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/HelloWorld2-RPC-process/HelloWorld2-RPC.bpel
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/HelloWorld2-RPC-process/HelloWorld2-RPC.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/HelloWorld2-RPC-process/HelloWorld2-RPC.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,69 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<process name="HelloWorld2-RPC"
+ targetNamespace="urn:/HelloWorld2-RPC.bpel"
+
xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
+ xmlns:tns="urn:/HelloWorld2-RPC.bpel"
+ xmlns:hello="urn:/HelloWorld2-RPC.wsdl"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
+
+ <import location="HelloWorld2-RPC.wsdl"
+ namespace="urn:/HelloWorld2-RPC.wsdl"
+
importType="http://schemas.xmlsoap.org/wsdl/" />
+
+ <partnerLinks>
+ <partnerLink name="helloPartnerLink"
+ partnerLinkType="hello:HelloPartnerLinkType"
+ myRole="Provider" />
+ </partnerLinks>
+
+ <variables>
+ <variable name="request"
messageType="hello:HelloRequest"/>
+ <variable name="response"
messageType="hello:HelloResponse"/>
+ <variable name="text" type="xsd:string"/>
+ </variables>
+
+ <sequence>
+ <receive
+ name="start"
+ partnerLink="helloPartnerLink"
+ portType="hello:HelloPortType"
+ operation="Hello"
+ variable="request"
+ createInstance="yes"/>
+
+ <assign name="assign1">
+ <copy>
+ <from>$request.text</from>
+ <to variable="text"/>
+ </copy>
+ <copy>
+ <from>concat($text,' World')</from>
+ <to>$response.text</to>
+ </copy>
+ </assign>
+
+ <reply name="end"
+ partnerLink="helloPartnerLink"
+ portType="hello:HelloPortType"
+ operation="Hello"
+ variable="response"/>
+ </sequence>
+</process>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/HelloWorld2-RPC-process/HelloWorld2-RPC.wsdl
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/HelloWorld2-RPC-process/HelloWorld2-RPC.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/HelloWorld2-RPC-process/HelloWorld2-RPC.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,56 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions name="Hello"
+ targetNamespace="urn:/HelloWorld2-RPC.wsdl"
+ xmlns:tns="urn:/HelloWorld2-RPC.wsdl"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+
xmlns="http://schemas.xmlsoap.org/wsdl/">
+
+ <message name="HelloRequest">
+ <part name="text" type="xsd:string"/>
+ </message>
+
+ <message name="HelloResponse">
+ <part name="text" type="xsd:string"/>
+ </message>
+
+ <portType name="HelloPortType">
+ <operation name="Hello">
+ <input message="tns:HelloRequest"/>
+ <output message="tns:HelloResponse"/>
+ </operation>
+ </portType>
+
+ <plnk:partnerLinkType name="HelloPartnerLinkType">
+ <plnk:role name="Provider"
portType="tns:HelloPortType"/>
+ </plnk:partnerLinkType>
+
+ <!--
+
+ This is an abstract interface/portType definition. Note the lack of
+ binding and service: these are defined by the HTTP binding component.
+ See HelloWorld2-RPC-http/HelloWorld2-RPC.wsdl for details.
+
+ -->
+
+</definitions>
+
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/HelloWorld2-RPC-process/build.xml
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/HelloWorld2-RPC-process/build.xml
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/HelloWorld2-RPC-process/build.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<project name="HelloWorld2-RPC-Process"
default="service-unit">
+
+ <import file="../../base-su.xml" />
+
+</project>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/HelloWorld2-RPC-process/deploy.xml
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/HelloWorld2-RPC-process/deploy.xml
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/HelloWorld2-RPC-process/deploy.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<deploy
xmlns="http://www.apache.org/ode/schemas/dd/2007/03"
+ xmlns:pns="urn:/HelloWorld2-RPC.bpel"
+ xmlns:sns="urn:/HelloWorld2-RPC.wsdl">
+
+
+ <process name="pns:HelloWorld2-RPC">
+ <active>true</active>
+ <provide partnerLink="helloPartnerLink">
+ <service name="sns:HelloRPCService"
port="HelloPort"/>
+ </provide>
+ </process>
+</deploy>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/build.xml
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/build.xml
(rev 0)
+++ branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/build.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<project name="HelloWorld2-RPC" default="assembly">
+
+ <import file="../base-sa.xml" />
+
+ <target name="test" depends="init">
+ <antcall target="_sendsoap">
+ <param name="ode.sendsoap.url"
value="http://localhost:${ode.http.port}/hello-rpc/"/>
+ <param name="ode.sendsoap.filename"
location="message.soap"/>
+ </antcall>
+ </target>
+
+</project>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/jbi.xml
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/jbi.xml
(rev 0)
+++ branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/jbi.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,52 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<jbi version="1.0"
xmlns="http://java.sun.com/xml/ns/jbi">
+ <service-assembly>
+ <identification>
+ <name>HelloWorld2-RPC-SA</name>
+ <description>HelloWorld2-RPC Service Assembly</description>
+ </identification>
+
+ <service-unit>
+ <identification>
+ <name>HelloWorld2-RPC-HTTP</name>
+ <description>HelloWorld2 HTTP Binding</description>
+ </identification>
+
+ <target>
+ <artifacts-zip>HelloWorld2-RPC-HTTP.zip</artifacts-zip>
+ <component-name>servicemix-http</component-name>
+ </target>
+ </service-unit>
+
+ <service-unit>
+ <identification>
+ <name>HelloWorld2-RPC-process</name>
+ <description>HelloWorld2 BPEL Service Unit</description>
+ </identification>
+ <target>
+ <artifacts-zip>HelloWorld2-RPC-Process.zip</artifacts-zip>
+ <component-name>OdeBpelEngine</component-name>
+ </target>
+ </service-unit>
+
+ </service-assembly>
+</jbi>
+
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/message.soap
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/message.soap
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/HelloWorld2-RPC/message.soap 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<SOAP-ENV:Envelope
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
+ <SOAP-ENV:Body>
+ <xns:Hello xmlns:xns="urn:/HelloWorld2-RPC.wsdl">
+ <text>hello</text>
+ </xns:Hello>
+ </SOAP-ENV:Body>
+</SOAP-ENV:Envelope>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/build.xml
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/build.xml
(rev 0)
+++ branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/build.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<project name="PingPong" default="assembly">
+
+ <import file="../base-sa.xml" />
+
+ <target name="test" depends="init">
+ <antcall target="_sendsoap">
+ <param name="ode.sendsoap.url"
value="http://localhost:${ode.http.port}/ping/"/>
+ <param name="ode.sendsoap.filename"
location="message.soap"/>
+ </antcall>
+ </target>
+
+</project>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/jbi.xml
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/jbi.xml
(rev 0)
+++ branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/jbi.xml 2010-04-14 18:25:55
UTC (rev 620)
@@ -0,0 +1,63 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<jbi version="1.0"
xmlns="http://java.sun.com/xml/ns/jbi">
+ <service-assembly>
+ <identification>
+ <name>PingPong-SA</name>
+ <description>PingPong Service Assembly</description>
+ </identification>
+
+ <service-unit>
+ <identification>
+ <name>Ping-HTTP</name>
+ <description>Ping HTTP Binding</description>
+ </identification>
+
+ <target>
+ <artifacts-zip>Ping-HTTP.zip</artifacts-zip>
+ <component-name>servicemix-http</component-name>
+ </target>
+ </service-unit>
+
+ <service-unit>
+ <identification>
+ <name>Pong-process</name>
+ <description>Pong BPEL Service Unit</description>
+ </identification>
+ <target>
+ <artifacts-zip>Pong-Process.zip</artifacts-zip>
+ <component-name>OdeBpelEngine</component-name>
+ </target>
+ </service-unit>
+
+ <service-unit>
+ <identification>
+ <name>Ping-process</name>
+ <description>Ping BPEL Service Unit</description>
+ </identification>
+ <target>
+ <artifacts-zip>Ping-Process.zip</artifacts-zip>
+ <component-name>OdeBpelEngine</component-name>
+ </target>
+ </service-unit>
+
+ </service-assembly>
+</jbi>
+
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/message.soap
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/message.soap
(rev 0)
+++ branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/message.soap 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<SOAP-ENV:Envelope
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
+ <SOAP-ENV:Body>
+ <PingRequest xmlns="urn:/Ping.wsdl">
+ <text>hello</text>
+ </PingRequest>
+ </SOAP-ENV:Body>
+</SOAP-ENV:Envelope>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping/Ping.bpel
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping/Ping.bpel
(rev 0)
+++ branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping/Ping.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,124 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<process
+ name="Ping"
+
xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
+ targetNamespace="urn:/Ping.bpel"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:tns="urn:/Ping.bpel"
+ xmlns:ping="urn:/Ping.wsdl"
+ xmlns:pong="urn:/Pong.wsdl"
+
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath1.0">
+
+ <import location="Ping.wsdl"
+ namespace="urn:/Ping.wsdl"
+
importType="http://schemas.xmlsoap.org/wsdl/" />
+
+ <import location="Pong.wsdl"
+ namespace="urn:/Pong.wsdl"
+
importType="http://schemas.xmlsoap.org/wsdl/" />
+
+ <partnerLinks>
+ <partnerLink name="PingPartnerLink"
+ partnerLinkType="ping:PingPartnerLinkType"
+ myRole="Provider" />
+ <partnerLink name="PongPartnerLink"
+ partnerLinkType="pong:PongPartnerLinkType"
+ partnerRole="Provider"
+ initializePartnerRole="yes" />
+ </partnerLinks>
+
+ <variables>
+ <variable messageType="ping:PingRequest"
name="pingRequest"/>
+ <variable messageType="ping:PingResponse"
name="pingResponse"/>
+ <variable messageType="pong:PongRequest"
name="pongRequest"/>
+ <variable messageType="pong:PongResponse"
name="pongResponse"/>
+ <variable type="xsd:string" name="text" />
+ </variables>
+
+ <sequence name="Main">
+ <receive name="pingReceive"
+ createInstance="yes"
+ operation="Ping"
+ partnerLink="PingPartnerLink"
+ portType="ping:PingPortType"
+ variable="pingRequest"/>
+
+ <assign name="assignPongRequest">
+ <!-- add "ping" text to the input text -->
+ <copy>
+ <from>concat($pingRequest.body/ping:text, '
ping')</from>
+ <to variable="text"/>
+ </copy>
+ <!-- initialize pongRequest -->
+ <copy>
+ <from>
+ <literal>
+ <pong:PongRequest>
+ <pong:text/>
+ </pong:PongRequest>
+ </literal>
+ </from>
+ <to>$pongRequest.body</to>
+ </copy>
+ <!-- copy new text into pongRequest -->
+ <copy>
+ <from>$text</from>
+ <to>$pongRequest.body/pong:text</to>
+ </copy>
+ </assign>
+
+ <invoke name="invokePong"
+ operation="Pong"
+ inputVariable="pongRequest"
+ outputVariable="pongResponse"
+ partnerLink="PongPartnerLink"
+ portType="pong:PongPortType"/>
+
+ <assign name="assignPingResponse">
+ <copy>
+ <from>$pongResponse.body/pong:text</from>
+ <to>$text</to>
+ </copy>
+ <!-- initialize pingResponse -->
+ <copy>
+ <from>
+ <literal>
+ <ping:PingResponse>
+ <ping:text/>
+ </ping:PingResponse>
+ </literal>
+ </from>
+ <to>$pingResponse.body</to>
+ </copy>
+ <!-- copy new text into pingResponse -->
+ <copy>
+ <from>$text</from>
+ <to>$pingResponse.body/ping:text</to>
+ </copy>
+ </assign>
+
+ <reply name="pingReply"
+ partnerLink="PingPartnerLink"
+ portType="ping:PingPortType"
+ operation="Ping"
+ variable="pingResponse"/>
+ </sequence>
+</process>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping/Ping.wsdl
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping/Ping.wsdl
(rev 0)
+++ branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping/Ping.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,74 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions name="Ping"
+ targetNamespace="urn:/Ping.wsdl"
+ xmlns:tns="urn:/Ping.wsdl"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns="http://schemas.xmlsoap.org/wsdl/">
+
+ <types>
+ <schema targetNamespace="urn:/Ping.wsdl"
+
xmlns="http://www.w3.org/2001/XMLSchema">
+ <element name="PingRequest">
+ <complexType>
+ <all>
+ <element name="text" type="string"/>
+ </all>
+ </complexType>
+ </element>
+ <element name="PingResponse">
+ <complexType>
+ <all>
+ <element name="text" type="string"/>
+ </all>
+ </complexType>
+ </element>
+ </schema>
+ </types>
+
+ <message name="PingRequest">
+ <part name="body" element="tns:PingRequest"/>
+ </message>
+
+ <message name="PingResponse">
+ <part name="body" element="tns:PingResponse"/>
+ </message>
+
+ <portType name="PingPortType">
+ <operation name="Ping">
+ <input message="tns:PingRequest"/>
+ <output message="tns:PingResponse"/>
+ </operation>
+ </portType>
+
+ <plnk:partnerLinkType name="PingPartnerLinkType">
+ <plnk:role name="Provider"
portType="tns:PingPortType"/>
+ </plnk:partnerLinkType>
+
+ <!--
+
+ This is an abstract interface/portType definition. Note the lack of
+ binding and service: these are defined by the HTTP binding component.
+ See ping-http/Ping.wsdl for details.
+
+ -->
+
+</definitions>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping/Pong.wsdl
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping/Pong.wsdl
(rev 0)
+++ branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping/Pong.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,74 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions name="Pong"
+ targetNamespace="urn:/Pong.wsdl"
+ xmlns:tns="urn:/Pong.wsdl"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns="http://schemas.xmlsoap.org/wsdl/">
+
+ <types>
+ <schema targetNamespace="urn:/Pong.wsdl"
+
xmlns="http://www.w3.org/2001/XMLSchema">
+ <element name="PongRequest">
+ <complexType>
+ <all>
+ <element name="text" type="string"/>
+ </all>
+ </complexType>
+ </element>
+ <element name="PongResponse">
+ <complexType>
+ <all>
+ <element name="text" type="string"/>
+ </all>
+ </complexType>
+ </element>
+ </schema>
+ </types>
+
+ <message name="PongRequest">
+ <part name="body" element="tns:PongRequest"/>
+ </message>
+
+ <message name="PongResponse">
+ <part name="body" element="tns:PongResponse"/>
+ </message>
+
+ <portType name="PongPortType">
+ <operation name="Pong">
+ <input message="tns:PongRequest"/>
+ <output message="tns:PongResponse"/>
+ </operation>
+ </portType>
+
+ <plnk:partnerLinkType name="PongPartnerLinkType">
+ <plnk:role name="Provider"
portType="tns:PongPortType"/>
+ </plnk:partnerLinkType>
+
+ <!--
+
+ This is an abstract interface/portType definition. Note the lack of
+ binding and service. Since Pong is only exposed on the JBI bus, the
+ JBI endpoint is defined in Pong.dd.
+
+ -->
+
+</definitions>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping/build.xml
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping/build.xml
(rev 0)
+++ branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping/build.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<project name="Ping-Process" default="service-unit">
+
+ <import file="../../base-su.xml" />
+
+</project>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping/deploy.xml
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping/deploy.xml
(rev 0)
+++ branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping/deploy.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<deploy
xmlns="http://www.apache.org/ode/schemas/dd/2007/03"
+ xmlns:process="urn:/Ping.bpel"
+ xmlns:ping="urn:/Ping.wsdl"
+ xmlns:pong="urn:/Pong.wsdl">
+
+ <process name="process:Ping">
+ <active>true</active>
+ <provide partnerLink="PingPartnerLink">
+ <service name="ping:PingService" port="PingPort"/>
+ </provide>
+ <invoke partnerLink="PongPartnerLink">
+ <service name="pong:PongService" port="PongPort"/>
+ </invoke>
+ </process>
+
+</deploy>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping-http/Ping.wsdl
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping-http/Ping.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping-http/Ping.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,86 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions name="Ping"
+ targetNamespace="urn:/Ping.wsdl"
+ xmlns:tns="urn:/Ping.wsdl"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+
xmlns:smix="http://servicemix.org/wsdl/jbi/"
+
xmlns="http://schemas.xmlsoap.org/wsdl/">
+
+ <types>
+ <schema targetNamespace="urn:/Ping.wsdl"
+
xmlns="http://www.w3.org/2001/XMLSchema">
+ <element name="PingRequest">
+ <complexType>
+ <all>
+ <element name="text" type="string"/>
+ </all>
+ </complexType>
+ </element>
+ <element name="PingResponse">
+ <complexType>
+ <all>
+ <element name="text" type="string"/>
+ </all>
+ </complexType>
+ </element>
+ </schema>
+ </types>
+
+ <message name="PingRequest">
+ <part name="body" element="tns:PingRequest"/>
+ </message>
+
+ <message name="PingResponse">
+ <part name="body" element="tns:PingResponse"/>
+ </message>
+
+ <portType name="PingPortType">
+ <operation name="Ping">
+ <input message="tns:PingRequest"/>
+ <output message="tns:PingResponse"/>
+ </operation>
+ </portType>
+
+ <binding name="PingSoapBinding" type="tns:PingPortType">
+ <soap:binding style="document"
transport="http://schemas.xmlsoap.org/soap/http"/>
+ <operation name="Ping">
+ <soap:operation soapAction=""/>
+ <input>
+ <soap:body use="literal"/>
+ </input>
+ <output>
+ <soap:body use="literal"/>
+ </output>
+ </operation>
+ </binding>
+
+ <service name="PingService">
+ <port name="PingPort" binding="tns:PingSoapBinding">
+ <soap:address location="http://localhost:8080/ping"/>
+
+ <!-- Connect this external HTTP endpoint to the process internal
+ JBI endpoint defined in ping/Ping.dd -->
+ <smix:endpoint role="consumer"
defaultMep="in-out"/>
+
+ </port>
+ </service>
+
+</definitions>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping-http/build.xml
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping-http/build.xml
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/ping-http/build.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<project name="Ping-HTTP" default="service-unit">
+ <import file="../../base-su.xml" />
+</project>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/pong/Pong.bpel
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/pong/Pong.bpel
(rev 0)
+++ branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/pong/Pong.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,87 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<process
+ name="Pong"
+
xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
+ targetNamespace="urn:/Pong.bpel"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:tns="urn:/Pong.bpel"
+ xmlns:pong="urn:/Pong.wsdl"
+
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath1.0">
+
+ <import location="Pong.wsdl"
+ namespace="urn:/Pong.wsdl"
+
importType="http://schemas.xmlsoap.org/wsdl/" />
+
+ <import location="Pong.wsdl"
+ namespace="urn:/Pong.wsdl"
+
importType="http://schemas.xmlsoap.org/wsdl/" />
+
+ <partnerLinks>
+ <partnerLink name="PongPartnerLink"
+ partnerLinkType="pong:PongPartnerLinkType"
+ myRole="Provider" />
+ </partnerLinks>
+
+ <variables>
+ <variable messageType="pong:PongRequest"
name="pongRequest"/>
+ <variable messageType="pong:PongResponse"
name="pongResponse"/>
+ <variable type="xsd:string" name="text" />
+ </variables>
+
+ <sequence name="Main">
+ <receive name="pongReceive"
+ createInstance="yes"
+ operation="Pong"
+ partnerLink="PongPartnerLink"
+ portType="pong:PongPortType"
+ variable="pongRequest"/>
+
+ <assign name="assignPongRequest">
+ <!-- add "ping" text to the input text -->
+ <copy>
+ <from>concat($pongRequest.body/pong:text, '
pong')</from>
+ <to>$text</to>
+ </copy>
+ <!-- initialize pongResponse -->
+ <copy>
+ <from>
+ <literal>
+ <pong:PongRequest>
+ <pong:text/>
+ </pong:PongRequest>
+ </literal>
+ </from>
+ <to>$pongResponse.body</to>
+ </copy>
+ <!-- copy new text into pongResponse -->
+ <copy>
+ <from>$text</from>
+ <to>$pongResponse.body/pong:text</to>
+ </copy>
+ </assign>
+
+ <reply name="pongReply"
+ partnerLink="PongPartnerLink"
+ portType="pong:PongPortType"
+ operation="Pong"
+ variable="pongResponse"/>
+ </sequence>
+</process>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/pong/Pong.wsdl
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/pong/Pong.wsdl
(rev 0)
+++ branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/pong/Pong.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,74 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions name="Pong"
+ targetNamespace="urn:/Pong.wsdl"
+ xmlns:tns="urn:/Pong.wsdl"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns="http://schemas.xmlsoap.org/wsdl/">
+
+ <types>
+ <schema targetNamespace="urn:/Pong.wsdl"
+
xmlns="http://www.w3.org/2001/XMLSchema">
+ <element name="PongRequest">
+ <complexType>
+ <all>
+ <element name="text" type="string"/>
+ </all>
+ </complexType>
+ </element>
+ <element name="PongResponse">
+ <complexType>
+ <all>
+ <element name="text" type="string"/>
+ </all>
+ </complexType>
+ </element>
+ </schema>
+ </types>
+
+ <message name="PongRequest">
+ <part name="body" element="tns:PongRequest"/>
+ </message>
+
+ <message name="PongResponse">
+ <part name="body" element="tns:PongResponse"/>
+ </message>
+
+ <portType name="PongPortType">
+ <operation name="Pong">
+ <input message="tns:PongRequest"/>
+ <output message="tns:PongResponse"/>
+ </operation>
+ </portType>
+
+ <plnk:partnerLinkType name="PongPartnerLinkType">
+ <plnk:role name="Provider"
portType="tns:PongPortType"/>
+ </plnk:partnerLinkType>
+
+ <!--
+
+ This is an abstract interface/portType definition. Note the lack of
+ binding and service. Since Pong is only exposed on the JBI bus, the
+ JBI endpoint is defined in Pong.dd.
+
+ -->
+
+</definitions>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/pong/build.xml
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/pong/build.xml
(rev 0)
+++ branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/pong/build.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<project name="Pong-Process" default="service-unit">
+
+ <import file="../../base-su.xml" />
+
+</project>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/pong/deploy.xml
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/pong/deploy.xml
(rev 0)
+++ branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/PingPong/pong/deploy.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<deploy
xmlns="http://www.apache.org/ode/schemas/dd/2007/03"
+ xmlns:process="urn:/Pong.bpel"
+ xmlns:pong="urn:/Pong.wsdl">
+
+ <process name="process:Pong">
+ <active>true</active>
+ <provide partnerLink="PongPartnerLink">
+ <service name="pong:PongService" port="PongPort"/>
+ </provide>
+ </process>
+
+</deploy>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/ProcessManagement/ProcessManagement-HTTP/build.xml
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/ProcessManagement/ProcessManagement-HTTP/build.xml
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/ProcessManagement/ProcessManagement-HTTP/build.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<project name="ProcessManagement-HTTP" default="service-unit">
+
+ <import file="../../base-su.xml" />
+
+</project>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/ProcessManagement/ProcessManagement-HTTP/pmapi.wsdl
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/ProcessManagement/ProcessManagement-HTTP/pmapi.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/ProcessManagement/ProcessManagement-HTTP/pmapi.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,1410 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<definitions
+ name="ProcessAndInstanceManagement"
+
targetNamespace="http://www.apache.org/ode/pmapi"
+
xmlns:tns="http://www.apache.org/ode/pmapi"
+
xmlns:typ="http://www.apache.org/ode/pmapi/types/2006/08/02/"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+
xmlns:smix="http://servicemix.org/wsdl/jbi/"
+
xmlns="http://schemas.xmlsoap.org/wsdl/">
+
+ <types>
+
+ <!--
+ <xsd:schema>
+ <xsd:import
namespace="http://www.apache.org/ode/pmapi/types/2006/08/02/"
schemaLocation="pmapi.xsd"/>
+ </xsd:schema>
+ -->
+
+<!-- Note: Schema is inlined because import does not resolve .xsd file from inside
service unit's directory -->
+<xsd:schema
xmlns="http://www.w3.org/2001/XMLSchema"
xmlns:pmapi="http://www.apache.org/ode/pmapi/types/2006/08/02/"
+
xmlns:xs="http://www.w3.org/2001/XMLSchema"
targetNamespace="http://www.apache.org/ode/pmapi/types/2006/08/02/&q...
+ elementFormDefault="qualified">
+ <element name="process-info" type="pmapi:tProcessInfo"
id="process-info"/>
+ <element name="activity-info" type="pmapi:tActivityInfo"
id="activity-info"/>
+ <element name="process-info-list"
type="pmapi:tProcessInfoList"/>
+ <element name="instance-info" type="pmapi:tInstanceInfo"
id="instance-info"/>
+ <element name="instance-info-list"
type="pmapi:tInstanceInfoList"/>
+ <element name="scope-info" type="pmapi:tScopeInfo"/>
+ <element name="variable-info" type="pmapi:tVariableInfo"/>
+ <element name="activity-ext-info-list"
type="pmapi:tActivitytExtInfoList"/>
+ <element name="activity-ext-info"
type="pmapi:tActivityExtInfo"/>
+ <element name="event-info" type="pmapi:tEventInfo"/>
+ <element name="event-info-list"
type="pmapi:tEventInfoList"/>
+
+ <complexType name="tProcessInfo">
+ <annotation>
+ <documentation>Information about a BPEL process.</documentation>
+ </annotation>
+ <sequence>
+ <element name="pid" type="xs:string">
+ <annotation>
+ <documentation>The unique name/id of the
process.</documentation>
+ </annotation>
+ </element>
+ <element name="status"
type="pmapi:tProcessStatus">
+ <annotation>
+ <documentation>Process status.</documentation>
+ </annotation>
+ </element>
+ <element name="version" type="xs:long">
+ <annotation>
+ <documentation>Process version.</documentation>
+ </annotation>
+ </element>
+ <element name="definition-info"
type="pmapi:tDefinitionInfo">
+ <annotation>
+ <documentation>Information about the process
+ definition.</documentation>
+ </annotation>
+ </element>
+ <element name="deployment-info"
type="pmapi:tDeploymentInfo">
+ <annotation>
+ <documentation>Information about the process
+ deployment.</documentation>
+ </annotation>
+ </element>
+ <element name="instance-summary"
type="pmapi:tInstanceSummary" minOccurs="0">
+ <annotation>
+ <documentation>Summary of the instances belonging to this
+ process.</documentation>
+ </annotation>
+ </element>
+ <element name="properties"
type="pmapi:tProcessProperties">
+ <annotation>
+ <documentation>Process properties.</documentation>
+ </annotation>
+ </element>
+ <element name="endpoints"
type="pmapi:tEndpointReferences">
+ <annotation>
+ <documentation>Endpoint references.</documentation>
+ </annotation>
+ </element>
+ <element name="documents">
+ <annotation>
+ <documentation>Process documents</documentation>
+ </annotation>
+ <complexType>
+ <sequence>
+ <element name="document"
type="pmapi:tDocumentInfo" minOccurs="0"
maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ </element>
+ <any namespace="##other" processContents="lax"
minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <anyAttribute namespace="##other"
processContents="lax"/>
+ </complexType>
+ <simpleType name="tProcessStatus">
+ <annotation>
+ <documentation>Enumeration of process status.</documentation>
+ </annotation>
+ <restriction base="xs:string">
+ <enumeration value="ACTIVE">
+ <annotation>
+ <documentation>Process is accepting new
+ requests.</documentation>
+ </annotation>
+ </enumeration>
+ <enumeration value="RETIRED">
+ <annotation>
+ <documentation>Process is NOT accepting new
+ requests.</documentation>
+ </annotation>
+ </enumeration>
+ </restriction>
+ </simpleType>
+ <simpleType name="tActivityStatus">
+ <annotation>
+ <documentation>Enumeration of scope status.</documentation>
+ </annotation>
+ <restriction base="xs:string">
+ <enumeration value="ENABLED">
+ <annotation>
+ <documentation>Activity is enabled, but not necessarily ready
to execute.</documentation>
+ </annotation>
+ </enumeration>
+ <enumeration value="STARTED">
+ <annotation>
+ <documentation>Activity has started
execution.</documentation>
+ </annotation>
+ </enumeration>
+ <enumeration value="COMPLETED">
+ <annotation>
+ <documentation>Activity has finished
execution.</documentation>
+ </annotation>
+ </enumeration>
+ <enumeration value="FAILURE">
+ <annotation>
+ <documentation>Activity is in failure state, recovery
required.</documentation>
+ </annotation>
+ </enumeration>
+ </restriction>
+ </simpleType>
+ <simpleType name="tScopeStatus">
+ <annotation>
+ <documentation>Enumeration of scope status.</documentation>
+ </annotation>
+ <restriction base="xs:string">
+ <enumeration value="ACTIVE">
+ <annotation>
+ <documentation>Scope is active.</documentation>
+ </annotation>
+ </enumeration>
+ <enumeration value="COMPLETED">
+ <annotation>
+ <documentation>Scope has completed.</documentation>
+ </annotation>
+ </enumeration>
+ <enumeration value="FAULTED">
+ <annotation>
+ <documentation>Scope has faulted.</documentation>
+ </annotation>
+ </enumeration>
+ <enumeration value="FAULTHANDLING">
+ <annotation>
+ <documentation>Scope is executing its fault
+ handler.</documentation>
+ </annotation>
+ </enumeration>
+ <enumeration value="COMPENSATING">
+ <annotation>
+ <documentation>Scope is executing its compensation
+ handler.</documentation>
+ </annotation>
+ </enumeration>
+ <enumeration value="COMPENSATED">
+ <annotation>
+ <documentation>Scope has been
compensated.</documentation>
+ </annotation>
+ </enumeration>
+ </restriction>
+ </simpleType>
+ <complexType name="tDefinitionInfo">
+ <annotation>
+ <documentation>Information about the process
definition.</documentation>
+ </annotation>
+ <sequence>
+ <element name="process-name" type="xs:QName">
+ <annotation>
+ <documentation>The qualified name of the BPEL
+ process.</documentation>
+ </annotation>
+ </element>
+ </sequence>
+ </complexType>
+ <complexType name="tDocumentInfo">
+ <annotation>
+ <documentation>Information about a document.</documentation>
+ </annotation>
+ <sequence>
+ <element name="name" type="xs:string">
+ <annotation>
+ <documentation>Name of the document.</documentation>
+ </annotation>
+ </element>
+ <element name="type" type="xs:anyURI">
+ <annotation>
+ <documentation>Type of document (e.g.
+ WSDL/BPEL/etc...).</documentation>
+ </annotation>
+ </element>
+ <element name="source" type="xs:anyURI">
+ <annotation>
+ <documentation>URL where the document can be
+ retrieved.</documentation>
+ </annotation>
+ </element>
+ </sequence>
+ </complexType>
+ <complexType name="tDeploymentInfo">
+ <annotation>
+ <documentation>Information about a BPEL process
+ deployment.</documentation>
+ </annotation>
+ <sequence>
+ <element name="package" type="xs:string">
+ <annotation>
+ <documentation>Deployment package the process was deployed
into.</documentation>
+ </annotation>
+ </element>
+ <element name="document" type="xs:string">
+ <annotation>
+ <documentation>File name of BPEL document.</documentation>
+ </annotation>
+ </element>
+ <element name="deploy-date" type="xs:dateTime">
+ <annotation>
+ <documentation>Date the process was
deployed.</documentation>
+ </annotation>
+ </element>
+ <element name="deployer" type="xs:string">
+ <annotation>
+ <documentation>The user that deployed this
+ process.</documentation>
+ </annotation>
+ </element>
+ </sequence>
+ </complexType>
+ <complexType name="tProcessProperties">
+ <sequence>
+ <element name="property" minOccurs="0"
maxOccurs="unbounded">
+ <annotation>
+ <documentation>Process property (name-value
pair).</documentation>
+ </annotation>
+ <complexType>
+ <sequence>
+ <any namespace="##other"
processContents="lax" minOccurs="0"
maxOccurs="unbounded"/>
+ </sequence>
+ <attribute name="name" type="xs:QName">
+ <annotation>
+ <documentation>Name of the
property.</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+ </element>
+ </sequence>
+ </complexType>
+ <complexType name="tEndpointReferences">
+ <sequence>
+ <element name="endpoint-ref" minOccurs="0"
maxOccurs="unbounded">
+ <annotation>
+ <documentation>Endpoint references associated with the process
partner links roles.</documentation>
+ </annotation>
+ <complexType>
+ <sequence>
+ <any namespace="##other"
processContents="lax" minOccurs="0"
maxOccurs="unbounded"/>
+ </sequence>
+ <attribute name="partner-link"
type="xs:string">
+ <annotation>
+ <documentation>Name of the partner link this endpoint
reference is associated with.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="partner-role"
type="xs:string">
+ <annotation>
+ <documentation>Name of the partner role this endpoint
reference is associated with.</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+ </element>
+ </sequence>
+ </complexType>
+ <simpleType name="tInstanceStatus">
+ <annotation>
+ <documentation>Enumeration of instant status.</documentation>
+ </annotation>
+ <restriction base="xs:string">
+ <enumeration value="ACTIVE">
+ <annotation>
+ <documentation>Instance is active.</documentation>
+ </annotation>
+ </enumeration>
+ <enumeration value="COMPLETED">
+ <annotation>
+ <documentation>Instance has completed.</documentation>
+ </annotation>
+ </enumeration>
+ <enumeration value="TERMINATED">
+ <annotation>
+ <documentation>Instance was terminated.</documentation>
+ </annotation>
+ </enumeration>
+ <enumeration value="FAILED">
+ <annotation>
+ <documentation>Instance failed (with a
fault).</documentation>
+ </annotation>
+ </enumeration>
+ <enumeration value="SUSPENDED">
+ <annotation>
+ <documentation>Instance has been
suspended.</documentation>
+ </annotation>
+ </enumeration>
+ <enumeration value="ERROR">
+ <annotation>
+ <documentation>Instance is.....</documentation>
+ </annotation>
+ </enumeration>
+ </restriction>
+ </simpleType>
+ <complexType name="tInstanceSummary">
+ <annotation>
+ <documentation>A summary of the number of instances in each state.
+ </documentation>
+ </annotation>
+ <sequence>
+ <element name="instances" minOccurs="0"
maxOccurs="unbounded">
+ <complexType>
+ <attribute name="state"
type="pmapi:tInstanceStatus" use="required"/>
+ <attribute name="count" type="xs:int"
use="required"/>
+ </complexType>
+ </element>
+ <element name="failures" type="pmapi:tFailuresInfo"
minOccurs="0"/>
+ </sequence>
+ </complexType>
+ <complexType name="tScopeInfo">
+ <sequence>
+ <element name="siid" type="xs:string">
+ <annotation>
+ <documentation>Scope instance
identifier.</documentation>
+ </annotation>
+ </element>
+ <element name="name" type="xs:string">
+ <annotation>
+ <documentation>Scope name.</documentation>
+ </annotation>
+ </element>
+ <element name="status" type="pmapi:tScopeStatus">
+ <annotation>
+ <documentation>Scope instance
identifier.</documentation>
+ </annotation>
+ </element>
+ <element name="parent-scope-ref"
type="pmapi:tScopeRef" minOccurs="0">
+ <annotation>
+ <documentation>Parent scope reference.</documentation>
+ </annotation>
+ </element>
+ <element name="children" minOccurs="0">
+ <complexType>
+ <sequence>
+ <element name="child-ref"
type="pmapi:tScopeRef" minOccurs="0"
maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ </element>
+ <element name="activities" minOccurs="0">
+ <complexType>
+ <sequence>
+ <element ref="pmapi:activity-info"
minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ </element>
+ <element name="variables" minOccurs="0">
+ <complexType>
+ <sequence>
+ <element name="variable-ref"
type="pmapi:tVariableRef" minOccurs="0"
maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ </element>
+ <element name="correlation-sets" minOccurs="0">
+ <annotation>
+ <documentation>Lists all correlation correlation sets
associated with
+ this scope with their valued correlation
properties.</documentation>
+ </annotation>
+ <complexType>
+ <sequence>
+ <element name="correlation-set"
maxOccurs="unbounded">
+ <complexType>
+ <sequence>
+ <element name="correlation-property"
type="pmapi:tCorrelationProperty" maxOccurs="unbounded"/>
+ </sequence>
+ <attribute name="name"
type="xs:string" use="required"/>
+ <attribute name="csetid"
type="xs:string" use="required"/>
+ </complexType>
+ </element>
+ </sequence>
+ </complexType>
+ </element>
+ <element name="endpoints"
type="pmapi:tEndpointReferences">
+ <annotation>
+ <documentation>Endpoint references.</documentation>
+ </annotation>
+ </element>
+ </sequence>
+ </complexType>
+ <complexType name="tActivityInfo">
+ <annotation>
+ <documentation>Information about an activity.
+ </documentation>
+ </annotation>
+ <sequence>
+ <element name="name" type="xs:string"
minOccurs="0"/>
+ <element name="type" type="xs:string"/>
+ <element name="aiid" type="xs:string"/>
+ <element name="status"
type="pmapi:tActivityStatus"/>
+ <element name="scope" type="pmapi:tScopeRef"
minOccurs="0">
+ <annotation>
+ <documentation>ID for scope in which this activity is
executing.</documentation>
+ </annotation>
+ </element>
+ <element name="dt-enabled" type="xs:dateTime"
minOccurs="0">
+ <annotation>
+ <documentation>The date/time when the activity was
enabled.</documentation>
+ </annotation>
+ </element>
+ <element name="dt-started" type="xs:dateTime"
minOccurs="0">
+ <annotation>
+ <documentation>The date/time when the activity was
+ started.</documentation>
+ </annotation>
+ </element>
+ <element name="dt-completed" type="xs:dateTime"
minOccurs="0">
+ <annotation>
+ <documentation>The date/time when the activity was
+ completed.</documentation>
+ </annotation>
+ </element>
+ <element name="failure" type="pmapi:tFailureInfo"
minOccurs="0">
+ <annotation>
+ <documentation>Indicates activity is in the failure state and
requires recovery.</documentation>
+ </annotation>
+ </element>
+ </sequence>
+ </complexType>
+ <complexType name="tFailureInfo">
+ <annotation>
+ <documentation>Indicates activity is in the failure state and requires
recovery.</documentation>
+ </annotation>
+ <sequence>
+ <element name="dt-failure" type="xs:dateTime">
+ <annotation>
+ <documentation>The date/time when failure
occurred.</documentation>
+ </annotation>
+ </element>
+ <element name="retries" type="xs:int">
+ <annotation>
+ <documentation>Number of retries.</documentation>
+ </annotation>
+ </element>
+ <element name="reason" type="xs:string">
+ <annotation>
+ <documentation>Reason for failure.</documentation>
+ </annotation>
+ </element>
+ <element name="actions" type="xs:string">
+ <annotation>
+ <documentation>Allowed recovery actions (space separated list of
action names).</documentation>
+ </annotation>
+ </element>
+ </sequence>
+ </complexType>
+ <complexType name="tVariableInfo">
+ <annotation>
+ <documentation>Information about a variable (basically the value)
+ </documentation>
+ </annotation>
+ <sequence>
+ <element name="self" type="pmapi:tVariableRef"/>
+ <element name="value" minOccurs="0">
+ <complexType>
+ <sequence>
+ <any namespace="##other"
processContents="lax" minOccurs="0"
maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ </element>
+ </sequence>
+ </complexType>
+ <complexType name="tInstanceInfo">
+ <sequence>
+ <element name="iid" type="xs:string">
+ <annotation>
+ <documentation>The unique instance identifier.
</documentation>
+ </annotation>
+ </element>
+ <element name="pid" type="xs:string">
+ <annotation>
+ <documentation>Process id of the process to which this
instance
+ belongs.</documentation>
+ </annotation>
+ </element>
+ <element name="process-name" type="QName"/>
+ <element name="root-scope" type="pmapi:tScopeRef"
minOccurs="0">
+ <annotation>
+ <documentation>Root scope id (might not exist).
</documentation>
+ </annotation>
+ </element>
+ <element name="status"
type="pmapi:tInstanceStatus">
+ <annotation>
+ <documentation>Status of ths instance.</documentation>
+ </annotation>
+ </element>
+ <element name="dt-started" type="xs:dateTime">
+ <annotation>
+ <documentation>The date/time when the instance was
+ started.</documentation>
+ </annotation>
+ </element>
+ <element name="dt-last-active" type="xs:dateTime">
+ <annotation>
+ <documentation>The date/time when the last activity
+ occured.</documentation>
+ </annotation>
+ </element>
+ <element name="dt-error-since" type="xs:dateTime"
minOccurs="0">
+ <annotation>
+ <documentation> If present, indicates the date/time since which
the
+ instance has been in an error state. </documentation>
+ </annotation>
+ </element>
+ <element name="correlation-properties"
minOccurs="0">
+ <annotation>
+ <documentation>Lists all correlation properties with their
values that
+ are associated with this process instance.</documentation>
+ </annotation>
+ <complexType>
+ <sequence>
+ <element name="correlation-property"
type="pmapi:tCorrelationProperty" maxOccurs="unbounded">
+ <annotation>
+ <documentation>Instance correlation
property.</documentation>
+ </annotation>
+ </element>
+ </sequence>
+ </complexType>
+ </element>
+ <element name="event-info" minOccurs="0">
+ <annotation>
+ <documentation> Information about the events for this instance.
If
+ absent, indicates events are not available.
</documentation>
+ </annotation>
+ <complexType>
+ <sequence>
+ <element name="count" type="xs:int">
+ <annotation>
+ <documentation> Indicates the datetime of the first
event
+ </documentation>
+ </annotation>
+ </element>
+ <element name="first-dtime"
type="xs:dateTime">
+ <annotation>
+ <documentation> Indicates the datetime of the first
event
+ </documentation>
+ </annotation>
+ </element>
+ <element name="last-dtime"
type="xs:dateTime">
+ <annotation>
+ <documentation> Indicates the datetime of the last
event.
+ </documentation>
+ </annotation>
+ </element>
+ </sequence>
+ </complexType>
+ </element>
+ <element name="fault-info" type="pmapi:tFaultInfo"
minOccurs="0">
+ <annotation>
+ <documentation> If present, indicates the fault with which
this
+ instance failed. </documentation>
+ </annotation>
+ </element>
+ <element name="failures" type="pmapi:tFailuresInfo"
minOccurs="0"/>
+ <element name="myElement" type="string"/>
+ </sequence>
+ </complexType>
+ <complexType name="tScopeRef">
+ <annotation>
+ <documentation> Reference to a scope. </documentation>
+ </annotation>
+ <attribute name="siid" type="xs:string"
use="required"/>
+ <attribute name="name" type="xs:string"
use="optional"/>
+ <attribute name="modelId" type="xs:string"
use="required"/>
+ <attribute name="status" type="pmapi:tScopeStatus"
use="required"/>
+ </complexType>
+ <complexType name="tVariableRef">
+ <annotation>
+ <documentation>Reference to a variable.</documentation>
+ </annotation>
+ <attribute name="iid" type="xs:string"
use="required"/>
+ <attribute name="siid" type="xs:string"
use="required"/>
+ <attribute name="name" type="xs:string"
use="required"/>
+ </complexType>
+ <complexType name="tFaultInfo">
+ <annotation>
+ <documentation> Type used for reporting faults. </documentation>
+ </annotation>
+ <sequence>
+ <element name="name" type="xs:QName"/>
+ <element name="explanation" type="xs:string"/>
+ <element name="line-number" type="xs:int"/>
+ <element name="aiid" type="xs:int"/>
+ <element name="data" minOccurs="0">
+ <complexType>
+ <sequence>
+ <any namespace="##other"
processContents="lax" minOccurs="0"
maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ </element>
+ </sequence>
+ </complexType>
+ <complexType name="tFailuresInfo">
+ <annotation>
+ <documentation>Indicates one or more activities are in the failure
+ state and require recovery.</documentation>
+ </annotation>
+ <sequence>
+ <element name="dt-failure" type="xs:dateTime">
+ <annotation>
+ <documentation>Date/time of last
failure.</documentation>
+ </annotation>
+ </element>
+ <element name="count" type="xs:int">
+ <annotation>
+ <documentation>Number of activities in failure
state.</documentation>
+ </annotation>
+ </element>
+ </sequence>
+ </complexType>
+ <!-- Yew that's ugly, but there aren't so many ways to map an heritage
-->
+ <complexType name="tEventInfo">
+ <sequence>
+ <element name="name" type="xs:string"/>
+ <element name="type" type="xs:string"/>
+ <element name="line-number" type="xs:int"/>
+ <element name="timestamp" type="xs:dateTime"/>
+ <element name="process-id" type="xs:QName"
minOccurs="0" maxOccurs="1"/>
+ <element name="process-type" type="xs:QName"
minOccurs="0" maxOccurs="1"/>
+ <element name="instance-id" type="xs:long"
minOccurs="0" maxOccurs="1"/>
+ <element name="scope-id" type="xs:long"
minOccurs="0" maxOccurs="1"/>
+ <element name="parent-scope-id" type="xs:long"
minOccurs="0" maxOccurs="1"/>
+ <element name="scope-name" type="xs:string"
minOccurs="0" maxOccurs="1"/>
+ <element name="scope-definition-id" type="xs:int"
minOccurs="0" maxOccurs="1"/>
+ <element name="activity-id" type="xs:long"
minOccurs="0" maxOccurs="1"/>
+ <element name="activity-name" type="xs:string"
minOccurs="0" maxOccurs="1"/>
+ <element name="activity-type" type="xs:string"
minOccurs="0" maxOccurs="1"/>
+ <element name="activity-definition-id" type="xs:int"
minOccurs="0" maxOccurs="1"/>
+ <element name="activity-failure-reason"
type="xs:string" minOccurs="0" maxOccurs="1"/>
+ <element name="activity-recovery-action"
type="xs:string" minOccurs="0" maxOccurs="1"/>
+ <element name="variable-name" type="xs:string"
minOccurs="0" maxOccurs="1"/>
+ <element name="port-type" type="xs:QName"
minOccurs="0" maxOccurs="1"/>
+ <element name="operation" type="xs:string"
minOccurs="0" maxOccurs="1"/>
+ <element name="correlation-set" type="xs:string"
minOccurs="0" maxOccurs="1"/>
+ <element name="mex-id" type="xs:string"
minOccurs="0" maxOccurs="1"/>
+ <element name="correlation-key" type="xs:string"
minOccurs="0" maxOccurs="1"/>
+ <element name="expression" type="xs:string"
minOccurs="0" maxOccurs="1"/>
+ <element name="fault" type="xs:QName"
minOccurs="0" maxOccurs="1"/>
+ <element name="fault-line-number" type="xs:int"
minOccurs="0" maxOccurs="1"/>
+ <element name="explanation" type="xs:string"
minOccurs="0" maxOccurs="1"/>
+ <element name="result" type="xs:string"
minOccurs="0" maxOccurs="1"/>
+ <element name="root-scope-id" type="xs:long"
minOccurs="0" maxOccurs="1"/>
+ <element name="root-scope-declaration-id"
type="xs:int" minOccurs="0" maxOccurs="1"/>
+ <element name="partner-link-name" type="xs:string"
minOccurs="0" maxOccurs="1"/>
+ <element name="old-state" type="xs:int"
minOccurs="0" maxOccurs="1"/>
+ <element name="new-state" type="xs:int"
minOccurs="0" maxOccurs="1"/>
+ <element name="success" type="xs:boolean"
minOccurs="0" maxOccurs="1"/>
+ </sequence>
+ </complexType>
+ <complexType name="tInstanceInfoList">
+ <sequence>
+ <element ref="pmapi:instance-info" minOccurs="0"
maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <complexType name="tProcessInfoList">
+ <sequence>
+ <element ref="pmapi:process-info" minOccurs="0"
maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <complexType name="tEventInfoList">
+ <sequence>
+ <element ref="pmapi:event-info" minOccurs="0"
maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <complexType name="tCorrelationProperty" mixed="true">
+ <simpleContent>
+ <extension base="xs:string">
+ <attribute name="csetid" type="xs:string"
use="required"/>
+ <attribute name="propertyName" type="xs:QName"
use="required"/>
+ </extension>
+ </simpleContent>
+ </complexType>
+
+ <complexType name="tActivityExtInfo">
+ <annotation>
+ <documentation>Information about an activity.
+ </documentation>
+ </annotation>
+ <sequence>
+ <element name="aiid" type="xs:string"/>
+ <any namespace="##other" processContents="lax"
minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+ <complexType name="tActivitytExtInfoList">
+ <sequence>
+ <element ref="pmapi:activity-ext-info" minOccurs="0"
maxOccurs="unbounded"/>
+ </sequence>
+ </complexType>
+
+</xsd:schema>
+
+
+ <xsd:schema
targetNamespace="http://www.apache.org/ode/pmapi">
+ <xsd:complexType name="aidsType">
+ <xsd:all>
+ <xsd:element name="aid"
type="xsd:string"/>
+ </xsd:all>
+ </xsd:complexType>
+ <xsd:complexType name="listType">
+ <xsd:all>
+ <xsd:element name="element"
type="xsd:string"/>
+ </xsd:all>
+ </xsd:complexType>
+ <xsd:complexType name="iidsType">
+ <xsd:all>
+ <xsd:element name="iid" type="xsd:long"/>
+ </xsd:all>
+ </xsd:complexType>
+ <xsd:element name="ManagementFault"
type="xsd:string"/>
+ </xsd:schema>
+ </types>
+
+ <message name="listProcessesInput">
+ <part name="filter" type="xsd:string"/>
+ <part name="orderKeys" type="xsd:string"/>
+ </message>
+ <message name="listProcessesOutput">
+ <part name="process-info-list"
type="typ:tProcessInfoList"/>
+ </message>
+ <message name="listProcessesCustomInput">
+ <part name="filter" type="xsd:string"/>
+ <part name="orderKeys" type="xsd:string"/>
+ <part name="customizer" type="xsd:string"/>
+ </message>
+ <message name="listProcessesCustomOutput">
+ <part name="process-info-list"
type="typ:tProcessInfoList"/>
+ </message>
+ <message name="listAllProcessesInput"/>
+ <message name="listAllProcessesOutput">
+ <part name="process-info-list"
type="typ:tProcessInfoList"/>
+ </message>
+ <message name="getProcessInfoInput">
+ <part name="pid" type="xsd:QName"/>
+ </message>
+ <message name="getProcessInfoOutput">
+ <part name="process-info" type="typ:tProcessInfo"/>
+ </message>
+ <message name="getProcessInfoCustomInput">
+ <part name="pid" type="xsd:QName"/>
+ <part name="customizer" type="xsd:string"/>
+ </message>
+ <message name="getProcessInfoCustomOutput">
+ <part name="process-info" type="typ:tProcessInfo"/>
+ </message>
+ <message name="getExtensibilityElementsInput">
+ <part name="pid" type="xsd:QName"/>
+ <part name="aids" type="tns:aidsType"/>
+ </message>
+ <message name="getExtensibilityElementsOutput">
+ <part name="process-info" type="typ:tProcessInfo"/>
+ </message>
+ <message name="setProcessPropertyNodeInput">
+ <part name="pid" type="xsd:QName"/>
+ <part name="propertyName" type="xsd:QName"/>
+ <part name="propertyValue" type="xsd:anyType"/>
+ </message>
+ <message name="setProcessPropertyNodeOutput">
+ <part name="process-info" type="typ:tProcessInfo"/>
+ </message>
+ <message name="setProcessPropertyInput">
+ <part name="pid" type="xsd:QName"/>
+ <part name="propertyName" type="xsd:QName"/>
+ <part name="propertyValue" type="xsd:string"/>
+ </message>
+ <message name="setProcessPropertyOutput">
+ <part name="process-info" type="typ:tProcessInfo"/>
+ </message>
+ <message name="activateInput">
+ <part name="pid" type="xsd:QName"/>
+ </message>
+ <message name="activateOutput">
+ <part name="process-info" type="typ:tProcessInfo"/>
+ </message>
+ <message name="setRetiredInput">
+ <part name="pid" type="xsd:QName"/>
+ <part name="retired" type="xsd:boolean"/>
+ </message>
+ <message name="setRetiredOutput">
+ <part name="process-info" type="typ:tProcessInfo"/>
+ </message>
+
+ <message name="listInstancesInput">
+ <part name="filter" type="xsd:string"/>
+ <part name="order" type="xsd:string"/>
+ <part name="limit" type="xsd:int"/>
+ </message>
+ <message name="listInstancesOutput">
+ <part name="instance-info-list"
type="typ:tInstanceInfoList"/>
+ </message>
+ <message name="queryInstancesInput">
+ <part name="payload" type="xsd:string"/>
+ </message>
+ <message name="queryInstancesOutput">
+ <part name="instance-info-list"
type="typ:tInstanceInfoList"/>
+ </message>
+ <message name="listAllInstancesInput"/>
+ <message name="listAllInstancesOutput">
+ <part name="instance-info-list"
type="typ:tInstanceInfoList"/>
+ </message>
+ <message name="listAllInstancesWithLimitInput">
+ <part name="payload" type="xsd:int"/>
+ </message>
+ <message name="listAllInstancesWithLimitOutput">
+ <part name="instance-info-list"
type="typ:tInstanceInfoList"/>
+ </message>
+ <message name="getInstanceInfoInput">
+ <part name="iid" type="xsd:long"/>
+ </message>
+ <message name="getInstanceInfoOutput">
+ <part name="instance-info" type="typ:tInstanceInfo"/>
+ </message>
+ <message name="getScopeInfoInput">
+ <part name="siid" type="xsd:long"/>
+ </message>
+ <message name="getScopeInfoOutput">
+ <part name="scope-info" type="typ:tScopeInfo"/>
+ </message>
+ <message name="getScopeInfoWithActivityInput">
+ <part name="sid" type="xsd:long"/>
+ <part name="activityInfo" type="xsd:boolean"/>
+ </message>
+ <message name="getScopeInfoWithActivityOutput">
+ <part name="scope-info" type="typ:tScopeInfo"/>
+ </message>
+ <message name="getVariableInfoInput">
+ <part name="sid" type="xsd:string"/>
+ <part name="varName" type="xsd:string"/>
+ </message>
+ <message name="getVariableInfoOutput">
+ <part name="scope-info" type="typ:tVariableInfo"/>
+ </message>
+ <message name="listEventsInput">
+ <part name="instanceFilter" type="xsd:string"/>
+ <part name="eventFilter" type="xsd:string"/>
+ <part name="maxCount" type="xsd:int"/>
+ </message>
+ <message name="listEventsOutput">
+ <part name="bpel-event-list"
type="typ:tEventInfoList"/>
+ </message>
+ <message name="getEventTimelineInput">
+ <part name="instanceFilter" type="xsd:string"/>
+ <part name="eventFilter" type="xsd:string"/>
+ </message>
+ <message name="getEventTimelineOutput">
+ <part name="dates" type="tns:listType"/>
+ </message>
+ <message name="suspendInput">
+ <part name="iid" type="xsd:long"/>
+ </message>
+ <message name="suspendOutput">
+ <part name="instance-info" type="typ:tInstanceInfo"/>
+ </message>
+ <message name="resumeInput">
+ <part name="iid" type="xsd:long"/>
+ </message>
+ <message name="resumeOutput">
+ <part name="instance-info" type="typ:tInstanceInfo"/>
+ </message>
+ <message name="terminateInput">
+ <part name="iid" type="xsd:long"/>
+ </message>
+ <message name="terminateOutput">
+ <part name="instance-info" type="typ:tInstanceInfo"/>
+ </message>
+ <message name="faultInput">
+ <part name="iid" type="xsd:long"/>
+ </message>
+ <message name="faultOutput">
+ <part name="instance-info" type="typ:tInstanceInfo"/>
+ </message>
+ <message name="deleteInput">
+ <part name="filter" type="xsd:string"/>
+ </message>
+ <message name="deleteOutput">
+ <part name="iids" type="tns:iidsType"/>
+ </message>
+ <message name="recoverActivityInput">
+ <part name="iid" type="xsd:long"/>
+ <part name="aid" type="xsd:long"/>
+ <part name="action" type="xsd:string"/>
+ </message>
+ <message name="recoverActivityOutput">
+ <part name="instance-info" type="typ:tInstanceInfo"/>
+ </message>
+ <message name="managementFault">
+ <part name="managementFault"
element="tns:ManagementFault"/>
+ </message>
+
+ <portType name="ProcessManagementPortType">
+ <operation name="listProcesses">
+ <input message="tns:listProcessesInput"/>
+ <output message="tns:listProcessesOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
+ <operation name="listAllProcesses">
+ <input message="tns:listAllProcessesInput"/>
+ <output message="tns:listAllProcessesOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
+ <operation name="listProcessesCustom">
+ <input message="tns:listProcessesCustomInput"/>
+ <output message="tns:listProcessesCustomOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
+ <operation name="getProcessInfo">
+ <input message="tns:getProcessInfoInput"/>
+ <output message="tns:getProcessInfoOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
+ <operation name="getProcessInfoCustom">
+ <input message="tns:getProcessInfoCustomInput"/>
+ <output message="tns:getProcessInfoCustomOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
+ <operation name="setProcessProperty">
+ <input message="tns:setProcessPropertyInput"/>
+ <output message="tns:setProcessPropertyOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
+ <operation name="setProcessPropertyNode">
+ <input message="tns:setProcessPropertyNodeInput"/>
+ <output message="tns:setProcessPropertyNodeOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
+ <operation name="getExtensibilityElements">
+ <input message="tns:getExtensibilityElementsInput"/>
+ <output message="tns:getExtensibilityElementsOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
+ <operation name="activate">
+ <input message="tns:activateInput"/>
+ <output message="tns:activateOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
+ <operation name="setRetired">
+ <input message="tns:setRetiredInput"/>
+ <output message="tns:setRetiredOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
+ </portType>
+
+ <portType name="InstanceManagementPortType">
+ <operation name="listInstances">
+ <input message="tns:listInstancesInput"/>
+ <output message="tns:listInstancesOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
+ <operation name="queryInstances">
+ <input message="tns:queryInstancesInput"/>
+ <output message="tns:queryInstancesOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
+ <operation name="listAllInstances">
+ <input message="tns:listAllInstancesInput"/>
+ <output message="tns:listAllInstancesOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
+ <operation name="listAllInstancesWithLimit">
+ <input message="tns:listAllInstancesWithLimitInput"/>
+ <output message="tns:listAllInstancesWithLimitOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
+ <operation name="getInstanceInfo">
+ <input message="tns:getInstanceInfoInput"/>
+ <output message="tns:getInstanceInfoOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
+ <operation name="getScopeInfo">
+ <input message="tns:getScopeInfoInput"/>
+ <output message="tns:getScopeInfoOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
+ <operation name="getScopeInfoWithActivity">
+ <input message="tns:getScopeInfoWithActivityInput"/>
+ <output message="tns:getScopeInfoWithActivityOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
+ <operation name="getVariableInfo">
+ <input message="tns:getVariableInfoInput"/>
+ <output message="tns:getVariableInfoOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
+ <operation name="listEvents">
+ <input message="tns:listEventsInput"/>
+ <output message="tns:listEventsOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
+ <operation name="getEventTimeline">
+ <input message="tns:getEventTimelineInput"/>
+ <output message="tns:getEventTimelineOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
+ <operation name="suspend">
+ <input message="tns:suspendInput"/>
+ <output message="tns:suspendOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
+ <operation name="resume">
+ <input message="tns:resumeInput"/>
+ <output message="tns:resumeOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
+ <operation name="terminate">
+ <input message="tns:terminateInput"/>
+ <output message="tns:terminateOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
+ <operation name="fault">
+ <input message="tns:faultInput"/>
+ <output message="tns:faultOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
+ <operation name="delete">
+ <input message="tns:deleteInput"/>
+ <output message="tns:deleteOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
+ <operation name="recoverActivity">
+ <input message="tns:recoverActivityInput"/>
+ <output message="tns:recoverActivityOutput"/>
+ <fault name="ManagementFault"
message="tns:managementFault"/>
+ </operation>
+ </portType>
+
+ <binding name="ProcessManagementBinding"
type="tns:ProcessManagementPortType">
+ <soap:binding style="rpc"
transport="http://schemas.xmlsoap.org/soap/http"/>
+ <operation name="listProcesses">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
+ <operation name="listAllProcesses">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
+ <operation name="listProcessesCustom">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
+ <operation name="getProcessInfo">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
+ <operation name="getProcessInfoCustom">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
+ <operation name="getExtensibilityElements">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
+ <operation name="setProcessProperty">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
+ <operation name="setProcessPropertyNode">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
+ <operation name="activate">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
+ <operation name="setRetired">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
+ </binding>
+
+ <binding name="InstanceManagementBinding"
type="tns:InstanceManagementPortType">
+ <soap:binding style="rpc"
transport="http://schemas.xmlsoap.org/soap/http"/>
+ <operation name="listInstances">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
+ <operation name="queryInstances">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
+ <operation name="listAllInstances">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
+ <operation name="listAllInstancesWithLimit">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
+ <operation name="getInstanceInfo">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
+ <operation name="getScopeInfo">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
+ <operation name="getScopeInfoWithActivity">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
+ <operation name="getVariableInfo">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
+ <operation name="listEvents">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
+ <operation name="getEventTimeline">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
+ <operation name="suspend">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
+ <operation name="resume">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
+ <operation name="terminate">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
+ <operation name="fault">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
+ <operation name="delete">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
+ <operation name="recoverActivity">
+ <soap:operation soapAction="" style="rpc"/>
+ <input>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </input>
+ <output>
+ <soap:body
namespace="http://www.apache.org/ode/pmapi"
use="literal"/>
+ </output>
+ <fault name="ManagementFault">
+ <soap:fault name="ManagementFault"
use="literal"/>
+ </fault>
+ </operation>
+ </binding>
+
+ <service name="ProcessManagementService">
+ <port name="ProcessManagementPort"
binding="tns:ProcessManagementBinding">
+ <soap:address
location="http://localhost:8080/ode/processes/ProcessManagement"/>
+ <smix:endpoint role="consumer"
defaultMep="in-out"/>
+
+ </port>
+ </service>
+ <service name="InstanceManagementService">
+ <port name="InstanceManagementPort"
binding="tns:InstanceManagementBinding">
+ <soap:address
location="http://localhost:8080/ode/processes/InstanceManagement"/>
+ <smix:endpoint role="consumer"
defaultMep="in-out"/>
+ </port>
+ </service>
+
+</definitions>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/ProcessManagement/build.xml
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/ProcessManagement/build.xml
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/ProcessManagement/build.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<project name="ProcessManagement" default="assembly">
+
+ <import file="../base-sa.xml" />
+
+ <target name="test" depends="init">
+ <antcall target="_sendsoap">
+ <param name="ode.sendsoap.url"
value="http://localhost:${ode.http.port}/ode/processes/ProcessManagement/"/>
+ <param name="ode.sendsoap.filename"
location="message.soap"/>
+ </antcall>
+ </target>
+
+</project>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/ProcessManagement/jbi.xml
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/ProcessManagement/jbi.xml
(rev 0)
+++ branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/ProcessManagement/jbi.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,41 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<jbi version="1.0"
xmlns="http://java.sun.com/xml/ns/jbi">
+ <service-assembly>
+ <identification>
+ <name>ProcessManagement-SA</name>
+ <description>Process Management API Service Assembly</description>
+ </identification>
+
+ <service-unit>
+ <identification>
+ <name>ProcessManagement-http</name>
+ <description>Process Management API HTTP Binding</description>
+ </identification>
+
+ <target>
+ <artifacts-zip>ProcessManagement-HTTP.zip</artifacts-zip>
+ <component-name>servicemix-http</component-name>
+ </target>
+ </service-unit>
+
+ </service-assembly>
+</jbi>
+
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/ProcessManagement/message.soap
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/ProcessManagement/message.soap
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/ProcessManagement/message.soap 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<SOAP-ENV:Envelope
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
+ <SOAP-ENV:Body>
+ <pmapi:listAllProcesses
xmlns:pmapi="http://www.apache.org/ode/pmapi/types/2006/08/02/"...
+ <!--
+ <pmapi:listProcesses
xmlns:pmapi="http://www.apache.org/ode/pmapi/types/2006/08/02/"...
+ <filter>name=Hello*</filter>
+ <orderKeys></orderKeys>
+ </pmapi:listProcesses>
+ -->
+ </SOAP-ENV:Body>
+</SOAP-ENV:Envelope>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/base-sa.xml
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/base-sa.xml
(rev 0)
+++ branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/base-sa.xml 2010-04-14 18:25:55 UTC
(rev 620)
@@ -0,0 +1,58 @@
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<!-- ANT Build File used for building JBI examples. This file
+ is imported from each example directory, and should not
+ be used directly. -->
+
+<project name="base-sa" >
+ <import file="base.xml" />
+
+ <property name="safilename" value="${ant.project.name}-sa.zip"
/>
+ <property name="safile" location="${build.dir}/${safilename}"
/>
+ <property name="sus.dir" location="${build.dir}/su" />
+
+ <target name="clean">
+ <delete dir="${build.dir}"/>
+ <subant target="clean">
+ <fileset dir="${basedir}" includes="*/build.xml"/>
+ </subant>
+ </target>
+
+ <target name="service-units" depends="init" >
+ <subant target="service-unit">
+ <property name="dist.dir" value="${sus.dir}" />
+ <property name="ode.home" value="${ode.home}" />
+ <fileset dir="." includes="*/build.xml"/>
+ </subant>
+ </target>
+
+ <target name="init" depends="base.init">
+ <mkdir dir="${build.dir}" />
+ <mkdir dir="${sus.dir}" />
+ </target>
+
+ <target name="assembly" depends="init,service-units">
+
+ <zip destfile="${safile}">
+ <fileset dir="${sus.dir}" includes="*" />
+ <zipfileset dir="." includes="jbi.xml"
prefix="META-INF/" />
+ </zip>
+ </target>
+</project>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/base-su.xml
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/base-su.xml
(rev 0)
+++ branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/base-su.xml 2010-04-14 18:25:55 UTC
(rev 620)
@@ -0,0 +1,44 @@
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<project name="base-su" >
+
+ <import file="base.xml" />
+
+ <property name="sufilename" value="${ant.project.name}.zip"
/>
+
+ <property name="stage.dir" location="${build.dir}/stage"
/>
+ <property name="sufile" location="${dist.dir}/${sufilename}"
/>
+
+ <target name="clean" description="Clean intermediate
artifacts.">
+ <delete dir="${build.dir}"/>
+ </target>
+
+
+ <target name="build" depends="init" >
+ <copy todir="${stage.dir}">
+ <fileset dir="${basedir}" includes="*"
excludes="build.xml,build" />
+ </copy>
+ </target>
+
+ <target name="service-unit" depends="init,build">
+ <zip destfile="${sufile}">
+ <fileset dir="${stage.dir}" includes="**/*"/>
+ </zip>
+ </target>
+</project>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/base.xml
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/base.xml (rev
0)
+++ branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/base.xml 2010-04-14 18:25:55 UTC (rev
620)
@@ -0,0 +1,136 @@
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<!-- ANT Build File used for building JBI examples. This file
+ is imported from each example directory, and should not
+ be used directly. -->
+
+<project name="base" >
+ <property environment="env"/>
+
+ <!-- Use ODE_HOME environment variable if available, otherwise assume
$basedir/../.. -->
+ <condition property="ode.home" value="${env.ODE_HOME}"
else="${basedir}/../../">
+ <isset property="env.ODE_HOME"/>
+ </condition>
+
+ <property file="${basedir}/../example.properties"/>
+
+ <!-- pick up environmental ode.xxx properties -->
+ <property file="${ode.home}/etc/ode.properties"/>
+
+ <property name="lib.dir" location="${ode.home}/lib"/>
+ <property name="etc.dir" location="${ode.home}/etc" />
+
+ <property name="build.dir" location="${basedir}/build" />
+
+ <target name="clean" description="Clean intermediate
artifacts.">
+ <delete dir="${build.dir}"/>
+ </target>
+
+
+ <target name="init-extensions">
+ <condition property="ode.script.extension"
value=".bat">
+ <os family="windows"/>
+ </condition>
+ <condition property="ode.script.extension" value="">
+ <os family="unix"/>
+ </condition>
+ <condition property="ode.exe.extension" value=".exe">
+ <os family="windows"/>
+ </condition>
+ <condition property="ode.exe.extension" value="">
+ <os family="unix"/>
+ </condition>
+ </target>
+
+ <!-- if example.properties has ode.java.home assigned it has highest priority
+ and overrides the system environment JAVA_HOME
+
+ if ode.java.home not set in example.properties and system environment
+ JAVA_HOME is set then ode.java.home becomes JAVA_HOME -->
+
+ <target name="try-ENV-java-underscore-home" if="Env-JAVA_HOME"
unless="ode.java.home">
+ <echo message="'ode.java.home' not set trying
'Env-JAVA_HOME'"/>
+ <property name="ode.java.home"
value="${Env-JAVA_HOME}"/>
+ </target>
+
+ <target name="try-jdk-dot-home" if="jdk.home"
unless="ode.java.home">
+ <echo message="'ode.java.home' not set trying
'jdk.home'"/>
+ <property name="ode.java.home" value="${jdk.home}"/>
+ </target>
+
+ <target name="try-java-dot-home" if="java.home"
unless="ode.java.home">
+ <echo message="'ode.java.home' not set trying
'java.home'"/>
+ <property name="ode.java.home" value="${java.home}"/>
+ </target>
+
+ <target name="fail-no-ode-java-home"
depends="try-ENV-java-underscore-home,try-jdk-dot-home,try-java-dot-home"
unless="ode.java.home">
+ <fail message="property 'ode.java.home' is not set (try sys env
JAVA_HOME or setting ode.java.home in example.properties)"/>
+ </target>
+
+ <target name="validate-ode-java-home"
depends="init-extensions,fail-no-ode-java-home"
if="ode.java.home">
+ <available file="${ode.java.home}/bin/java${ode.exe.extension}"
property="ode.java.home.good"/>
+ </target>
+
+ <target name="fail-invalid-ode-java-home"
depends="validate-ode-java-home" unless="ode.java.home.good">
+ <fail message="Java Home invalid:
'ode.java.home'=${ode.java.home}"/>
+ </target>
+
+ <target name="validate-ode-home">
+ <available file="${lib.dir}/ode-bpel-compiler.jar"
property="ode.home.good"/>
+ </target>
+
+ <target name="fail-invalid-ode-home"
depends="validate-ode-home" unless="ode.home.good">
+ <fail message="Invalid property
'ode.home'=${ode.home}"/>
+ </target>
+
+ <target name="init"
depends="init-extensions,fail-invalid-ode-home,fail-invalid-ode-java-home">
+ <echo message="ode.home = ${ode.home}"/>
+ <echo message="ode.java.home = ${ode.java.home}"/>
+
+ <!-- Ant Env Takes gets first crack at basic ode properties override -->
+ <!-- example.properties gets second crack at basic ode properties override
-->
+ <!-- ode.properties is default authority -->
+ <property file="${ode.home}/etc/ode.properties"/>
+
+ <property name="ode.default.javaopts"
+ value=""/>
+
+ <path id="cpath.ode">
+ <fileset dir="${lib.dir}" includes="**/*.jar" />
+ <pathelement location="${ode.home}/etc" />
+ </path>
+
+ <taskdef classpathref="cpath.ode"
resource="org/apache/ode/tools/anttasks.properties"
+ onerror="ignore" />
+
+ <mkdir dir="${build.dir}"/>
+ </target>
+
+ <target name="_sendsoap" depends="init">
+ <echo message="ode.sendsoap.url=${ode.sendsoap.url}"/>
+ <echo message="ode.sendsoap.filename=${ode.sendsoap.filename}"/>
+ <exec executable="${ode.home}/bin/sendsoap${ode.script.extension}"
dir="${ode.home}">
+ <env key="JAVA_HOME" value="${ode.java.home}"/>
+ <arg value="${ode.sendsoap.url}"/>
+ <arg value="${ode.sendsoap.filename}"/>
+ </exec>
+ </target>
+
+</project>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/example.properties
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/example.properties
(rev 0)
+++ branches/ODE/ODE-1.x/distro/src/examples-jbi/ant/example.properties 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,27 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+#
http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+#
+# customize any properties for your environment
+#
+ode.start.args=-v -console
+ode.javaopts.env=
+
+ode.default.http.port=8080
+ode.http.port=8080
+
+ode.home=../../bin
\ No newline at end of file
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/README.txt
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/README.txt
(rev 0)
+++ branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/README.txt 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,5 @@
+This example demonstrates particularly a feature, which enables adding java code inside
JBI Service Unit and invoking it from BPEL using Saxon.
+An invoked method is AttachPing.attachPing(String).
+
+More detailed information is here:
http://issues.apache.org/jira/browse/ODE-709
+
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/pom.xml
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/pom.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<project
xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/maven-v4_0_0.xsd">
+ <parent>
+ <groupId>org.apache.ode.ping-pong</groupId>
+ <artifactId>pom</artifactId>
+ <version>1.0.0</version>
+ </parent>
+
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.apache.ode.ping-pong</groupId>
+ <artifactId>common</artifactId>
+ <packaging>jar</packaging>
+</project>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/src/main/resources/Ping.wsdl
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/src/main/resources/Ping.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/src/main/resources/Ping.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,60 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions name="Ping"
+ targetNamespace="urn:/Ping.wsdl"
+ xmlns:tns="urn:/Ping.wsdl"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns="http://schemas.xmlsoap.org/wsdl/">
+
+ <types>
+ <schema
xmlns="http://www.w3.org/2001/XMLSchema">
+ <import namespace="urn:/Ping.wsdl"
schemaLocation="Ping.xsd"></import>
+ </schema>
+ </types>
+
+ <message name="PingRequest">
+ <part name="body" element="tns:PingRequest"/>
+ </message>
+
+ <message name="PingResponse">
+ <part name="body" element="tns:PingResponse"/>
+ </message>
+
+ <portType name="PingPortType">
+ <operation name="Ping">
+ <input message="tns:PingRequest"/>
+ <output message="tns:PingResponse"/>
+ </operation>
+ </portType>
+
+ <plnk:partnerLinkType name="PingPartnerLinkType">
+ <plnk:role name="Provider"
portType="tns:PingPortType"/>
+ </plnk:partnerLinkType>
+
+ <!--
+
+ This is an abstract interface/portType definition. Note the lack of
+ binding and service: these are defined by the HTTP binding component.
+ See ping-http/Ping.wsdl for details.
+
+ -->
+
+</definitions>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/src/main/resources/Ping.xsd
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/src/main/resources/Ping.xsd
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/src/main/resources/Ping.xsd 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<schema
xmlns="http://www.w3.org/2001/XMLSchema"
targetNamespace="urn:/Ping.wsdl" xmlns:tns="urn:/Ping.wsdl"
elementFormDefault="qualified">
+ <element name="PingRequest">
+ <complexType>
+ <all>
+ <element name="text" type="string"/>
+ </all>
+ </complexType>
+ </element>
+ <element name="PingResponse">
+ <complexType>
+ <all>
+ <element name="text" type="string"/>
+ </all>
+ </complexType>
+ </element>
+</schema>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/src/main/resources/Pong.wsdl
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/src/main/resources/Pong.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/src/main/resources/Pong.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,60 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions name="Pong"
+ targetNamespace="urn:/Pong.wsdl"
+ xmlns:tns="urn:/Pong.wsdl"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns="http://schemas.xmlsoap.org/wsdl/">
+
+ <types>
+ <schema
xmlns="http://www.w3.org/2001/XMLSchema">
+ <import namespace="urn:/Pong.wsdl"
schemaLocation="Pong.xsd"></import>
+ </schema>
+ </types>
+
+ <message name="PongRequest">
+ <part name="body" element="tns:PongRequest"/>
+ </message>
+
+ <message name="PongResponse">
+ <part name="body" element="tns:PongResponse"/>
+ </message>
+
+ <portType name="PongPortType">
+ <operation name="Pong">
+ <input message="tns:PongRequest"/>
+ <output message="tns:PongResponse"/>
+ </operation>
+ </portType>
+
+ <plnk:partnerLinkType name="PongPartnerLinkType">
+ <plnk:role name="Provider"
portType="tns:PongPortType"/>
+ </plnk:partnerLinkType>
+
+ <!--
+
+ This is an abstract interface/portType definition. Note the lack of
+ binding and service. Since Pong is only exposed on the JBI bus, the
+ JBI endpoint is defined in Pong.dd.
+
+ -->
+
+</definitions>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/src/main/resources/Pong.xsd
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/src/main/resources/Pong.xsd
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/src/main/resources/Pong.xsd 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<schema targetNamespace="urn:/Pong.wsdl"
xmlns="http://www.w3.org/2001/XMLSchema">
+ <element name="PongRequest">
+ <complexType>
+ <all>
+ <element name="text" type="string"/>
+ </all>
+ </complexType>
+ </element>
+ <element name="PongResponse">
+ <complexType>
+ <all>
+ <element name="text" type="string"/>
+ </all>
+ </complexType>
+ </element>
+</schema>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/src/main/resources/common.wsdl
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/src/main/resources/common.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/common/src/main/resources/common.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<wsdl:definitions
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:tns="http://www.example.org/common/"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema" name="common"
targetNamespace="http://www.example.org/common/">
+ <wsdl:import location="Ping.wsdl"
namespace="urn:/Ping.wsdl"/>
+ <wsdl:import location="Pong.wsdl"
namespace="urn:/Pong.wsdl"/>
+</wsdl:definitions>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/http-su/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/http-su/pom.xml
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/http-su/pom.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,43 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<project
xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/maven-v4_0_0.xsd">
+ <parent>
+ <groupId>org.apache.ode.ping-pong</groupId>
+ <artifactId>pom</artifactId>
+ <version>1.0.0</version>
+ </parent>
+
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.apache.ode.ping-pong</groupId>
+ <artifactId>ping-pong-http-su</artifactId>
+ <packaging>jbi-service-unit</packaging>
+
+ <dependencies>
+ <dependency>
+ <groupId>${project.groupId}</groupId>
+ <artifactId>common</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ </dependencies>
+
+ <properties>
+ <componentName>servicemix-http</componentName>
+ </properties>
+</project>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/http-su/src/main/resources/xbean.xml
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/http-su/src/main/resources/xbean.xml
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/http-su/src/main/resources/xbean.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<beans
xmlns:http="http://servicemix.apache.org/http/1.0"
+ xmlns:ping="urn:/Ping.wsdl"
+ xmlns:pong="urn:/Pong.wsdl"
+ >
+ <http:endpoint
+ service="ping:PingService"
+ endpoint="http"
+ targetService="ping:PingService"
+ targetEndpoint="PingPort"
+ defaultOperation="Ping"
+ role="consumer"
+ locationURI="http://localhost:8192/PingHttp/"
+
defaultMep="http://www.w3.org/2004/08/wsdl/in-out"
+ wsdlResource="classpath:Ping.wsdl"
+ soapVersion="1.1"
+ soap="true" />
+</beans>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/pom.xml
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/pom.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,44 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<project
xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/maven-v4_0_0.xsd">
+ <parent>
+ <groupId>org.apache.ode.ping-pong</groupId>
+ <artifactId>pom</artifactId>
+ <version>1.0.0</version>
+ </parent>
+
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.apache.ode.ping-pong</groupId>
+ <artifactId>ping-pong-ode-su-${processRevision}</artifactId>
+ <packaging>jbi-service-unit</packaging>
+
+ <dependencies>
+ <dependency>
+ <groupId>${project.groupId}</groupId>
+ <artifactId>common</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ </dependencies>
+
+ <properties>
+ <componentName>OdeBpelEngine</componentName>
+ </properties>
+
+</project>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/src/main/java/org/apache/ode/ping/AttachPing.java
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/src/main/java/org/apache/ode/ping/AttachPing.java
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/src/main/java/org/apache/ode/ping/AttachPing.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,28 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.ode.ping;
+
+public class AttachPing {
+
+ public static String attachPing(String ping) {
+ return "Java attached ping to: "+ping;
+ }
+
+}
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/src/main/resources/Ping.bpel
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/src/main/resources/Ping.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/src/main/resources/Ping.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,121 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<process
+ name="Ping"
+
xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
+ targetNamespace="urn:/Ping.bpel"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:tns="urn:/Ping.bpel"
+ xmlns:ping="urn:/Ping.wsdl"
+ xmlns:pong="urn:/Pong.wsdl"
+ xmlns:fun="java:org.apache.ode.ping.AttachPing"
+
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+
+ <import location="common.wsdl"
+
namespace="http://www.example.org/common/"
+
importType="http://schemas.xmlsoap.org/wsdl/" />
+
+ <partnerLinks>
+ <partnerLink name="PingPartnerLink"
+ partnerLinkType="ping:PingPartnerLinkType"
+ myRole="Provider" />
+ <partnerLink name="PongPartnerLink"
+ partnerLinkType="pong:PongPartnerLinkType"
+ partnerRole="Provider"
+ initializePartnerRole="yes" />
+ </partnerLinks>
+
+ <variables>
+ <variable messageType="ping:PingRequest"
name="pingRequest"/>
+ <variable messageType="ping:PingResponse"
name="pingResponse"/>
+ <variable messageType="pong:PongRequest"
name="pongRequest"/>
+ <variable messageType="pong:PongResponse"
name="pongResponse"/>
+ <variable type="xsd:string" name="text" />
+ </variables>
+
+ <sequence name="Main">
+ <receive name="pingReceive"
+ createInstance="yes"
+ operation="Ping"
+ partnerLink="PingPartnerLink"
+ portType="ping:PingPortType"
+ variable="pingRequest"/>
+
+ <assign name="assignPongRequest">
+ <!-- add "ping" text to the input text -->
+ <copy>
+
<from>fun:attachPing($pingRequest.body/ping:text/text())</from>
+ <to variable="text"/>
+ </copy>
+ <!-- initialize pongRequest -->
+ <copy>
+ <from>
+ <literal>
+ <pong:PongRequest>
+ <pong:text/>
+ </pong:PongRequest>
+ </literal>
+ </from>
+ <to>$pongRequest.body</to>
+ </copy>
+ <!-- copy new text into pongRequest -->
+ <copy>
+ <from>$text</from>
+ <to>$pongRequest.body/pong:text</to>
+ </copy>
+ </assign>
+
+ <invoke name="invokePong"
+ operation="Pong"
+ inputVariable="pongRequest"
+ outputVariable="pongResponse"
+ partnerLink="PongPartnerLink"
+ portType="pong:PongPortType"/>
+
+ <assign name="assignPingResponse">
+ <copy>
+ <from>$pongResponse.body/pong:text</from>
+ <to>$text</to>
+ </copy>
+ <!-- initialize pingResponse -->
+ <copy>
+ <from>
+ <literal>
+ <ping:PingResponse>
+ <ping:text/>
+ </ping:PingResponse>
+ </literal>
+ </from>
+ <to>$pingResponse.body</to>
+ </copy>
+ <!-- copy new text into pingResponse -->
+ <copy>
+ <from>$text</from>
+ <to>$pingResponse.body/ping:text</to>
+ </copy>
+ </assign>
+
+ <reply name="pingReply"
+ partnerLink="PingPartnerLink"
+ portType="ping:PingPortType"
+ operation="Ping"
+ variable="pingResponse"/>
+ </sequence>
+</process>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/src/main/resources/Pong.bpel
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/src/main/resources/Pong.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/src/main/resources/Pong.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,83 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<process
+ name="Pong"
+
xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
+ targetNamespace="urn:/Pong.bpel"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:tns="urn:/Pong.bpel"
+ xmlns:pong="urn:/Pong.wsdl"
+
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath1.0">
+
+ <import location="common.wsdl"
+
namespace="http://www.example.org/common/"
+
importType="http://schemas.xmlsoap.org/wsdl/" />
+
+ <partnerLinks>
+ <partnerLink name="PongPartnerLink"
+ partnerLinkType="pong:PongPartnerLinkType"
+ myRole="Provider" />
+ </partnerLinks>
+
+ <variables>
+ <variable messageType="pong:PongRequest"
name="pongRequest"/>
+ <variable messageType="pong:PongResponse"
name="pongResponse"/>
+ <variable type="xsd:string" name="text" />
+ </variables>
+
+ <sequence name="Main">
+ <receive name="pongReceive"
+ createInstance="yes"
+ operation="Pong"
+ partnerLink="PongPartnerLink"
+ portType="pong:PongPortType"
+ variable="pongRequest"/>
+
+ <assign name="assignPongRequest">
+ <!-- add "ping" text to the input text -->
+ <copy>
+ <from>concat($pongRequest.body/pong:text, '
pong')</from>
+ <to>$text</to>
+ </copy>
+ <!-- initialize pongResponse -->
+ <copy>
+ <from>
+ <literal>
+ <pong:PongRequest>
+ <pong:text/>
+ </pong:PongRequest>
+ </literal>
+ </from>
+ <to>$pongResponse.body</to>
+ </copy>
+ <!-- copy new text into pongResponse -->
+ <copy>
+ <from>$text</from>
+ <to>$pongResponse.body/pong:text</to>
+ </copy>
+ </assign>
+
+ <reply name="pongReply"
+ partnerLink="PongPartnerLink"
+ portType="pong:PongPortType"
+ operation="Pong"
+ variable="pongResponse"/>
+ </sequence>
+</process>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/src/main/resources/deploy.xml
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/src/main/resources/deploy.xml
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/ode-su/src/main/resources/deploy.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,42 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<deploy
xmlns="http://www.apache.org/ode/schemas/dd/2007/03"
+ xmlns:pingProcess="urn:/Ping.bpel"
+ xmlns:pongProcess="urn:/Pong.bpel"
+ xmlns:ping="urn:/Ping.wsdl"
+ xmlns:pong="urn:/Pong.wsdl">
+
+ <process name="pingProcess:Ping">
+ <active>true</active>
+ <provide partnerLink="PingPartnerLink">
+ <service name="ping:PingService" port="PingPort"/>
+ </provide>
+ <invoke partnerLink="PongPartnerLink">
+ <service name="pong:PongService" port="PongPort"/>
+ </invoke>
+ </process>
+ <process name="pongProcess:Pong">
+ <active>true</active>
+ <provide partnerLink="PongPartnerLink">
+ <service name="pong:PongService" port="PongPort"/>
+ </provide>
+ </process>
+
+</deploy>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/pom.xml
(rev 0)
+++ branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/pom.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,54 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<project
xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/maven-v4_0_0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.apache.ode.ping-pong</groupId>
+ <artifactId>pom</artifactId>
+ <packaging>pom</packaging>
+ <version>1.0.0</version>
+
+ <properties>
+ <jbi-maven-plugin-version>4.0</jbi-maven-plugin-version>
+ <processRevision>1</processRevision>
+ </properties>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.servicemix.tooling</groupId>
+ <artifactId>jbi-maven-plugin</artifactId>
+ <version>${jbi-maven-plugin-version}</version>
+ <extensions>true</extensions>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-eclipse-plugin</artifactId>
+ <version>2.7</version>
+ </plugin>
+ </plugins>
+ </build>
+
+ <modules>
+ <module>common</module>
+ <module>ode-su</module>
+ <module>http-su</module>
+ <module>sa</module>
+ </modules>
+</project>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/sa/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/sa/pom.xml
(rev 0)
+++ branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong/sa/pom.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,65 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<project
xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/maven-v4_0_0.xsd">
+ <parent>
+ <groupId>org.apache.ode.ping-pong</groupId>
+ <artifactId>pom</artifactId>
+ <version>1.0.0</version>
+ </parent>
+
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.apache.ode.ping-pong</groupId>
+ <artifactId>ping-pong-sa</artifactId>
+ <packaging>jbi-service-assembly</packaging>
+
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ode.ping-pong</groupId>
+ <artifactId>ping-pong-ode-su-${processRevision}</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode.ping-pong</groupId>
+ <artifactId>ping-pong-http-su</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.servicemix.tooling</groupId>
+ <artifactId>jbi-maven-plugin</artifactId>
+ <executions>
+ <execution>
+ <goals>
+ <goal>generate-jbi-service-assembly-descriptor</goal>
+ </goals>
+ <configuration>
+ <name>${project.artifactId}-${processRevision}</name>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+
+</project>
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/osgi.bnd
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/osgi.bnd
(rev 0)
+++ branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/osgi.bnd 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,4 @@
+Bundle-Activator: org.apache.ode.jbi.osgi.ServiceUnitActivator
+Export-Package: org.apache.ode.ping
+Import-Package:
org.apache.ode.jbi.osgi,org.apache.servicemix.http,org.apache.servicemix.common.osgi
+Include-Resource: src/main/resources
Added: branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/pom.xml
(rev 0)
+++ branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/pom.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/maven-v4_0_0.xsd"
xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
+
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.apache.ode.examples</groupId>
+ <artifactId>ping-pong-bundle</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ <packaging>bundle</packaging>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.felix</groupId>
+ <artifactId>maven-bundle-plugin</artifactId>
+ <version>1.4.3</version>
+ <extensions>true</extensions>
+ <configuration>
+ <instructions>
+
<Bundle-SymbolicName>${project.groupId}-${project.artifactId}</Bundle-SymbolicName>
+ <Bundle-Version>${project.version}</Bundle-Version>
+ <_include>-osgi.bnd</_include>
+ </instructions>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+</project>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/java/org/apache/ode/ping/AttachPing.java
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/java/org/apache/ode/ping/AttachPing.java
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/java/org/apache/ode/ping/AttachPing.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,28 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.ode.ping;
+
+public class AttachPing {
+
+ public static String attachPing(String ping) {
+ return "Java attached ping to: "+ping;
+ }
+
+}
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/META-INF/spring/xbean.xml
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/META-INF/spring/xbean.xml
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/META-INF/spring/xbean.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,44 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<beans
xmlns="http://www.springframework.org/schema/beans"
+
xmlns:http="http://servicemix.apache.org/http/1.0"
+ xmlns:ping="urn:/Ping.wsdl"
+ xmlns:pong="urn:/Pong.wsdl"
+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="
+
http://www.springframework.org/schema/beans
+
http://www.springframework.org/schema/beans/spring-beans.xsd
+
http://servicemix.apache.org/http/1.0
+
http://servicemix.apache.org/http/1.0/servicemix-http.xsd">
+ <http:endpoint
+ service="ping:PingService"
+ endpoint="http"
+ targetService="ping:PingService"
+ targetEndpoint="PingPort"
+ defaultOperation="Ping"
+ role="consumer"
+ locationURI="http://localhost:8192/PingHttp/"
+
defaultMep="http://www.w3.org/2004/08/wsdl/in-out"
+ wsdlResource="classpath:Ping.wsdl"
+ soapVersion="1.1"
+ soap="true" />
+
+ <bean class="org.apache.servicemix.common.osgi.EndpointExporter" />
+</beans>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/Ping.bpel
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/Ping.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/Ping.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,121 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<process
+ name="Ping"
+
xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
+ targetNamespace="urn:/Ping.bpel"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:tns="urn:/Ping.bpel"
+ xmlns:ping="urn:/Ping.wsdl"
+ xmlns:pong="urn:/Pong.wsdl"
+ xmlns:fun="java:org.apache.ode.ping.AttachPing"
+
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+
+ <import location="common.wsdl"
+
namespace="http://www.example.org/common/"
+
importType="http://schemas.xmlsoap.org/wsdl/" />
+
+ <partnerLinks>
+ <partnerLink name="PingPartnerLink"
+ partnerLinkType="ping:PingPartnerLinkType"
+ myRole="Provider" />
+ <partnerLink name="PongPartnerLink"
+ partnerLinkType="pong:PongPartnerLinkType"
+ partnerRole="Provider"
+ initializePartnerRole="yes" />
+ </partnerLinks>
+
+ <variables>
+ <variable messageType="ping:PingRequest"
name="pingRequest"/>
+ <variable messageType="ping:PingResponse"
name="pingResponse"/>
+ <variable messageType="pong:PongRequest"
name="pongRequest"/>
+ <variable messageType="pong:PongResponse"
name="pongResponse"/>
+ <variable type="xsd:string" name="text" />
+ </variables>
+
+ <sequence name="Main">
+ <receive name="pingReceive"
+ createInstance="yes"
+ operation="Ping"
+ partnerLink="PingPartnerLink"
+ portType="ping:PingPortType"
+ variable="pingRequest"/>
+
+ <assign name="assignPongRequest">
+ <!-- add "ping" text to the input text -->
+ <copy>
+
<from>fun:attachPing($pingRequest.body/ping:text/text())</from>
+ <to variable="text"/>
+ </copy>
+ <!-- initialize pongRequest -->
+ <copy>
+ <from>
+ <literal>
+ <pong:PongRequest>
+ <pong:text/>
+ </pong:PongRequest>
+ </literal>
+ </from>
+ <to>$pongRequest.body</to>
+ </copy>
+ <!-- copy new text into pongRequest -->
+ <copy>
+ <from>$text</from>
+ <to>$pongRequest.body/pong:text</to>
+ </copy>
+ </assign>
+
+ <invoke name="invokePong"
+ operation="Pong"
+ inputVariable="pongRequest"
+ outputVariable="pongResponse"
+ partnerLink="PongPartnerLink"
+ portType="pong:PongPortType"/>
+
+ <assign name="assignPingResponse">
+ <copy>
+ <from>$pongResponse.body/pong:text</from>
+ <to>$text</to>
+ </copy>
+ <!-- initialize pingResponse -->
+ <copy>
+ <from>
+ <literal>
+ <ping:PingResponse>
+ <ping:text/>
+ </ping:PingResponse>
+ </literal>
+ </from>
+ <to>$pingResponse.body</to>
+ </copy>
+ <!-- copy new text into pingResponse -->
+ <copy>
+ <from>$text</from>
+ <to>$pingResponse.body/ping:text</to>
+ </copy>
+ </assign>
+
+ <reply name="pingReply"
+ partnerLink="PingPartnerLink"
+ portType="ping:PingPortType"
+ operation="Ping"
+ variable="pingResponse"/>
+ </sequence>
+</process>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/Ping.wsdl
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/Ping.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/Ping.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,60 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions name="Ping"
+ targetNamespace="urn:/Ping.wsdl"
+ xmlns:tns="urn:/Ping.wsdl"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns="http://schemas.xmlsoap.org/wsdl/">
+
+ <types>
+ <schema
xmlns="http://www.w3.org/2001/XMLSchema">
+ <import namespace="urn:/Ping.wsdl"
schemaLocation="Ping.xsd"></import>
+ </schema>
+ </types>
+
+ <message name="PingRequest">
+ <part name="body" element="tns:PingRequest"/>
+ </message>
+
+ <message name="PingResponse">
+ <part name="body" element="tns:PingResponse"/>
+ </message>
+
+ <portType name="PingPortType">
+ <operation name="Ping">
+ <input message="tns:PingRequest"/>
+ <output message="tns:PingResponse"/>
+ </operation>
+ </portType>
+
+ <plnk:partnerLinkType name="PingPartnerLinkType">
+ <plnk:role name="Provider"
portType="tns:PingPortType"/>
+ </plnk:partnerLinkType>
+
+ <!--
+
+ This is an abstract interface/portType definition. Note the lack of
+ binding and service: these are defined by the HTTP binding component.
+ See ping-http/Ping.wsdl for details.
+
+ -->
+
+</definitions>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/Ping.xsd
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/Ping.xsd
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/Ping.xsd 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<schema
xmlns="http://www.w3.org/2001/XMLSchema"
targetNamespace="urn:/Ping.wsdl" xmlns:tns="urn:/Ping.wsdl"
elementFormDefault="qualified">
+ <element name="PingRequest">
+ <complexType>
+ <all>
+ <element name="text" type="string"/>
+ </all>
+ </complexType>
+ </element>
+ <element name="PingResponse">
+ <complexType>
+ <all>
+ <element name="text" type="string"/>
+ </all>
+ </complexType>
+ </element>
+</schema>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/Pong.bpel
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/Pong.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/Pong.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,83 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<process
+ name="Pong"
+
xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
+ targetNamespace="urn:/Pong.bpel"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:tns="urn:/Pong.bpel"
+ xmlns:pong="urn:/Pong.wsdl"
+
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath1.0">
+
+ <import location="common.wsdl"
+
namespace="http://www.example.org/common/"
+
importType="http://schemas.xmlsoap.org/wsdl/" />
+
+ <partnerLinks>
+ <partnerLink name="PongPartnerLink"
+ partnerLinkType="pong:PongPartnerLinkType"
+ myRole="Provider" />
+ </partnerLinks>
+
+ <variables>
+ <variable messageType="pong:PongRequest"
name="pongRequest"/>
+ <variable messageType="pong:PongResponse"
name="pongResponse"/>
+ <variable type="xsd:string" name="text" />
+ </variables>
+
+ <sequence name="Main">
+ <receive name="pongReceive"
+ createInstance="yes"
+ operation="Pong"
+ partnerLink="PongPartnerLink"
+ portType="pong:PongPortType"
+ variable="pongRequest"/>
+
+ <assign name="assignPongRequest">
+ <!-- add "ping" text to the input text -->
+ <copy>
+ <from>concat($pongRequest.body/pong:text, '
pong')</from>
+ <to>$text</to>
+ </copy>
+ <!-- initialize pongResponse -->
+ <copy>
+ <from>
+ <literal>
+ <pong:PongRequest>
+ <pong:text/>
+ </pong:PongRequest>
+ </literal>
+ </from>
+ <to>$pongResponse.body</to>
+ </copy>
+ <!-- copy new text into pongResponse -->
+ <copy>
+ <from>$text</from>
+ <to>$pongResponse.body/pong:text</to>
+ </copy>
+ </assign>
+
+ <reply name="pongReply"
+ partnerLink="PongPartnerLink"
+ portType="pong:PongPortType"
+ operation="Pong"
+ variable="pongResponse"/>
+ </sequence>
+</process>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/Pong.wsdl
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/Pong.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/Pong.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,60 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions name="Pong"
+ targetNamespace="urn:/Pong.wsdl"
+ xmlns:tns="urn:/Pong.wsdl"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns="http://schemas.xmlsoap.org/wsdl/">
+
+ <types>
+ <schema
xmlns="http://www.w3.org/2001/XMLSchema">
+ <import namespace="urn:/Pong.wsdl"
schemaLocation="Pong.xsd"></import>
+ </schema>
+ </types>
+
+ <message name="PongRequest">
+ <part name="body" element="tns:PongRequest"/>
+ </message>
+
+ <message name="PongResponse">
+ <part name="body" element="tns:PongResponse"/>
+ </message>
+
+ <portType name="PongPortType">
+ <operation name="Pong">
+ <input message="tns:PongRequest"/>
+ <output message="tns:PongResponse"/>
+ </operation>
+ </portType>
+
+ <plnk:partnerLinkType name="PongPartnerLinkType">
+ <plnk:role name="Provider"
portType="tns:PongPortType"/>
+ </plnk:partnerLinkType>
+
+ <!--
+
+ This is an abstract interface/portType definition. Note the lack of
+ binding and service. Since Pong is only exposed on the JBI bus, the
+ JBI endpoint is defined in Pong.dd.
+
+ -->
+
+</definitions>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/Pong.xsd
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/Pong.xsd
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/Pong.xsd 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<schema targetNamespace="urn:/Pong.wsdl"
xmlns="http://www.w3.org/2001/XMLSchema">
+ <element name="PongRequest">
+ <complexType>
+ <all>
+ <element name="text" type="string"/>
+ </all>
+ </complexType>
+ </element>
+ <element name="PongResponse">
+ <complexType>
+ <all>
+ <element name="text" type="string"/>
+ </all>
+ </complexType>
+ </element>
+</schema>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/common.wsdl
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/common.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/common.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<wsdl:definitions
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:tns="http://www.example.org/common/"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema" name="common"
targetNamespace="http://www.example.org/common/">
+ <wsdl:import location="Ping.wsdl"
namespace="urn:/Ping.wsdl"/>
+ <wsdl:import location="Pong.wsdl"
namespace="urn:/Pong.wsdl"/>
+</wsdl:definitions>
Added:
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/deploy.xml
===================================================================
---
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/deploy.xml
(rev 0)
+++
branches/ODE/ODE-1.x/distro/src/examples-jbi/maven2/ping-pong-osgi/src/main/resources/deploy.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,42 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<deploy
xmlns="http://www.apache.org/ode/schemas/dd/2007/03"
+ xmlns:pingProcess="urn:/Ping.bpel"
+ xmlns:pongProcess="urn:/Pong.bpel"
+ xmlns:ping="urn:/Ping.wsdl"
+ xmlns:pong="urn:/Pong.wsdl">
+
+ <process name="pingProcess:Ping">
+ <active>true</active>
+ <provide partnerLink="PingPartnerLink">
+ <service name="ping:PingService" port="PingPort"/>
+ </provide>
+ <invoke partnerLink="PongPartnerLink">
+ <service name="pong:PongService" port="PongPort"/>
+ </invoke>
+ </process>
+ <process name="pongProcess:Pong">
+ <active>true</active>
+ <provide partnerLink="PongPartnerLink">
+ <service name="pong:PongService" port="PongPort"/>
+ </provide>
+ </process>
+
+</deploy>
Added: branches/ODE/ODE-1.x/distro/src/main/assembly/jbi.xml
===================================================================
--- branches/ODE/ODE-1.x/distro/src/main/assembly/jbi.xml (rev 0)
+++ branches/ODE/ODE-1.x/distro/src/main/assembly/jbi.xml 2010-04-14 18:25:55 UTC (rev
620)
@@ -0,0 +1,170 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<assembly>
+ <!-- id typically identifies the "type" (src vs bin etc) of the assembly
-->
+ <id></id>
+ <includeBaseDirectory>true</includeBaseDirectory>
+ <formats>
+ <format>zip</format>
+ </formats>
+
+ <fileSets>
+
+ <fileSet>
+ <directory>src/examples-jbi</directory>
+ <outputDirectory>/examples</outputDirectory>
+ <excludes>
+ <exclude>**/target/**</exclude>
+ </excludes>
+ </fileSet>
+
+ <fileSet>
+ <directory>src/bin</directory>
+ <outputDirectory>/bin</outputDirectory>
+ <fileMode>755</fileMode>
+ </fileSet>
+
+ <fileSet>
+ <directory>${basedir}/../dao-jpa-ojpa-derby/target/</directory>
+ <outputDirectory>/sql</outputDirectory>
+ <includes>
+ <include>*.sql</include>
+ </includes>
+ <excludes>
+ <exclude>*partial*.sql</exclude>
+ </excludes>
+ </fileSet>
+
+ <fileSet>
+ <directory>${basedir}/../</directory>
+ <outputDirectory>/</outputDirectory>
+ <includes>
+ <include>LICENSE</include>
+ <include>README</include>
+ <include>NOTICE</include>
+ <include>RELEASE_NOTES</include>
+ </includes>
+ </fileSet>
+
+ <fileSet>
+ <directory>${basedir}/license</directory>
+ <outputDirectory>/lib</outputDirectory>
+ <includes>
+ <include>*LICENSE</include>
+ </includes>
+ </fileSet>
+
+ <fileSet>
+ <directory>${basedir}/../extensions/e4x</directory>
+ <outputDirectory>/extensions/ode-extensions-e4x</outputDirectory>
+ <includes>
+ <include>README</include>
+ </includes>
+ </fileSet>
+
+ <fileSet>
+ <directory>${basedir}/../extensions/e4x/target</directory>
+ <outputDirectory>/extensions/ode-extensions-e4x</outputDirectory>
+ <includes>
+ <include>ode-extensions-e4x*.jar</include>
+ </includes>
+ </fileSet>
+
+ <fileSet>
+ <directory>${basedir}/../extensions/jms-eventpublisher</directory>
+
<outputDirectory>/extensions/ode-extensions-jms-eventpublisher</outputDirectory>
+ <includes>
+ <include>README</include>
+ </includes>
+ </fileSet>
+
+ <fileSet>
+
<directory>${basedir}/../extensions/jms-eventpublisher/target</directory>
+
<outputDirectory>/extensions/ode-extensions-jms-eventpublisher</outputDirectory>
+ <includes>
+ <include>ode-extensions-jms*.jar</include>
+ </includes>
+ </fileSet>
+
+ <fileSet>
+ <directory>${basedir}/../extensions</directory>
+ <outputDirectory>/extensions</outputDirectory>
+ <includes>
+ <include>README.extensions</include>
+ </includes>
+ </fileSet>
+
+ </fileSets>
+
+ <files>
+ <file>
+
<source>${basedir}/../jbi/target/ode-jbi-${project.version}.zip</source>
+ <outputDirectory>/</outputDirectory>
+ </file>
+ </files>
+
+
+ <dependencySets>
+
+ <dependencySet>
+ <outputDirectory>/lib</outputDirectory>
+ <includes>
+ <include>org.apache.ode:ode-utils</include>
+ <include>org.apache.ode:ode-tools</include>
+ <include>org.apache.ode:ode-bpel-compiler</include>
+ <include>org.apache.ode:ode-bpel-api</include>
+ <include>org.apache.ode:ode-bpel-schemas</include>
+ <include>commons-logging:commons-logging</include>
+ <include>org.apache.ode:ode-utils</include>
+ <include>commons-codec:commons-codec</include>
+ <include>commons-collections:commons-collections</include>
+ <include>commons-httpclient:commons-httpclient</include>
+ <include>commons-pool:commons-pool</include>
+ <include>net.sf.saxon:saxon</include>
+ <include>net.sf.saxon:saxon-xpath</include>
+ <include>net.sf.saxon:saxon-dom</include>
+ <include>net.sf.saxon:saxon-xqj</include>
+ <include>jaxen:jaxen</include>
+ <include>log4j:log4j</include>
+ <include>wsdl4j:wsdl4j</include>
+ <include>xalan:xalan</include>
+ <include>xerces:xercesImpl</include>
+ </includes>
+ </dependencySet>
+
+ <dependencySet>
+ <outputDirectory>/extensions/ode-extensions-e4x/lib</outputDirectory>
+ <includes>
+ <include>rhino:js</include>
+ <include>commons-logging:commons-logging</include>
+ </includes>
+ </dependencySet>
+
+ <dependencySet>
+
<outputDirectory>/extensions/ode-extensions-jms-eventpublisher/lib</outputDirectory>
+ <includes>
+ <include>org.apache.activemq:apache-activemq</include>
+ <include>org.apache.xmlbeans:xmlbeans</include>
+ </includes>
+ </dependencySet>
+
+ </dependencySets>
+
+</assembly>
Added: branches/ODE/ODE-1.x/distro/src/main/assembly/war.xml
===================================================================
--- branches/ODE/ODE-1.x/distro/src/main/assembly/war.xml (rev 0)
+++ branches/ODE/ODE-1.x/distro/src/main/assembly/war.xml 2010-04-14 18:25:55 UTC (rev
620)
@@ -0,0 +1,168 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<assembly>
+ <!-- id typically identifies the "type" (src vs bin etc) of the assembly
-->
+ <id></id>
+ <includeBaseDirectory>true</includeBaseDirectory>
+ <formats>
+ <format>zip</format>
+ </formats>
+
+ <fileSets>
+
+ <fileSet>
+ <directory>src/examples-war</directory>
+ <outputDirectory>/examples</outputDirectory>
+ </fileSet>
+
+ <fileSet>
+ <directory>src/bin</directory>
+ <outputDirectory>/bin</outputDirectory>
+ <fileMode>755</fileMode>
+ </fileSet>
+
+ <fileSet>
+ <directory>${basedir}/../dao-jpa-ojpa-derby/target/</directory>
+ <outputDirectory>/sql</outputDirectory>
+ <includes>
+ <include>*.sql</include>
+ </includes>
+ <excludes>
+ <exclude>*partial*.sql</exclude>
+ </excludes>
+ </fileSet>
+
+ <fileSet>
+ <directory>${basedir}/../</directory>
+ <outputDirectory>/</outputDirectory>
+ <includes>
+ <include>LICENSE</include>
+ <include>README</include>
+ <include>NOTICE</include>
+ <include>RELEASE_NOTES</include>
+ </includes>
+ </fileSet>
+
+ <fileSet>
+ <directory>${basedir}/license</directory>
+ <outputDirectory>/lib</outputDirectory>
+ <includes>
+ <include>*LICENSE</include>
+ </includes>
+ </fileSet>
+
+ <fileSet>
+ <directory>${basedir}/../extensions/e4x</directory>
+ <outputDirectory>/extensions/ode-extensions-e4x</outputDirectory>
+ <includes>
+ <include>README</include>
+ </includes>
+ </fileSet>
+
+ <fileSet>
+ <directory>${basedir}/../extensions/e4x/target</directory>
+ <outputDirectory>/extensions/ode-extensions-e4x</outputDirectory>
+ <includes>
+ <include>ode-extensions-e4x*.jar</include>
+ </includes>
+ </fileSet>
+
+ <fileSet>
+ <directory>${basedir}/../extensions/jms-eventpublisher</directory>
+
<outputDirectory>/extensions/ode-extensions-jms-eventpublisher</outputDirectory>
+ <includes>
+ <include>README</include>
+ </includes>
+ </fileSet>
+
+ <fileSet>
+
<directory>${basedir}/../extensions/jms-eventpublisher/target</directory>
+
<outputDirectory>/extensions/ode-extensions-jms-eventpublisher</outputDirectory>
+ <includes>
+ <include>ode-extensions-jms*.jar</include>
+ </includes>
+ </fileSet>
+
+ <fileSet>
+ <directory>${basedir}/../extensions</directory>
+ <outputDirectory>/extensions</outputDirectory>
+ <includes>
+ <include>README.extensions</include>
+ </includes>
+ </fileSet>
+
+ </fileSets>
+
+ <files>
+ <file>
+
<source>${basedir}/../axis2-war/target/ode-axis2-war-${project.version}.war</source>
+ <outputDirectory>/</outputDirectory>
+ <destName>ode.war</destName>
+ </file>
+ </files>
+
+
+ <dependencySets>
+
+ <dependencySet>
+ <outputDirectory>/lib</outputDirectory>
+ <includes>
+ <include>org.apache.ode:ode-utils</include>
+ <include>org.apache.ode:ode-tools</include>
+ <include>org.apache.ode:ode-bpel-compiler</include>
+ <include>org.apache.ode:ode-bpel-api</include>
+ <include>org.apache.ode:ode-bpel-schemas</include>
+ <include>commons-logging:commons-logging</include>
+ <include>org.apache.ode:ode-utils</include>
+ <include>commons-codec:commons-codec</include>
+ <include>commons-collections:commons-collections</include>
+ <include>commons-httpclient:commons-httpclient</include>
+ <include>commons-pool:commons-pool</include>
+ <include>net.sf.saxon:saxon</include>
+ <include>net.sf.saxon:saxon-xpath</include>
+ <include>net.sf.saxon:saxon-dom</include>
+ <include>net.sf.saxon:saxon-xqj</include>
+ <include>jaxen:jaxen</include>
+ <include>log4j:log4j</include>
+ <include>wsdl4j:wsdl4j</include>
+ <include>xalan:xalan</include>
+ <include>xerces:xercesImpl</include>
+ </includes>
+ </dependencySet>
+
+ <dependencySet>
+ <outputDirectory>/extensions/ode-extensions-e4x/lib</outputDirectory>
+ <includes>
+ <include>rhino:js</include>
+ <include>commons-logging:commons-logging</include>
+ </includes>
+ </dependencySet>
+
+ <dependencySet>
+
<outputDirectory>/extensions/ode-extensions-jms-eventpublisher/lib</outputDirectory>
+ <includes>
+ <include>org.apache.activemq:apache-activemq</include>
+ <include>org.apache.xmlbeans:xmlbeans</include>
+ </includes>
+ </dependencySet>
+
+ </dependencySets>
+
+</assembly>
Added: branches/ODE/ODE-1.x/jacob/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/jacob/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/jacob/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,81 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jacob</artifactId>
+ <packaging>jar</packaging>
+ <name>ODE :: Java Concurrent Objects (JACOB)</name>
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-utils</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jacob-ap</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-logging</groupId>
+ <artifactId>commons-logging</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>apt-maven-plugin</artifactId>
+ <version>1.0-alpha-3</version>
+ <configuration>
+
<factory>org.apache.ode.jacob.ap.JacobAnnotationProcessorFactory</factory>
+ <outputDirectory>target/generated/apt</outputDirectory>
+ </configuration>
+ <executions>
+ <execution>
+ <goals>
+ <goal>process</goal>
+ <goal>test-process</goal>
+ </goals>
+ </execution>
+ </executions>
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jacob-ap</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ </dependencies>
+ </plugin>
+ </plugins>
+ </build>
+</project>
Added: branches/ODE/ODE-1.x/jacob-ap/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/jacob-ap/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/jacob-ap/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,45 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jacob-ap</artifactId>
+ <packaging>jar</packaging>
+ <name>ODE :: Java Concurrent Objects (JACOB) - APT</name>
+
+ <modelVersion>4.0.0</modelVersion>
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <dependencies>
+ <dependency>
+ <groupId>sun.jdk</groupId>
+ <artifactId>tools</artifactId>
+ <version>1.5.0</version>
+ <scope>system</scope>
+ <systemPath>${java.home}/../lib/tools.jar</systemPath>
+ </dependency>
+ </dependencies>
+
+
+</project>
Added: branches/ODE/ODE-1.x/jbi/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/jbi/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,513 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project
xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/maven-v4_0_0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jbi</artifactId>
+ <name>ODE :: JBI Distribution</name>
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <properties>
+ <jbi.version>1.1.0</jbi.version>
+ <spring.version>2.5.6</spring.version>
+ <servicemix.core.version>3.3</servicemix.core.version>
+ <servicemix.component.version>2008.01</servicemix.component.version>
+ <servicemix.utils.version>1.0.0</servicemix.utils.version>
+ <tranql.version>1.1</tranql.version>
+ <geronimo.specs.jms.version>1.1-rc4</geronimo.specs.jms.version>
+ </properties>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-compiler</artifactId>
+ <exclusions>
+ <exclusion>
+ <groupId>xml-apis</groupId>
+ <artifactId>xml-apis</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>dom4j</groupId>
+ <artifactId>dom4j</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>jdom</groupId>
+ <artifactId>jdom</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>stax</groupId>
+ <artifactId>stax-api</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>xom</groupId>
+ <artifactId>xom</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-connector</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-dao</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-epr</artifactId>
+ <exclusions>
+ <exclusion>
+ <groupId>org.apache.geronimo.components</groupId>
+ <artifactId>geronimo-connector</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.apache.geronimo.components</groupId>
+ <artifactId>geronimo-transaction</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.jencks</groupId>
+ <artifactId>jencks</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.components</groupId>
+ <artifactId>geronimo-connector</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.components</groupId>
+ <artifactId>geronimo-transaction</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-agents</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-obj</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-runtime</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-scheduler-simple</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-store</artifactId>
+ <exclusions>
+ <exclusion>
+ <groupId>org.hibernate</groupId>
+ <artifactId>hibernate-core</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>hsqldb</groupId>
+ <artifactId>hsqldb</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-jms_1.1_spec</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-jpa_1.0_spec</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-schemas</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-utils</artifactId>
+ <exclusions>
+ <exclusion>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-adb</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-codegen</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-kernel</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-java2wsdl</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-jibx</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-saaj</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-xmlbeans</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-javamail_1.4_spec</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.codehaus.woodstox</groupId>
+ <artifactId>wstx-asl</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>xml-apis</groupId>
+ <artifactId>xml-apis</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-activation_1.1_spec</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>xpp3</groupId>
+ <artifactId>xpp3_min</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-ql</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jacob-ap</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.servicemix.specs</groupId>
+ <artifactId>org.apache.servicemix.specs.jbi-api-1.0</artifactId>
+ <version>${jbi.version}</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-dao-jpa</artifactId>
+ <exclusions>
+ <exclusion>
+ <groupId>xerces</groupId>
+ <artifactId>xmlParserAPIs</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.derby</groupId>
+ <artifactId>derby</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-dao-hibernate</artifactId>
+ <exclusions>
+ <exclusion>
+ <groupId>org.hibernate</groupId>
+ <artifactId>hibernate</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-api-jca</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jca-ra</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jca-server</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jacob</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>xerces</groupId>
+ <artifactId>xercesImpl</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>commons-io</groupId>
+ <artifactId>commons-io</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.springframework</groupId>
+ <artifactId>spring</artifactId>
+ <version>${spring.version}</version>
+ <scope>test</scope>
+ </dependency>
+
+ <dependency>
+ <groupId>org.apache.servicemix</groupId>
+ <artifactId>servicemix-core</artifactId>
+ <version>${servicemix.core.version}</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.servicemix</groupId>
+ <artifactId>servicemix-soap</artifactId>
+ <version>${servicemix.component.version}</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.servicemix</groupId>
+ <artifactId>servicemix-common</artifactId>
+ <version>${servicemix.component.version}</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.servicemix</groupId>
+ <artifactId>servicemix-shared</artifactId>
+ <version>${servicemix.component.version}</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.servicemix</groupId>
+ <artifactId>servicemix-http</artifactId>
+ <version>${servicemix.component.version}</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.servicemix</groupId>
+ <artifactId>servicemix-eip</artifactId>
+ <version>${servicemix.component.version}</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.servicemix</groupId>
+ <artifactId>servicemix-utils</artifactId>
+ <version>${servicemix.utils.version}</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-javamail_1.4_spec</artifactId>
+ <scope>test</scope>
+ </dependency>
+
+ <!-- for JBI packaging -->
+ <dependency>
+ <groupId>ant</groupId>
+ <artifactId>ant</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>tranql</groupId>
+ <artifactId>tranql-connector</artifactId>
+ <version>${tranql.version}</version>
+ <exclusions>
+ <exclusion>
+ <groupId>geronimo-spec</groupId>
+ <artifactId>geronimo-spec-j2ee-connector</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>geronimo-spec</groupId>
+ <artifactId>geronimo-spec-jta</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>regexp</groupId>
+ <artifactId>regexp</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>net.java.dev.javacc</groupId>
+ <artifactId>javacc</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ <dependency>
+ <groupId>tranql</groupId>
+ <artifactId>tranql-connector-derby-common</artifactId>
+ <version>${tranql.version}</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>geronimo-spec</groupId>
+ <artifactId>geronimo-spec-jms</artifactId>
+ <version>${geronimo.specs.jms.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>commons-primitives</groupId>
+ <artifactId>commons-primitives</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>backport-util-concurrent</groupId>
+ <artifactId>backport-util-concurrent</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-dbcp</groupId>
+ <artifactId>commons-dbcp</artifactId>
+ <exclusions>
+ <exclusion>
+ <groupId>xml-apis</groupId>
+ <artifactId>xml-apis</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-ejb_2.1_spec</artifactId>
+ </dependency>
+
+ <!-- This is a way to specify the global exclusion in the dependency tree
-->
+ <dependency>
+ <groupId>commons-httpclient</groupId>
+ <artifactId>commons-httpclient</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>commons-logging</groupId>
+ <artifactId>commons-logging</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ </dependencies>
+
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.servicemix.tooling</groupId>
+ <artifactId>jbi-maven-plugin</artifactId>
+ <version>3.2.3</version>
+ <extensions>true</extensions>
+ <executions>
+ <execution>
+ <id>jbi-generation</id>
+ <phase>process-resources</phase>
+ <goals>
+ <goal>generate-jbi-component-descriptor</goal>
+ </goals>
+ <configuration>
+ <component>org.apache.ode.jbi.OdeComponent</component>
+ <bootstrap>org.apache.ode.jbi.OdeBootstrap</bootstrap>
+
<bootstrapClassLoaderDelegation>parent-first</bootstrapClassLoaderDelegation>
+
<componentClassLoaderDelegation>parent-first</componentClassLoaderDelegation>
+ <type>service-engine</type>
+ <name>OdeBpelEngine</name>
+ <description>ODE JBI Integration Layer</description>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+
+ <plugin>
+ <artifactId>maven-surefire-plugin</artifactId>
+ <configuration>
+ <!-- FIXME: temporary skip it -->
+ <!--
+ <skipTests>true</skipTests>
+ -->
+ <systemProperties>
+ <property>
+ <name>java.naming.factory.initial</name>
+ <value>org.apache.xbean.spring.jndi.SpringInitialContextFactory</value>
+ </property>
+ </systemProperties>
+ </configuration>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-assembly-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>jbi-package</id>
+ <phase>package</phase>
+ <goals>
+ <goal>single</goal>
+ </goals>
+ <configuration>
+ <finalName>ode-jbi-${project.version}</finalName>
+ <appendAssemblyId>false</appendAssemblyId>
+ <descriptors>
+ <descriptor>src/main/assembly/bin.xml</descriptor>
+ </descriptors>
+ <tarLongFileMode>gnu</tarLongFileMode>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+
+ <plugin>
+ <artifactId>maven-resources-plugin</artifactId>
+ <version>2.4.2</version>
+ <executions>
+ <execution>
+ <id>copy-resources</id>
+ <phase>process-test-resources</phase>
+ <goals>
+ <goal>copy-resources</goal>
+ </goals>
+ <configuration>
+
<outputDirectory>${project.build.directory}/test/smx/ode</outputDirectory>
+ <resources>
+ <resource>
+
<directory>${basedir}/../dao-jpa-ojpa-derby/target/derby</directory>
+ </resource>
+ <resource>
+
<directory>${basedir}/../dao-hibernate-db/target/derby</directory>
+ </resource>
+ </resources>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+
+ <testResources>
+ <testResource>
+ <directory>src/test/resources</directory>
+ <targetPath>${project.build.directory}/test/resources</targetPath>
+ </testResource>
+ <testResource>
+ <directory>src/test/resources</directory>
+ <targetPath>${project.build.testOutputDirectory}</targetPath>
+ </testResource>
+ <testResource>
+ <directory>src/test/jbi</directory>
+ <targetPath>${project.build.directory}/test/smx/ode</targetPath>
+ </testResource>
+ <testResource>
+ <directory>src/main/jbi</directory>
+
<includes><include>hibernate.properties</include></includes>
+ <targetPath>${project.build.directory}/test/smx/ode</targetPath>
+ </testResource>
+ </testResources>
+ </build>
+
+</project>
Added: branches/ODE/ODE-1.x/jbi/src/main/assembly/bin.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/main/assembly/bin.xml (rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/main/assembly/bin.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,124 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<assembly>
+ <!-- id typically identifies the "type" (src vs bin etc) of the assembly
-->
+ <id></id>
+ <includeBaseDirectory>false</includeBaseDirectory>
+ <formats>
+ <format>zip</format>
+ </formats>
+
+ <fileSets>
+
+ <fileSet>
+ <directory>src/main/jbi</directory>
+ <outputDirectory>/</outputDirectory>
+ <includes>
+ <include>ode-jbi.properties</include>
+ </includes>
+ </fileSet>
+
+ <fileSet>
+ <directory>target</directory>
+ <outputDirectory>/META-INF</outputDirectory>
+ <includes>
+ <include>jbi.xml</include>
+ </includes>
+ </fileSet>
+
+ <fileSet>
+ <directory>${basedir}/../dao-jpa-ojpa-derby/target/derby</directory>
+ <outputDirectory>/</outputDirectory>
+ </fileSet>
+
+ <fileSet>
+ <directory>${basedir}/../dao-hibernate-db/target/derby</directory>
+ <outputDirectory>/</outputDirectory>
+ </fileSet>
+
+ </fileSets>
+
+ <dependencySets>
+
+ <dependencySet>
+ <outputDirectory>/lib</outputDirectory>
+ <includes>
+ <include>ant:ant</include>
+ <include>org.apache.ode:ode-jbi</include>
+ <include>org.apache.ode:ode-bpel-api</include>
+ <include>org.apache.ode:ode-bpel-api-jca</include>
+ <include>org.apache.ode:ode-bpel-compiler</include>
+ <include>org.apache.ode:ode-bpel-connector</include>
+ <include>org.apache.ode:ode-bpel-dao</include>
+ <include>org.apache.ode:ode-bpel-epr</include>
+ <include>org.apache.ode:ode-jca-ra</include>
+ <include>org.apache.ode:ode-jca-server</include>
+ <include>org.apache.ode:ode-bpel-runtime</include>
+ <include>org.apache.ode:ode-bpel-ql</include>
+ <include>org.apache.ode:ode-scheduler-simple</include>
+ <include>org.apache.ode:ode-bpel-schemas</include>
+ <include>org.apache.ode:ode-bpel-store</include>
+ <include>org.apache.ode:ode-dao-hibernate</include>
+ <include>org.apache.ode:ode-dao-jpa</include>
+ <include>org.apache.ode:ode-jacob</include>
+ <include>org.apache.ode:ode-jacob-ap</include>
+ <include>org.apache.ode:ode-utils</include>
+ <include>org.apache.ode:ode-agents</include>
+ <include>org.apache.ode:ode-bpel-obj</include>
+ <include>org.apache.ws.commons.axiom:axiom-api</include>
+ <include>org.apache.ws.commons.axiom:axiom-impl</include>
+ <include>org.apache.ws.commons.axiom:axiom-dom</include>
+ <include>backport-util-concurrent:backport-util-concurrent</include>
+ <include>commons-codec:commons-codec</include>
+ <include>commons-collections:commons-collections</include>
+ <include>commons-dbcp:commons-dbcp</include>
+ <include>commons-lang:commons-lang</include>
+ <include>commons-pool:commons-pool</include>
+ <include>commons-primitives:commons-primitives</include>
+ <include>org.apache.derby:derby</include>
+ <include>org.apache.geronimo.specs:geronimo-ejb_2.1_spec</include>
+ <include>org.apache.geronimo.specs:geronimo-j2ee-connector_1.5_spec</include>
+ <include>org.apache.geronimo.specs:geronimo-jta_1.1_spec</include>
+ <include>org.apache.geronimo.components:geronimo-connector</include>
+ <include>org.apache.geronimo.components:geronimo-transaction</include>
+ <include>geronimo-spec:geronimo-spec-jms</include>
+ <include>org.apache.geronimo.specs:geronimo-stax-api_1.0_spec</include>
+ <include>jaxen:jaxen</include>
+ <include>log4j:log4j</include>
+ <include>org.apache.openjpa:openjpa</include>
+ <include>javax.persistence:persistence-api</include>
+ <include>net.sourceforge.serp:serp</include>
+ <include>net.sf.saxon:saxon</include>
+ <include>net.sf.saxon:saxon-xpath</include>
+ <include>net.sf.saxon:saxon-dom</include>
+ <include>net.sf.saxon:saxon-xqj</include>
+ <include>wsdl4j:wsdl4j</include>
+ <include>tranql:tranql-connector</include>
+ <include>xalan:xalan</include>
+ <include>org.apache.xmlbeans:xmlbeans</include>
+ <include>com.thoughtworks.xstream:xstream</include>
+ <include>axion:axion</include>
+ <include>xerces:xercesImpl</include>
+ </includes>
+ </dependencySet>
+
+ </dependencySets>
+
+</assembly>
Modified:
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/EndpointReferenceContextImpl.java
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/EndpointReferenceContextImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/EndpointReferenceContextImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -34,6 +34,7 @@
import org.w3c.dom.NodeList;
import java.util.Map;
+import java.util.HashMap;
/**
* Implementation of the ODE {@link org.apache.ode.bpel.iapi.EndpointReferenceContext}
@@ -72,7 +73,8 @@
DocumentFragment fragment = doc.createDocumentFragment();
NodeList children = epr.getChildNodes();
for (int i = 0 ; i < children.getLength(); ++i)
- fragment.appendChild(doc.importNode(children.item(i), true));
+ if (children.item(i) instanceof Element)
+ fragment.appendChild(doc.importNode(children.item(i), true));
ServiceEndpoint se = _ode.getContext().resolveEndpointReference(fragment);
if (se == null)
return null;
@@ -113,6 +115,8 @@
}
public Map getConfigLookup(EndpointReference epr) {
- return ((MutableEndpoint)epr).toMap();
+ Map m = new HashMap();
+ m.put("service",
((JbiEndpointReference)epr).getServiceEndpoint().getServiceName());
+ return m;
}
}
Modified:
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/JbiEndpointReference.java
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/JbiEndpointReference.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/JbiEndpointReference.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -61,12 +61,15 @@
}
public Document toXML() {
- DocumentFragment fragment = getServiceEndpoint().getAsReference(_type);
- if (fragment == null)
- return null;
Document doc = DOMUtils.newDocument();
Element root =
doc.createElementNS(SERVICE_REF_QNAME.getNamespaceURI(),SERVICE_REF_QNAME.getLocalPart());
- root.appendChild(doc.importNode(fragment,true));
+ try {
+ DocumentFragment fragment = getServiceEndpoint().getAsReference(_type);
+ if (fragment != null) {
+ root.appendChild(doc.importNode(fragment,true));
+ }
+ } catch (Throwable t) {
+ }
doc.appendChild(root);
return doc;
}
Modified: branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeComponent.java
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeComponent.java 2010-04-14
15:43:12 UTC (rev 619)
+++ branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeComponent.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -34,9 +34,13 @@
private OdeLifeCycle _lifeCycle;
public OdeComponent() {
- _lifeCycle = new OdeLifeCycle();
+ this(new OdeLifeCycle());
}
+ public OdeComponent(OdeLifeCycle lifeCycle) {
+ _lifeCycle = lifeCycle;
+ }
+
public ComponentLifeCycle getLifeCycle() {
return _lifeCycle;
}
@@ -117,4 +121,5 @@
// We are an engine, so we don't have to worry about this.
return null;
}
+
}
Modified:
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeConfigProperties.java
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeConfigProperties.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeConfigProperties.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -20,6 +20,7 @@
package org.apache.ode.jbi;
import java.io.File;
+import java.util.Properties;
import org.apache.ode.jbi.msgmap.JbiWsdl11WrapperMapper;
@@ -34,13 +35,13 @@
private static final String PROP_MSGMAPPER = "messageMapper";
-
- private String _installDir;
-
public OdeConfigProperties(File cfgFile) {
super(cfgFile, "ode-jbi.");
}
+ public OdeConfigProperties(Properties properties) {
+ super(properties, "ode-jbi.");
+ }
/**
Modified: branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeConsumer.java
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeConsumer.java 2010-04-14
15:43:12 UTC (rev 619)
+++ branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeConsumer.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -85,6 +85,7 @@
jbiMex.setEndpoint(se);
jbiMex.setService(se.getServiceName());
jbiMex.setOperation(opname);
+
} catch (MessagingException e) {
String errmsg = "Unable to create JBI message exchange for ODE message
exchange " + odeMex;
__log.error(errmsg, e);
@@ -100,6 +101,7 @@
NormalizedMessage nmsg = inonly.createMessage();
mapper.toNMS(nmsg, odeMex.getRequest(),
odeMex.getOperation().getInput().getMessage(), null);
inonly.setInMessage(nmsg);
+ copyMexProperties(jbiMex, odeMex);
_ode._scheduler.registerSynchronizer(new Scheduler.Synchronizer() {
public void afterCompletion(boolean success) {
if (success) {
@@ -116,6 +118,7 @@
NormalizedMessage nmsg = inout.createMessage();
mapper.toNMS(nmsg, odeMex.getRequest(),
odeMex.getOperation().getInput().getMessage(), null);
inout.setInMessage(nmsg);
+ copyMexProperties(jbiMex, odeMex);
_ode._scheduler.registerSynchronizer(new Scheduler.Synchronizer() {
public void afterCompletion(boolean success) {
if (success) {
@@ -205,7 +208,7 @@
// need to reload mex since we're in a different transaction
PartnerRoleMessageExchange pmex = (PartnerRoleMessageExchange)
_ode._server.getEngine().getMessageExchange(outstanding.getMessageExchangeId());
if (pmex == null) {
- __log.warn("Received a response for unknown partner role
message exchange " + pmex.getMessageExchangeId());
+ __log.warn("Received a response for unknown partner role
message exchange " + outstanding.getMessageExchangeId());
return Boolean.FALSE;
}
String mapperName = pmex.getProperty(Mapper.class.getName());
Modified: branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeContext.java
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeContext.java 2010-04-14
15:43:12 UTC (rev 619)
+++ branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeContext.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -174,12 +174,15 @@
return (TransactionManager) getContext().getTransactionManager();
}
- public MyEndpointReference activateEndpoint(QName pid, Endpoint endpoint) throws
Exception {
+ public synchronized MyEndpointReference activateEndpoint(QName pid, Endpoint
endpoint) throws Exception {
if (__log.isDebugEnabled()) {
__log.debug("Activate endpoint: " + endpoint);
}
- OdeService service = new OdeService(this, endpoint);
+
+ OdeService service=_activeOdeServices.get(endpoint);
+ if(service == null)
+ service = new OdeService(this, endpoint);
try {
ProcessConf pc = _store.getProcessConfiguration(pid);
InputStream is = pc.getCBPInputStream();
@@ -223,12 +226,15 @@
}
- public void deactivateEndpoint(Endpoint endpoint) throws Exception {
- OdeService svc = _activeOdeServices.remove(endpoint);
+ public synchronized void deactivateEndpoint(Endpoint endpoint) throws Exception {
+ OdeService svc = _activeOdeServices.get(endpoint);
if (svc != null) {
_serviceEprMap.remove(svc);
- svc.deactivate();
+ svc.deactivate();
+ if(svc.getCount() < 1 ) {
+ _activeOdeServices.remove(endpoint);
+ }
}
}
Modified: branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeLifeCycle.java
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeLifeCycle.java 2010-04-14
15:43:12 UTC (rev 619)
+++ branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeLifeCycle.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -21,8 +21,6 @@
import java.io.File;
import java.io.FileNotFoundException;
-import java.util.HashMap;
-import java.util.Map;
import java.util.concurrent.Executors;
import javax.jbi.JBIException;
@@ -39,7 +37,6 @@
import org.apache.ode.bpel.dao.BpelDAOConnectionFactoryJDBC;
import org.apache.ode.bpel.engine.BpelServerImpl;
import org.apache.ode.bpel.engine.ProcessAndInstanceManagementMBean;
-import org.apache.ode.bpel.engine.ProcessAndInstanceManagementImpl;
import org.apache.ode.bpel.extvar.jdbc.JdbcExternalVariableModule;
import org.apache.ode.bpel.iapi.BpelEventListener;
@@ -78,6 +75,16 @@
private ObjectName _mbeanName;
+ private OdeConfigProperties _config;
+
+ public OdeLifeCycle() {
+
+ }
+
+ public OdeLifeCycle(OdeConfigProperties config) {
+ _config = config;
+ }
+
ServiceUnitManager getSUManager() {
return _suManager;
}
@@ -104,8 +111,13 @@
if (_ode.getContext().getWorkspaceRoot() != null)
TempFileManager.setWorkingDirectory(new
File(_ode.getContext().getWorkspaceRoot()));
- __log.debug("Loading properties.");
- initProperties();
+ if (_config == null) {
+ __log.debug("Loading properties.");
+ initProperties();
+ } else {
+ __log.debug("Applying properties.");
+ _ode._config = _config;
+ }
__log.debug("Initializing message mappers.");
initMappers();
@@ -135,10 +147,9 @@
_suManager = new OdeSUManager(_ode);
_initSuccess = true;
__log.info(__msgs.msgOdeInitialized());
- } finally {
- if (!_initSuccess) {
- // TODO ..then what? at least shutdown the scheduler
- }
+ } catch (Throwable t) {
+ __log.fatal("", t);
+ throw new JBIException("Fatal error", t);
}
}
@@ -183,7 +194,7 @@
_ode._dataSource = _db.getDataSource();
}
-
+
/**
* Load the "ode-jbi.properties" file from the install directory.
*
Modified: branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeSUManager.java
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeSUManager.java 2010-04-14
15:43:12 UTC (rev 619)
+++ branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeSUManager.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -40,6 +40,8 @@
private static final Messages __msgs = Messages.getMessages(Messages.class);
+ private static final String XMLNS_JBI_MGMT =
"http://java.sun.com/xml/ns/jbi/management-message";
+
private OdeContext _ode;
/** All the service units that have been "init"ed. */
@@ -110,13 +112,16 @@
__log.error(errmsg, ex);
throw new DeploymentException(errmsg, ex);
}
-
+ ClassLoader cl = Thread.currentThread().getContextClassLoader();
try {
- su.start();
+ Thread.currentThread().setContextClassLoader(su.getConfigurationClassLoader());
+ su.start();
} catch (Exception ex) {
String errmsg = __msgs.msgServiceUnitStartFailed(serviceUnitID);
__log.error(errmsg, ex);
throw new DeploymentException(errmsg, ex);
+ } finally {
+ Thread.currentThread().setContextClassLoader(cl);
}
}
@@ -221,24 +226,24 @@
throw new RuntimeException(ex);
}
- Element elem = doc.createElement("component-task-result");
+ Element elem = doc.createElementNS(XMLNS_JBI_MGMT,
"component-task-result");
doc.appendChild(elem);
- Element compNameElem = doc.createElement("component-name");
+ Element compNameElem = doc.createElementNS(XMLNS_JBI_MGMT,
"component-name");
elem.appendChild(compNameElem);
- Element compTaskRsltDtlsElem =
doc.createElement("component-task-result-details");
+ Element compTaskRsltDtlsElem = doc.createElementNS(XMLNS_JBI_MGMT,
"component-task-result-details");
elem.appendChild(compTaskRsltDtlsElem);
- Element taskRsltDtlsElem = doc.createElement("task-result-details");
+ Element taskRsltDtlsElem = doc.createElementNS(XMLNS_JBI_MGMT,
"task-result-details");
compTaskRsltDtlsElem.appendChild(taskRsltDtlsElem);
- Element taskId = doc.createElement("task-id");
+ Element taskId = doc.createElementNS(XMLNS_JBI_MGMT, "task-id");
taskRsltDtlsElem.appendChild(taskId);
- Element taskResult = doc.createElement("task-result");
+ Element taskResult = doc.createElementNS(XMLNS_JBI_MGMT, "task-result");
taskRsltDtlsElem.appendChild(taskResult);
// Why do I have to tell this thing the component name? It /knows/ the
// component name....
-
compNameElem.appendChild(doc.createTextNode(_ode.getContext().getComponentName()));
+ compNameElem.appendChild(doc.createTextNode(_ode.getContext().getComponentName()));
// And why on earth do I have to tell my caller the method he just
// called?
Modified: branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeService.java
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeService.java 2010-04-14
15:43:12 UTC (rev 619)
+++ branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeService.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -24,6 +24,7 @@
import org.apache.ode.bpel.iapi.Message;
import org.apache.ode.bpel.iapi.MessageExchange;
import org.apache.ode.bpel.iapi.MessageExchange.Status;
+import org.apache.ode.bpel.iapi.Scheduler.Synchronizer;
import org.apache.ode.bpel.iapi.MyRoleMessageExchange;
import org.apache.ode.jbi.msgmap.Mapper;
import org.apache.ode.jbi.msgmap.MessageTranslationException;
@@ -62,18 +63,26 @@
private Element _serviceref;
private Endpoint _endpoint;
+
+ private int count;
public OdeService(OdeContext odeContext, Endpoint endpoint) throws Exception {
_ode = odeContext;
_endpoint = endpoint;
}
+ public int getCount() {
+ return count;
+ }
/**
* Do the JBI endpoint activation.
*
* @throws JBIException
*/
public void activate() throws JBIException {
+ count++;
+ if(count != 1)
+ return;
if (_serviceref == null) {
ServiceEndpoint[] candidates =
_ode.getContext().getExternalEndpointsForService(_endpoint.serviceName);
if (candidates.length != 0) {
@@ -91,6 +100,9 @@
* Deactivate endpoints in JBI.
*/
public void deactivate() throws JBIException {
+ count--;
+ if(count != 0)
+ return;
_ode.getContext().deactivateEndpoint(_internal);
__log.debug("Dectivated endpoint " + _endpoint);
}
@@ -181,13 +193,16 @@
* message exchange
*/
public void onResponse(MyRoleMessageExchange mex) {
- __log.debug("Consuming MEX tracker " + mex.getClientId());
- javax.jbi.messaging.MessageExchange jbiMex =
_jbiMexTracker.consume(mex.getClientId());
+ final String clientId = mex.getClientId();
+ final String mexId = mex.getMessageExchangeId();
+ __log.debug("Processing MEX tracker mexId: " + mexId + " clientId:
" + clientId);
+ final javax.jbi.messaging.MessageExchange jbiMex =
_jbiMexTracker.peek(clientId);
if (jbiMex == null) {
- __log.warn("Ignoring unknown async reply: " + mex);
+ __log.warn("Ignoring unknown async reply. mexId: " + mexId + "
clientId: " + clientId);
return;
}
+ try {
switch (mex.getStatus()) {
case FAULT:
outResponseFault(mex, jbiMex);
@@ -199,9 +214,30 @@
outFailure(mex, jbiMex);
break;
default:
- __log.warn("Received ODE message exchange in unexpected state: " +
mex.getStatus());
+ __log.warn("Received ODE message exchange in unexpected state: " +
mex.getStatus() + " mexId: " + mexId + " clientId: " + clientId);
}
+
mex.release(mex.getStatus() == MessageExchange.Status.RESPONSE);
+ _ode._scheduler.registerSynchronizer(new Synchronizer() {
+ public void afterCompletion(boolean success) {
+ if (success) {
+ //Deliver reply to external world only if ODE scheduler's job has
completed successfully
+ try {
+ _ode.getChannel().send(jbiMex);
+ __log.debug("Consuming MEX tracker mexId: " + mexId +
" clientId: " + clientId);
+ _jbiMexTracker.consume(clientId);
+ } catch (MessagingException e) {
+ __log.error("Error delivering response from ODE to JBI
mexId: " + mexId + " clientId: " + clientId, e);
+ }
+ }
+ }
+
+ public void beforeCompletion() {
+ }
+ });
+ } catch (MessagingException e) {
+ __log.error("Error processing response from ODE to JBI mexId: " +
mexId + " clientId: " + clientId, e);
+ }
}
/**
@@ -255,7 +291,7 @@
}
} else {
__log.error("ODE MEX " + odeMex + " was
unroutable.");
- sendError(jbiMex, new IllegalArgumentException("Unroutable
invocation."));
+ setError(jbiMex, new IllegalArgumentException("Unroutable
invocation."));
}
success = true;
@@ -279,18 +315,13 @@
}
- private void outFailure(MyRoleMessageExchange odeMex,
javax.jbi.messaging.MessageExchange jbiMex) {
- try {
- jbiMex.setError(new Exception("MEXFailure"));
- jbiMex.setStatus(ExchangeStatus.ERROR);
- // TODO: get failure codes out of the message.
- _ode.getChannel().send(jbiMex);
- } catch (MessagingException ex) {
- __log.fatal("Error bridging ODE out response: ", ex);
- }
+ private void outFailure(MyRoleMessageExchange odeMex,
javax.jbi.messaging.MessageExchange jbiMex) throws MessagingException {
+ jbiMex.setError(new Exception("MEXFailure"));
+ jbiMex.setStatus(ExchangeStatus.ERROR);
+ // TODO: get failure codes out of the message.
}
- private void outResponse(MyRoleMessageExchange mex,
javax.jbi.messaging.MessageExchange jbiMex) {
+ private void outResponse(MyRoleMessageExchange mex,
javax.jbi.messaging.MessageExchange jbiMex) throws MessagingException {
InOut inout = (InOut) jbiMex;
try {
@@ -307,19 +338,13 @@
mapper.toNMS(nmsg, mex.getResponse(),
mex.getOperation().getOutput().getMessage(), null);
inout.setOutMessage(nmsg);
- _ode.getChannel().send(inout);
-
- } catch (MessagingException ex) {
- __log.error("Error bridging ODE out response: ", ex);
- sendError(jbiMex, ex);
} catch (MessageTranslationException e) {
__log.error("Error translating ODE message " + mex.getResponse() +
" to NMS format!", e);
- sendError(jbiMex, e);
+ setError(jbiMex, e);
}
}
- private void outResponseFault(MyRoleMessageExchange mex,
javax.jbi.messaging.MessageExchange jbiMex) {
-
+ private void outResponseFault(MyRoleMessageExchange mex,
javax.jbi.messaging.MessageExchange jbiMex) throws MessagingException {
InOut inout = (InOut) jbiMex;
try {
@@ -336,29 +361,20 @@
QName fault = mex.getFault();
javax.wsdl.Fault wsdlFault =
mex.getOperation().getFault(fault.getLocalPart());
if (wsdlFault == null) {
- sendError(jbiMex, new MessageTranslationException("Unmapped Fault :
" + fault + ": " + mex.getFaultExplanation()));
+ setError(jbiMex, new MessageTranslationException("Unmapped Fault :
" + fault + ": " + mex.getFaultExplanation()));
} else {
mapper.toNMS(flt, mex.getFaultResponse(), wsdlFault.getMessage(),
fault);
inout.setFault(flt);
- _ode.getChannel().send(inout);
}
- } catch (MessagingException e) {
- __log.error("Error bridging ODE fault response: ", e);
- sendError(jbiMex, e);
} catch (MessageTranslationException mte) {
__log.error("Error translating ODE fault message " +
mex.getFaultResponse() + " to NMS format!", mte);
- sendError(jbiMex, mte);
+ setError(jbiMex, mte);
}
}
- private void sendError(javax.jbi.messaging.MessageExchange jbiMex, Exception error)
{
- try {
- jbiMex.setError(error);
- jbiMex.setStatus(ExchangeStatus.ERROR);
- _ode.getChannel().send(jbiMex);
- } catch (Exception e) {
- __log.error("Error sending ERROR status: ", e);
- }
+ private void setError(javax.jbi.messaging.MessageExchange jbiMex, Exception error)
throws MessagingException {
+ jbiMex.setError(error);
+ jbiMex.setStatus(ExchangeStatus.ERROR);
}
public Endpoint getEndpoint() {
@@ -381,9 +397,12 @@
return found;
}
+ synchronized javax.jbi.messaging.MessageExchange peek(String clientId) {
+ return _outstandingJbiExchanges.get(clientId);
+ }
+
synchronized javax.jbi.messaging.MessageExchange consume(String clientId) {
return _outstandingJbiExchanges.remove(clientId);
}
-
}
}
Modified: branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeServiceUnit.java
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeServiceUnit.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/OdeServiceUnit.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -19,16 +19,21 @@
package org.apache.ode.jbi;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-
-import javax.jbi.management.DeploymentException;
-import javax.xml.namespace.QName;
import java.io.File;
+import java.io.FilenameFilter;
+import java.net.MalformedURLException;
+import java.net.URL;
+import java.net.URLClassLoader;
import java.util.ArrayList;
import java.util.Collection;
import java.util.List;
+import javax.jbi.management.DeploymentException;
+import javax.xml.namespace.QName;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
/**
* Representation of a JBI service unit. A JBI service unit may actually consist
* of multiple processes.
@@ -49,6 +54,7 @@
private Collection<QName> _registered = new ArrayList<QName>();
+ private static final String LIB_DIR = "lib";
/** Ctor. */
OdeServiceUnit(OdeContext ode, String serviceUnitID, String serviceUnitRootPath) {
@@ -58,13 +64,21 @@
}
public void deploy() throws DeploymentException {
+ ClassLoader cl = Thread.currentThread().getContextClassLoader();
try {
- _ode._store.deploy(_serviceUnitRootPath);
+ Thread.currentThread().setContextClassLoader(getConfigurationClassLoader());
+ // JBI ServiceUnits don't use autoincrement version,
+ // because in ServiceMix redeploying component yields to redeploying
dependent
+ // ServiceUnits, and we don't want to create new processes versions
+ // on such redeployments
+ _ode._store.deploy(_serviceUnitRootPath, false);
} catch (Exception ex) {
String errmsg = __msgs.msgOdeProcessDeploymentFailed(_serviceUnitRootPath,
_serviceUnitID);
__log.error(errmsg, ex);
throw new DeploymentException(errmsg, ex);
- }
+ } finally {
+ Thread.currentThread().setContextClassLoader(cl);
+ }
}
public void undeploy() throws Exception {
@@ -133,5 +147,35 @@
}
}
}
+
+ public ClassLoader getConfigurationClassLoader() throws DeploymentException {
+ return new URLClassLoader(getDefaultLocations(), getClass().getClassLoader());
+ }
+
+ protected URL[] getDefaultLocations() throws DeploymentException {
+ try {
+ File[] jars = new File(_serviceUnitRootPath, LIB_DIR).listFiles(new
FilenameFilter() {
+ public boolean accept(File dir, String name) {
+ name = name.toLowerCase();
+ return name.endsWith(".jar") ||
name.endsWith(".zip");
+ }
+ });
+ URL[] urls = new URL[jars != null ? jars.length + 1 : 1];
+ urls[0] = _serviceUnitRootPath.toURI().toURL();
+ if (jars != null) {
+ for (int i = 0; i < jars.length; i++) {
+ urls[i + 1] = jars[i].toURI().toURL();
+ }
+ }
+ if (__log.isDebugEnabled()) {
+ for (URL u : urls) {
+ __log.debug("in classpath for "+_serviceUnitID+" using url:
"+u);
+ }
+ }
+ return urls;
+ } catch (MalformedURLException e) {
+ throw new DeploymentException("Unable to get default classpath
locations", e);
+ }
+ }
}
Modified: branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/ServiceBridge.java
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/ServiceBridge.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/ServiceBridge.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -20,9 +20,13 @@
import java.util.Set;
+import javax.jbi.messaging.NormalizedMessage;
+
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
+import org.apache.ode.bpel.iapi.MessageExchange;
import org.apache.ode.bpel.iapi.MyRoleMessageExchange;
+import org.apache.ode.bpel.iapi.PartnerRoleMessageExchange;
/**
* Base-class for classes providing JBI-ODE translation services.
@@ -40,14 +44,19 @@
* @param jbiMex destination JBI message-exchange
* @param odeMex source ODE message-exchange
*/
- protected void copyMexProperties(javax.jbi.messaging.MessageExchange jbiMex,
MyRoleMessageExchange odeMex) {
+ protected void copyMexProperties(javax.jbi.messaging.MessageExchange jbiMex,
PartnerRoleMessageExchange odeMex) {
+ __log.debug(odeMex + ": pmex copyProperties");
+ NormalizedMessage in = jbiMex.getMessage("in");
for (String propName : odeMex.getPropertyNames()) {
String val = odeMex.getProperty(propName);
if (val != null) {
- jbiMex.setProperty(propName, val);
- __log.debug(jbiMex + ": set property " + propName + " =
" + val);
+ in.setProperty(propName, val);
+ __log.debug(jbiMex + ": set pmex property " + propName + "
= " + val);
}
}
+
+ in.setProperty(MessageExchange.PROPERTY_SEP_MYROLE_SESSIONID,
odeMex.getProperty(MessageExchange.PROPERTY_SEP_PARTNERROLE_SESSIONID));
+ in.setProperty(MessageExchange.PROPERTY_SEP_PARTNERROLE_SESSIONID,
odeMex.getProperty(MessageExchange.PROPERTY_SEP_MYROLE_SESSIONID));
}
/**
@@ -58,21 +67,22 @@
*/
@SuppressWarnings("unchecked")
protected void copyMexProperties(MyRoleMessageExchange odeMex,
javax.jbi.messaging.MessageExchange jbiMex) {
- for (String propName : (Set<String>) jbiMex.getPropertyNames()) {
- if (propName.startsWith("org.apache.ode")) {
+ __log.debug(odeMex + ": mmex copyProperties");
+ NormalizedMessage in = jbiMex.getMessage("in");
+ for (String propName : (Set<String>) in.getPropertyNames()) {
+ Object val = in.getProperty(propName);
+ if (propName.startsWith("org.apache.ode") ) {
// Handle ODE-specific properties
- Object val = jbiMex.getProperty(propName);
if (val != null) {
String sval = val.toString();
odeMex.setProperty(propName, sval);
- __log.debug(odeMex + ": set property " + propName + "
= " + sval);
+ __log.debug(odeMex + ": set mmex property " + propName +
" = " + sval);
}
} else {
// Non ODE-specific properties,
// TODO: Should we copy these?
+ __log.debug(odeMex + ": other mmex property " + propName +
" = " + val);
}
}
}
-
-
}
Modified:
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/msgmap/JbiWsdl11WrapperMapper.java
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/msgmap/JbiWsdl11WrapperMapper.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/msgmap/JbiWsdl11WrapperMapper.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -204,8 +204,8 @@
if (etype == null && p.getElementName() == null)
continue;
- if (etype.equals(p.getElementName()))
- continue;
+ if (!etype.equals(p.getElementName()))
+ continue fltiter;
}
return f;
Modified:
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/msgmap/ServiceMixMapper.java
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/msgmap/ServiceMixMapper.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/jbi/src/main/java/org/apache/ode/jbi/msgmap/ServiceMixMapper.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -20,6 +20,8 @@
package org.apache.ode.jbi.msgmap;
import java.util.Collection;
+import java.util.HashMap;
+import java.util.Map;
import java.util.Set;
import javax.jbi.messaging.MessagingException;
@@ -33,7 +35,9 @@
import org.apache.ode.bpel.iapi.Message;
import org.apache.ode.utils.DOMUtils;
import org.w3c.dom.Document;
+import org.w3c.dom.DocumentFragment;
import org.w3c.dom.Element;
+import org.w3c.dom.Node;
/**
* Message mapper for dealing with the degenerate messages that servicemix components
such as servicemix-http provide. These
@@ -78,42 +82,68 @@
return Recognized.UNSURE;
}
- for (String pname : ((Set<String>)
op.getInput().getMessage().getParts().keySet())) {
- Part part = op.getInput().getMessage().getPart(pname);
- Element pdata = null;
- // servicemix-http has a (bad) habit of placing the SOAP body content
directly in the normalized message
+ // servicemix-http has a (bad) habit of placing the SOAP body content directly in
the normalized message.
+ // We need to recognize it
+ __log.debug("Recognizing document content");
+ if (op.getInput().getMessage().getParts().size() == 1) {
+ Part part = (Part)
op.getInput().getMessage().getParts().values().iterator().next();
QName elementName = part.getElementName();
if (elementName != null &&
elementName.getLocalPart().equals(msg.getLocalName())
&&
elementName.getNamespaceURI().equals(msg.getNamespaceURI())) {
- pdata = msg;
+ __log.debug("Recognized");
+ return Recognized.TRUE;
}
- if (pdata == null) {
- // with RPC semantic the body is wrapped by a partName which is same as
bodyElementName
- pdata = DOMUtils.findChildByName(msg, new QName(null, part.getName()));
+ }
+
+ // Recognize RPC style message
+ __log.debug("Recognizing RPC style content");
+ for (String pname : ((Set<String>)
op.getInput().getMessage().getParts().keySet())) {
+ Part part = op.getInput().getMessage().getPart(pname);
+
+ if (part.getElementName() != null) {
+ //RPC style invocation doesn't allow element parts, so we don't
accept it
+ __log.debug("Part " + part.getName() + " has element content
" + part.getElementName() + ". It's not allowed for RPC style.");
+ return Recognized.FALSE;
}
+
+ // with RPC semantic the body is wrapped by a partName which is same as
bodyElementName
+ Element pdata = DOMUtils.findChildByName(msg, new QName(null,
part.getName()));
if (pdata == null) {
__log.debug("no part data for " + part.getName() + " --
unrecognized.");
return Recognized.FALSE;
}
- if (part.getElementName() != null) {
- Element child = DOMUtils.getFirstChildElement(pdata);
- if (child == null) {
- __log.debug("element part " + part.getName() + " does
not contain element " + part.getElementName()
- + " -- unrecognized");
- return Recognized.FALSE;
- }
-
- }
}
return Recognized.TRUE;
-
}
public void toNMS(NormalizedMessage nmsMsg, Message odeMsg, javax.wsdl.Message
msgdef, QName fault) throws MessagingException,
MessageTranslationException {
if (msgdef == null)
throw new NullPointerException("msdef must not be null.");
+
+ Map<String, Node> headers = odeMsg.getHeaderParts();
+ if (headers != null) {
+ for (String header : headers.keySet()) {
+ if (__log.isDebugEnabled()) {
+ __log.debug("toNMS() header " + header + " := " +
DOMUtils.domToString(headers.get(header)) );
+ }
+
+ Map<QName, DocumentFragment> headers2 = (Map<QName,
DocumentFragment>) nmsMsg.getProperty("org.apache.servicemix.soap.headers");
+ if (headers2 == null) {
+ headers2 = new HashMap<QName, DocumentFragment>();
+ nmsMsg.setProperty("org.apache.servicemix.soap.headers",
headers2);
+ }
+
+ Node v = headers.get(header);
+ DocumentFragment f = v.getOwnerDocument().createDocumentFragment();
+ f.appendChild(v);
+ headers2.put(QName.valueOf(header), f);
+ }
+ }
+
+
+
Element ode = odeMsg == null ? null : odeMsg.getMessage();
Element part = ode == null ? null : DOMUtils.getFirstChildElement(ode);
Element firstPartEl = part == null ? null : DOMUtils.getFirstChildElement(part);
@@ -147,7 +177,12 @@
return;
}
- if (msgdef.getParts().size() > 1 || ((Part)
msgdef.getParts().values().iterator().next()).getElementName() == null) {
+ if (msgdef.getParts().size() == 0) {
+ if (__log.isDebugEnabled())
+ __log.debug("toNMS() ode message (rpc-like): no parts");
+ nmsMsg.setContent(null);
+ return;
+ } else if (msgdef.getParts().size() != 1 || ((Part)
msgdef.getParts().values().iterator().next()).getElementName() == null) {
// If we have more than one part, or a single non-element part, then we
can't use the standard
// NMS doc-lit like convention. Instead we place the entire message on the
bus and hope for the
// best.
@@ -163,13 +198,25 @@
}
public void toODE(Message odeMsg, NormalizedMessage nmsMsg, javax.wsdl.Message
msgdef) throws MessageTranslationException {
- Element nms = parse(nmsMsg.getContent());
- boolean docLit = false;
-
+ Element nms;
+ if (nmsMsg.getContent() != null) {
+ nms = parse(nmsMsg.getContent());
+ } else {
+ Document doc = newDocument();
+ Element message = doc.createElement("message");
+ odeMsg.setMessage(message);
+ if (__log.isDebugEnabled()) {
+ __log.debug("toODE() normalized message:\n" +
prettyPrint(message));
+ }
+ return;
+ }
+
if (__log.isDebugEnabled()) {
__log.debug("toODE() normalized message:\n" + prettyPrint(nms));
}
+ boolean docLit = false;
+
for (String pname : ((Set<String>) msgdef.getParts().keySet())) {
Part part = msgdef.getPart(pname);
// servicemix-http has a (bad) habit of placing the SOAP body content
directly in the normalized message
@@ -200,6 +247,20 @@
}
odeMsg.setMessage(nms);
}
+
+ Map<QName, DocumentFragment> headers = (Map<QName, DocumentFragment>)
nmsMsg.getProperty("org.apache.servicemix.soap.headers");
+ if (headers != null) {
+ for (QName header : headers.keySet()) {
+ if (__log.isDebugEnabled()) {
+ __log.debug("toODE() header " + header + " := " +
DOMUtils.domToString(headers.get(header)) );
+ }
+ try {
+ odeMsg.setHeaderPart(header.getLocalPart(),
DOMUtils.stringToDOM(DOMUtils.domToString(headers.get(header))));
+ } catch (Exception e) {
+ __log.error("Can't copy input header " + header);
+ }
+ }
+ }
}
public Fault toFaultType(javax.jbi.messaging.Fault jbiFlt, Collection<Fault>
faults) throws MessageTranslationException {
Added:
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/CommunicationJbiTest.java
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/CommunicationJbiTest.java
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/CommunicationJbiTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,23 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.ode.jbi;
+
+public class CommunicationJbiTest extends JbiTestBase {
+ public void testCommunication() throws Exception {
+ go();
+ }
+}
Added: branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/DigestJbiTest.java
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/DigestJbiTest.java
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/DigestJbiTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,23 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.ode.jbi;
+
+public class DigestJbiTest extends JbiTestBase {
+ public void testDigest() throws Exception {
+ go();
+ }
+}
Added: branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/EmptyRespJbiTest.java
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/EmptyRespJbiTest.java
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/EmptyRespJbiTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,23 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.ode.jbi;
+
+public class EmptyRespJbiTest extends JbiTestBase {
+ public void testEmptyResp() throws Exception {
+ go();
+ }
+}
Modified: branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/ExtVarJbiTest.java
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/ExtVarJbiTest.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/ExtVarJbiTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -1,3 +1,19 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
package org.apache.ode.jbi;
import java.sql.Connection;
Modified:
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/HelloWorldJbiTest.java
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/HelloWorldJbiTest.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/HelloWorldJbiTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -1,3 +1,19 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
package org.apache.ode.jbi;
public class HelloWorldJbiTest extends JbiTestBase {
Modified: branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/JbiTestBase.java
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/JbiTestBase.java 2010-04-14
15:43:12 UTC (rev 619)
+++ branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/JbiTestBase.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -19,16 +19,21 @@
import java.io.ByteArrayInputStream;
import java.io.ByteArrayOutputStream;
import java.io.File;
+import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.net.URL;
import java.net.URLConnection;
+import java.sql.Connection;
+import java.sql.Statement;
import java.util.Properties;
import java.util.regex.Pattern;
import javax.jbi.messaging.ExchangeStatus;
import javax.jbi.messaging.InOut;
+import javax.sql.DataSource;
+import javax.transaction.TransactionManager;
import javax.xml.namespace.QName;
import javax.xml.transform.stream.StreamSource;
@@ -54,16 +59,32 @@
protected JBIContainer jbiContainer;
protected Properties testProperties;
+ protected DefaultServiceMixClient smxClient;
@Override
protected AbstractXmlApplicationContext createBeanFactory() {
- return new ClassPathXmlApplicationContext("/" + getTestName() +
"/smx.xml");
+ return new ClassPathXmlApplicationContext(new String[] {
+ "/smx-base.xml",
+ "/" + getTestName() + "/smx.xml"
+ });
}
+ private void initOdeDb() throws Exception {
+ TransactionManager tm = (TransactionManager)
getBean("transactionManager");
+ tm.begin();
+ Connection conn = ((DataSource) getBean("odeDS")).getConnection();
+ Statement s = conn.createStatement();
+ s.execute("delete from bpel_process");
+ s.close();
+ tm.commit();
+ }
+
@Override
protected void setUp() throws Exception {
super.setUp();
+ initOdeDb();
+
jbiContainer = ((JBIContainer) getBean("jbi"));
odeComponent = new OdeComponent();
@@ -75,6 +96,8 @@
testProperties = new Properties();
testProperties.load(getClass().getResourceAsStream("/" + getTestName()
+ "/test.properties"));
+
+ smxClient = new DefaultServiceMixClient(jbiContainer);
}
protected String getTestName() {
@@ -101,52 +124,103 @@
protected void go() throws Exception {
- enableProcess(getTestName(), true);
+ boolean manualDeploy = Boolean.parseBoolean("" +
testProperties.getProperty("manualDeploy"));
+ if (!manualDeploy)
+ enableProcess(getTestName(), true);
- String request = testProperties.getProperty("request");
- String expectedResponse = testProperties.getProperty("response");
- {
- String httpUrl = testProperties.getProperty("http.url");
- if (httpUrl != null) {
- log.debug(getTestName() + " sending http request to " + httpUrl +
" request: " + request);
- URLConnection connection = new URL(httpUrl).openConnection();
- connection.setDoOutput(true);
- connection.setDoInput(true);
- //Send request
- OutputStream os = connection.getOutputStream();
- PrintWriter wt = new PrintWriter(os);
- wt.print(request);
- wt.flush();
- wt.close();
- // Read the response.
- InputStream is = connection.getInputStream();
- ByteArrayOutputStream baos = new ByteArrayOutputStream();
- FileUtil.copyInputStream(is, baos);
- String result = baos.toString();
- log.debug(getTestName() + " have result: " + result);
- matchResponse(expectedResponse, result);
- }
- }
- {
- if (testProperties.getProperty("nmr.service") != null) {
- DefaultServiceMixClient client = new DefaultServiceMixClient(jbiContainer);
- InOut io = client.createInOutExchange();
-
io.setService(QName.valueOf(testProperties.getProperty("nmr.service")));
-
io.setOperation(QName.valueOf(testProperties.getProperty("nmr.operation")));
- io.getInMessage().setContent(new StreamSource(new
ByteArrayInputStream(request.getBytes())));
- client.sendSync(io,20000);
- assertEquals(ExchangeStatus.ACTIVE,io.getStatus());
- assertNotNull(io.getOutMessage());
- String result = new
SourceTransformer().contentToString(io.getOutMessage());
- matchResponse(expectedResponse, result);
- client.done(io);
- }
- }
+ int i = 0;
+ boolean loop;
+ do {
+ String prefix = i == 0 ? "" : "" + i;
+ loop = i == 0;
+
+ {
+ String deploy = testProperties.getProperty(prefix + "deploy");
+ if (deploy != null) {
+ loop = true;
+ enableProcess(getTestName() + "/" + deploy, true);
+ }
+ }
+ {
+ String undeploy = testProperties.getProperty(prefix +
"undeploy");
+ if (undeploy != null) {
+ loop = true;
+ enableProcess(getTestName() + "/" + undeploy, false);
+ }
+ }
+
+ String request = testProperties.getProperty(prefix + "request");
+ if (request != null && request.startsWith("@")) {
+ request =
inputStreamToString(getClass().getResourceAsStream("/" + getTestName() +
"/" + request.substring(1)));
+ }
+ String expectedResponse = testProperties.getProperty(prefix +
"response");
+ {
+ String delay = testProperties.getProperty(prefix + "delay");
+ if (delay != null) {
+ loop = true;
+ long d = Long.parseLong(delay);
+ log.debug("Sleeping " + d + " ms");
+ Thread.sleep(d);
+ }
+ }
+ {
+ String httpUrl = testProperties.getProperty(prefix + "http.url");
+ if (httpUrl != null && request != null) {
+ loop = true;
+ log.debug(getTestName() + " sending http request to " +
httpUrl + " request: " + request);
+ URLConnection connection = new URL(httpUrl).openConnection();
+ connection.setDoOutput(true);
+ connection.setDoInput(true);
+ //Send request
+ OutputStream os = connection.getOutputStream();
+ PrintWriter wt = new PrintWriter(os);
+ wt.print(request);
+ wt.flush();
+ wt.close();
+ // Read the response.
+ String result = inputStreamToString(connection.getInputStream());
+
+ log.debug(getTestName() + " have result: " + result);
+ matchResponse(expectedResponse, result, true);
+ }
+ }
+ {
+ if (testProperties.getProperty(prefix + "nmr.service") != null
&& request != null) {
+ loop = true;
+ InOut io = smxClient.createInOutExchange();
+ io.setService(QName.valueOf(testProperties.getProperty(prefix +
"nmr.service")));
+ io.setOperation(QName.valueOf(testProperties.getProperty(prefix +
"nmr.operation")));
+ io.getInMessage().setContent(new StreamSource(new
ByteArrayInputStream(request.getBytes())));
+ smxClient.sendSync(io,20000);
+ if (io.getStatus() == ExchangeStatus.ACTIVE) {
+ assertNotNull(io.getOutMessage());
+ String result = new
SourceTransformer().contentToString(io.getOutMessage());
+ matchResponse(expectedResponse, result, true);
+ smxClient.done(io);
+ } else {
+ matchResponse(expectedResponse, "", false);
+ }
+ }
+ }
+
+ i++;
+ } while (loop);
- enableProcess(getTestName(), false);
+ if (!manualDeploy)
+ enableProcess(getTestName(), false);
}
- protected void matchResponse(String expectedResponse, String result) {
- assertTrue("Response doesn't match expected regex.\nExpected: " +
expectedResponse + "\nReceived: " + result, Pattern.compile(expectedResponse,
Pattern.DOTALL).matcher(result).matches());
+ protected void matchResponse(String expectedResponse, String result, boolean
succeeded) {
+ if (succeeded) {
+ assertTrue("Response doesn't match expected regex.\nExpected: "
+ expectedResponse + "\nReceived: " + result, Pattern.compile(expectedResponse,
Pattern.DOTALL).matcher(result).matches());
+ } else {
+ assertTrue("Expected success, but got fault",
expectedResponse.equals("FAULT"));
+ }
}
+
+ private String inputStreamToString(InputStream is) throws IOException {
+ ByteArrayOutputStream baos = new ByteArrayOutputStream();
+ FileUtil.copyInputStream(is, baos);
+ return baos.toString();
+ }
}
Added:
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/MagicSessionExternalJbiTest.java
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/MagicSessionExternalJbiTest.java
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/MagicSessionExternalJbiTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,23 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.ode.jbi;
+
+public class MagicSessionExternalJbiTest extends JbiTestBase {
+ public void testMagicSessionExternal() throws Exception {
+ go();
+ }
+}
Added: branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/MagicSessionJbiTest.java
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/MagicSessionJbiTest.java
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/MagicSessionJbiTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,23 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.ode.jbi;
+
+public class MagicSessionJbiTest extends JbiTestBase {
+ public void testMagicSession() throws Exception {
+ go();
+ }
+}
Modified:
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/OdeJbiComponentLifeCycleTest.java
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/OdeJbiComponentLifeCycleTest.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/OdeJbiComponentLifeCycleTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -25,6 +25,7 @@
import org.apache.servicemix.jbi.container.JBIContainer;
import org.apache.servicemix.jbi.framework.ComponentContextImpl;
import org.apache.servicemix.jbi.framework.ComponentNameSpace;
+import org.junit.Ignore;
import javax.jbi.messaging.ExchangeStatus;
import javax.jbi.messaging.InOut;
@@ -33,6 +34,7 @@
import javax.xml.transform.stream.StreamSource;
import java.io.File;
+@Ignore
public class OdeJbiComponentLifeCycleTest extends TestCase {
JBIContainer container;
Added: branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/OnEventAlarmJbiTest.java
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/OnEventAlarmJbiTest.java
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/OnEventAlarmJbiTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,25 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.ode.jbi;
+
+public class OnEventAlarmJbiTest extends JbiTestBase {
+ public void testOnEventAlarm() throws Exception {
+ go();
+ }
+}
Added: branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/ReplayerJbiTest.java
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/ReplayerJbiTest.java
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/ReplayerJbiTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,23 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.ode.jbi;
+
+public class ReplayerJbiTest extends JbiTestBase {
+ public void testCommunication() throws Exception {
+ go();
+ }
+}
Added: branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/RetireJbiTest.java
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/RetireJbiTest.java
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/RetireJbiTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,7 @@
+package org.apache.ode.jbi;
+
+public class RetireJbiTest extends JbiTestBase {
+ public void testRetire() throws Exception {
+ go();
+ }
+}
Added:
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/msgmap/JbiWsdl11WrapperMapperTest.java
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/msgmap/JbiWsdl11WrapperMapperTest.java
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/java/org/apache/ode/jbi/msgmap/JbiWsdl11WrapperMapperTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,131 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.ode.jbi.msgmap;
+
+import java.util.Set;
+
+import javax.activation.DataHandler;
+import javax.jbi.messaging.Fault;
+import javax.jbi.messaging.MessagingException;
+import javax.security.auth.Subject;
+import javax.wsdl.Definition;
+import javax.wsdl.Operation;
+import javax.xml.namespace.QName;
+import javax.xml.transform.Source;
+import javax.xml.transform.dom.DOMSource;
+
+import org.apache.commons.io.IOUtils;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+import org.apache.ode.utils.DOMUtils;
+
+public class JbiWsdl11WrapperMapperTest extends junit.framework.TestCase {
+ private static Log __log = LogFactory.getLog(JbiWsdl11WrapperMapperTest.class);
+
+ public static class MockJbiFault implements javax.jbi.messaging.Fault {
+ private String resourceName;
+
+ public MockJbiFault(String resourceName) {
+ this.resourceName = resourceName;
+ }
+
+ public void addAttachment(String id, DataHandler content) throws
MessagingException {
+ // TODO Auto-generated method stub
+ __log.debug("addAttachment");
+
+ }
+
+ public DataHandler getAttachment(String id) {
+ // TODO Auto-generated method stub
+ __log.debug("getAttachment");
+ return null;
+ }
+
+ public Set getAttachmentNames() {
+ // TODO Auto-generated method stub
+ __log.debug("getAttachmentNames");
+ return null;
+ }
+
+ public Source getContent() {
+ try {
+ return new
DOMSource(DOMUtils.stringToDOM(IOUtils.toString(getClass().getResourceAsStream(resourceName))));
+ } catch (Exception e) {
+ throw new RuntimeException("", e);
+ }
+ }
+
+ public Object getProperty(String name) {
+ // TODO Auto-generated method stub
+ __log.debug("getProperty");
+ return null;
+ }
+
+ public Set getPropertyNames() {
+ // TODO Auto-generated method stub
+ __log.debug("getPropertyNames");
+ return null;
+ }
+
+ public Subject getSecuritySubject() {
+ // TODO Auto-generated method stub
+ __log.debug("getSecuritySubject");
+ return null;
+ }
+
+ public void removeAttachment(String id) throws MessagingException {
+ // TODO Auto-generated method stub
+ __log.debug("removeAttachment");
+
+ }
+
+ public void setContent(Source content) throws MessagingException {
+ // TODO Auto-generated method stub
+ __log.debug("setContent");
+
+ }
+
+ public void setProperty(String name, Object value) {
+ // TODO Auto-generated method stub
+ __log.debug("setProperty");
+
+ }
+
+ public void setSecuritySubject(Subject subject) {
+ // TODO Auto-generated method stub
+ __log.debug("setSecuritySubject");
+
+ }
+
+ };
+
+ public void testFault() throws Exception {
+ JbiWsdl11WrapperMapper m = new JbiWsdl11WrapperMapper();
+ Definition w =
javax.wsdl.factory.WSDLFactory.newInstance().newWSDLReader().readWSDL(getClass().getResource("/test.wsdl").getFile());
+ {
+ Fault f = new MockJbiFault("/fault.xml");
+ javax.wsdl.Fault k = m.toFaultType(f, ((Operation)
w.getPortType(QName.valueOf("{http://www.example.org/test/}test"...;
+ assertEquals("fault", k.getName());
+ }
+ {
+ Fault f = new MockJbiFault("/fault1.xml");
+ javax.wsdl.Fault k = m.toFaultType(f, ((Operation)
w.getPortType(QName.valueOf("{http://www.example.org/test/}test"...;
+ assertEquals("fault1", k.getName());
+ }
+ }
+}
Added: branches/ODE/ODE-1.x/jbi/src/test/jbi/ode-jbi.properties
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/jbi/ode-jbi.properties (rev
0)
+++ branches/ODE/ODE-1.x/jbi/src/test/jbi/ode-jbi.properties 2010-04-14 18:25:55 UTC (rev
620)
@@ -0,0 +1,78 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+#
http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+
+# ODE-JBI Configuraiton Properties
+
+# Process Identifier Namespace [QNAME]
+# Namespace for processes created using the JBI integration.
+# This will be the namespace of the process identifiers (PIDs)
+ode-jbi.pidNamespace=urn:ode-jbi
+
+# Allow Incomplete Deployment ("true","false")
+# Should incomplete deployments be allowed? An incomplete deployment
+# arises when a service unit contains multiple processes and not all
+# of the processes can be deployed. If incomplete deployments are
+# allowed (true), the service unit will report success if any of the
+# processes can be deployed. If not allowed (false), a failure in
+# one process will prevent all processes from being deployed.
+ode-jbi.allowIncompleteDeployment=false
+
+# Database Mode ("INTERNAL", "EXTERNAL", "EMBEDDED")
+# What kind of database should ODE use?
+# * "EMBEDDED" - ODE will create its own embbeded database (Derby)
+# and connection pool (Minerva).
+# * "EXTERNAL" - ODE will use an app-server provided database and pool.
+# The "ode-jbi.db.ext.dataSource" property will need to
+# be set.
+# * "INTERNAL" - ODE will create its own connection pool for a user-
+# specified JDBC URL and driver.
+ode-jbi.db.mode=EXTERNAL
+
+# External Database [JNDI Name]
+# JNDI Name of the DataSource for the ODE database. This is only
+# used if the "ode-jbi.db.mode" property is set to "EXTERNAL"
+ode-jbi.db.ext.dataSource=java:comp/env/jdbc/ode
+
+# Embedded Database Name [String]
+# Name of the embedded Derby database. This is only used if the
+# "ode-jbi.db.mode" property is set to "EMBEDDED".
+#ode-jbi.db.emb.name=hibdb
+#ode-jbi.db.emb.name=jpadb
+
+# Internal Database Configuration
+#ode-jbi.db.int.jdbcurl=jdbc:mysql://localhost/ode?user=sa
+#ode-jbi.db.int.driver=com.mysql.jdbc.Driver
+
+
+# DAO Connection Factory class.
+# uncomment the following for hibernate.
+ode-jbi.dao.factory=org.apache.ode.daohib.bpel.BpelDAOConnectionFactoryImpl
+
+# Class name of the message mapper that should be used to convert message
+# between ODE / NMS.
+# org.apache.ode.jbi.msgmap.JbiWsdl11WrapperMapper - use JBI WSDL 1.1
"wrapped"
+# org.apache.ode.jbi.msgmap.ServiceMixMapper
+# org.apache.ode.jbi.msgmap.DocLitMapper
+ode-jbi.messageMapper=org.apache.ode.jbi.msgmap.ServiceMixMapper
+
+# BPEL Event Listener
+# Uncomment the following for a debug output of BPEL navigation events.
+ode-jbi.event.listeners=org.apache.ode.bpel.common.evt.DebugBpelEventListener
+#debugeventlistener.dumpToStdOut=on/off
+
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/EPRTest.bpel
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/EPRTest.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/EPRTest.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,93 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<bpws:process
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns="http://sample.bpel.org/bpel/sampleArtifacts"
xmlns:tns="http://sample.bpel.org/bpel/sample"
exitOnStandardFault="yes" name="EPRTest"
suppressJoinFailure="yes"
targetNamespace="http://sample.bpel.org/bpel/sample"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://docs.oasis-open.org/wsbpel/2.0/process/ex...
/usr/share/bpel-schema/ws-bpel_executable.xsd">
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelationArtifacts.wsdl"
namespace="http://sample.bpel.org/bpel/sampleArtifacts"/>
+ <bpws:partnerLinks>
+ <bpws:partnerLink myRole="OnEventCorrelationProvider"
partnerRole="OnEventCorrelationProvider" name="client"
partnerLinkType="tns:OnEventCorrelation"
initializePartnerRole="no"/>
+ </bpws:partnerLinks>
+ <bpws:variables>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="input"/>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="output"/>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="output2"/>
+ <bpws:variable type="xsd:string" name="s"/>
+ </bpws:variables>
+ <bpws:correlationSets>
+ <bpws:correlationSet name="CorrelationSet"
properties="ns:input"/>
+ </bpws:correlationSets>
+ <bpws:sequence name="main">
+ <bpws:receive createInstance="yes" operation="opInOut"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input"/>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>
+ <bpws:literal>
+<sref:service-ref
xmlns:sref="http://docs.oasis-open.org/wsbpel/2.0/serviceref">
+ <wsa:EndpointReference
xmlns:wsa="http://www.w3.org/2005/08/addressing">
+
<wsa:Address>http://localhost:8198/EPRTest2/?http.soap=true&http.soapVersion=1.1</wsa:Address>
+ </wsa:EndpointReference>
+</sref:service-ref>
+ </bpws:literal>
+ </bpws:from>
+ <bpws:to partnerLink="client"/>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:invoke partnerLink="client" operation="opInOut"
inputVariable="input" outputVariable="output"/>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$output</bpws:from>
+ <bpws:to>$output2</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>
+ <bpws:literal>
+<sref:service-ref
xmlns:sref="http://docs.oasis-open.org/wsbpel/2.0/serviceref">
+<jbi:end-point-reference jbi:end-point-name="default"
+ jbi:service-name="bpel:EPRTest2"
+
xmlns:jbi="http://java.sun.com/jbi/end-point-reference"
xmlns:bpel="http://sample.bpel.org/bpel/sample"/>
+</sref:service-ref>
+ </bpws:literal>
+ </bpws:from>
+ <bpws:to partnerLink="client"/>
+ </bpws:copy>
+ <bpws:copy>
+ <bpws:from>''</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:invoke partnerLink="client" operation="opInOut"
inputVariable="input" outputVariable="output"/>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($output2.data, $output.data)</bpws:from>
+ <bpws:to>$output2.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:reply operation="opInOut" partnerLink="client"
variable="output2"/>
+ </bpws:sequence>
+</bpws:process>
+
+
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/EPRTest2.bpel
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/EPRTest2.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/EPRTest2.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,53 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<bpws:process
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns="http://sample.bpel.org/bpel/sampleArtifacts"
xmlns:tns="http://sample.bpel.org/bpel/sample"
exitOnStandardFault="yes" name="EPRTest2"
suppressJoinFailure="yes"
targetNamespace="http://sample.bpel.org/bpel/sample"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelationArtifacts.wsdl"
namespace="http://sample.bpel.org/bpel/sampleArtifacts"/>
+ <bpws:partnerLinks>
+ <bpws:partnerLink myRole="OnEventCorrelationProvider"
name="client" partnerLinkType="tns:OnEventCorrelation"/>
+ </bpws:partnerLinks>
+ <bpws:variables>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="input"/>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="output"/>
+ <bpws:variable type="xsd:string" name="s"/>
+ </bpws:variables>
+ <bpws:correlationSets>
+ <bpws:correlationSet name="CorrelationSet"
properties="ns:input"/>
+ </bpws:correlationSets>
+ <bpws:sequence name="main">
+
+ <bpws:receive createInstance="yes" operation="opInOut"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input">
+ </bpws:receive>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$input.payload</bpws:from>
+ <bpws:to>$output.payload</bpws:to>
+ </bpws:copy>
+ <bpws:copy>
+ <bpws:from>concat($input.data, '-EPRTest2')</bpws:from>
+ <bpws:to>$output.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:reply operation="opInOut" partnerLink="client"
variable="output"/>
+ </bpws:sequence>
+</bpws:process>
+
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation.wsdl
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,62 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions
xmlns="http://schemas.xmlsoap.org/wsdl/"
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
xmlns:tns="http://sample.bpel.org/bpel/sample"
xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/"
name="OnEventCorrelation"
targetNamespace="http://sample.bpel.org/bpel/sample"
+xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+>
+ <message name="OnEventCorrelationMessage">
+ <part type="xsd:string" name="payload"/>
+ <part type="xsd:string" name="data"/>
+ </message>
+ <portType name="OnEventCorrelation">
+ <operation name="opInOut">
+ <input message="tns:OnEventCorrelationMessage"/>
+ <output message="tns:OnEventCorrelationMessage"/>
+ </operation>
+ <operation name="opIn">
+ <input message="tns:OnEventCorrelationMessage"/>
+ </operation>
+ </portType>
+ <binding name="OnEventCorrelationBinding"
type="tns:OnEventCorrelation">
+ <wsdlsoap:binding style="rpc"
transport="http://schemas.xmlsoap.org/soap/http"/>
+ <operation name="opInOut">
+ <wsdlsoap:operation soapAction="opInOut"/>
+ <input>
+ <wsdlsoap:body use="literal"/>
+ </input>
+ <output>
+ <wsdlsoap:body use="literal"/>
+ </output>
+ </operation>
+ <operation name="opIn">
+ <wsdlsoap:operation soapAction="opIn"/>
+ <input>
+ <wsdlsoap:body use="literal"/>
+ </input>
+ </operation>
+ </binding>
+ <service name="OnEventCorrelation">
+ <port binding="tns:OnEventCorrelationBinding"
name="OnEventCorrelation">
+ <wsdlsoap:address
location="http://localhost:8080/ode/processes/OnEventCorrelation/"/>
+ </port>
+ </service>
+ <plnk:partnerLinkType name="OnEventCorrelation">
+ <plnk:role name="OnEventCorrelationProvider"
portType="tns:OnEventCorrelation"/>
+ </plnk:partnerLinkType>
+</definitions>
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation000.bpel
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation000.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation000.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,111 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<bpws:process
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns="http://sample.bpel.org/bpel/sampleArtifacts"
xmlns:tns="http://sample.bpel.org/bpel/sample"
exitOnStandardFault="yes" name="OnEventCorrelation000"
suppressJoinFailure="yes"
targetNamespace="http://sample.bpel.org/bpel/sample"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelationArtifacts.wsdl"
namespace="http://sample.bpel.org/bpel/sampleArtifacts"/>
+ <bpws:partnerLinks>
+ <bpws:partnerLink myRole="OnEventCorrelationProvider"
partnerRole="OnEventCorrelationProvider" name="client"
partnerLinkType="tns:OnEventCorrelation"/>
+ </bpws:partnerLinks>
+ <bpws:variables>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="input"/>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="output"/>
+ <bpws:variable type="xsd:string" name="s"/>
+ </bpws:variables>
+ <bpws:correlationSets>
+ <bpws:correlationSet name="CorrelationSet"
properties="ns:input"/>
+ </bpws:correlationSets>
+ <bpws:sequence name="main">
+ <bpws:receive createInstance="yes" operation="opInOut"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex1">
+ <bpws:correlations>
+ <bpws:correlation initiate="yes"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($input.payload, '-b')</bpws:from>
+ <bpws:to>$input.payload</bpws:to>
+ </bpws:copy>
+ <bpws:copy>
+ <bpws:from>'tIn1'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:invoke partnerLink="client" operation="opIn"
inputVariable="input"/>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'tIn2'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT2S'</bpws:for></bpws:wait>
+ <bpws:invoke partnerLink="client" operation="opIn"
inputVariable="input"/>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'tInOut3'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT2S'</bpws:for></bpws:wait>
+ <bpws:invoke partnerLink="client" operation="opInOut"
outputVariable="output" inputVariable="input"/>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$output.data</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'tInOut4'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT2S'</bpws:for></bpws:wait>
+ <bpws:invoke partnerLink="client" operation="opInOut"
outputVariable="output" inputVariable="input"/>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $output.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat('result-', $s)</bpws:from>
+ <bpws:to>$output.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="opInOut" partnerLink="client"
variable="output" messageExchange="mex1"/>
+
+ </bpws:sequence>
+</bpws:process>
+
+
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation001.bpel
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation001.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation001.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,111 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<bpws:process
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns="http://sample.bpel.org/bpel/sampleArtifacts"
xmlns:tns="http://sample.bpel.org/bpel/sample"
exitOnStandardFault="yes" name="OnEventCorrelation001"
suppressJoinFailure="yes"
targetNamespace="http://sample.bpel.org/bpel/sample"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelationArtifacts.wsdl"
namespace="http://sample.bpel.org/bpel/sampleArtifacts"/>
+ <bpws:partnerLinks>
+ <bpws:partnerLink myRole="OnEventCorrelationProvider"
partnerRole="OnEventCorrelationProvider" name="client"
partnerLinkType="tns:OnEventCorrelation"/>
+ </bpws:partnerLinks>
+ <bpws:variables>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="input"/>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="output"/>
+ <bpws:variable type="xsd:string" name="s"/>
+ </bpws:variables>
+ <bpws:correlationSets>
+ <bpws:correlationSet name="CorrelationSet"
properties="ns:input"/>
+ </bpws:correlationSets>
+ <bpws:sequence name="main">
+ <bpws:receive createInstance="yes" operation="opInOut"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex1">
+ <bpws:correlations>
+ <bpws:correlation initiate="yes"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($input.payload, '-b')</bpws:from>
+ <bpws:to>$input.payload</bpws:to>
+ </bpws:copy>
+ <bpws:copy>
+ <bpws:from>'tIn1'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:invoke partnerLink="client" operation="opIn"
inputVariable="input"/>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'tIn2'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT2S'</bpws:for></bpws:wait>
+ <bpws:invoke partnerLink="client" operation="opIn"
inputVariable="input"/>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'tInOut3'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT2S'</bpws:for></bpws:wait>
+ <bpws:invoke partnerLink="client" operation="opInOut"
outputVariable="output" inputVariable="input"/>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$output.data</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'tInOut4'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT2S'</bpws:for></bpws:wait>
+ <bpws:invoke partnerLink="client" operation="opInOut"
outputVariable="output" inputVariable="input"/>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $output.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat('result-', $s)</bpws:from>
+ <bpws:to>$output.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="opInOut" partnerLink="client"
variable="output" messageExchange="mex1"/>
+
+ </bpws:sequence>
+</bpws:process>
+
+
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation010.bpel
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation010.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation010.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,111 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<bpws:process
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns="http://sample.bpel.org/bpel/sampleArtifacts"
xmlns:tns="http://sample.bpel.org/bpel/sample"
exitOnStandardFault="yes" name="OnEventCorrelation010"
suppressJoinFailure="yes"
targetNamespace="http://sample.bpel.org/bpel/sample"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelationArtifacts.wsdl"
namespace="http://sample.bpel.org/bpel/sampleArtifacts"/>
+ <bpws:partnerLinks>
+ <bpws:partnerLink myRole="OnEventCorrelationProvider"
partnerRole="OnEventCorrelationProvider" name="client"
partnerLinkType="tns:OnEventCorrelation"/>
+ </bpws:partnerLinks>
+ <bpws:variables>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="input"/>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="output"/>
+ <bpws:variable type="xsd:string" name="s"/>
+ </bpws:variables>
+ <bpws:correlationSets>
+ <bpws:correlationSet name="CorrelationSet"
properties="ns:input"/>
+ </bpws:correlationSets>
+ <bpws:sequence name="main">
+ <bpws:receive createInstance="yes" operation="opInOut"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex1">
+ <bpws:correlations>
+ <bpws:correlation initiate="yes"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($input.payload, '-b')</bpws:from>
+ <bpws:to>$input.payload</bpws:to>
+ </bpws:copy>
+ <bpws:copy>
+ <bpws:from>'tIn1'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:invoke partnerLink="client" operation="opIn"
inputVariable="input"/>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'tIn2'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT2S'</bpws:for></bpws:wait>
+ <bpws:invoke partnerLink="client" operation="opIn"
inputVariable="input"/>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'tInOut3'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT2S'</bpws:for></bpws:wait>
+ <bpws:invoke partnerLink="client" operation="opInOut"
outputVariable="output" inputVariable="input"/>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$output.data</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'tInOut4'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT2S'</bpws:for></bpws:wait>
+ <bpws:invoke partnerLink="client" operation="opInOut"
outputVariable="output" inputVariable="input"/>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $output.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat('result-', $s)</bpws:from>
+ <bpws:to>$output.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="opInOut" partnerLink="client"
variable="output" messageExchange="mex1"/>
+
+ </bpws:sequence>
+</bpws:process>
+
+
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation011.bpel
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation011.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation011.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,111 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<bpws:process
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns="http://sample.bpel.org/bpel/sampleArtifacts"
xmlns:tns="http://sample.bpel.org/bpel/sample"
exitOnStandardFault="yes" name="OnEventCorrelation011"
suppressJoinFailure="yes"
targetNamespace="http://sample.bpel.org/bpel/sample"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelationArtifacts.wsdl"
namespace="http://sample.bpel.org/bpel/sampleArtifacts"/>
+ <bpws:partnerLinks>
+ <bpws:partnerLink myRole="OnEventCorrelationProvider"
partnerRole="OnEventCorrelationProvider" name="client"
partnerLinkType="tns:OnEventCorrelation"/>
+ </bpws:partnerLinks>
+ <bpws:variables>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="input"/>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="output"/>
+ <bpws:variable type="xsd:string" name="s"/>
+ </bpws:variables>
+ <bpws:correlationSets>
+ <bpws:correlationSet name="CorrelationSet"
properties="ns:input"/>
+ </bpws:correlationSets>
+ <bpws:sequence name="main">
+ <bpws:receive createInstance="yes" operation="opInOut"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex1">
+ <bpws:correlations>
+ <bpws:correlation initiate="yes"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($input.payload, '-b')</bpws:from>
+ <bpws:to>$input.payload</bpws:to>
+ </bpws:copy>
+ <bpws:copy>
+ <bpws:from>'tIn1'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:invoke partnerLink="client" operation="opIn"
inputVariable="input"/>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'tIn2'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT2S'</bpws:for></bpws:wait>
+ <bpws:invoke partnerLink="client" operation="opIn"
inputVariable="input"/>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'tInOut3'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT2S'</bpws:for></bpws:wait>
+ <bpws:invoke partnerLink="client" operation="opInOut"
outputVariable="output" inputVariable="input"/>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$output.data</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'tInOut4'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT2S'</bpws:for></bpws:wait>
+ <bpws:invoke partnerLink="client" operation="opInOut"
outputVariable="output" inputVariable="input"/>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $output.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat('result-', $s)</bpws:from>
+ <bpws:to>$output.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="opInOut" partnerLink="client"
variable="output" messageExchange="mex1"/>
+
+ </bpws:sequence>
+</bpws:process>
+
+
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation100.bpel
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation100.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation100.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,111 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<bpws:process
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns="http://sample.bpel.org/bpel/sampleArtifacts"
xmlns:tns="http://sample.bpel.org/bpel/sample"
exitOnStandardFault="yes" name="OnEventCorrelation100"
suppressJoinFailure="yes"
targetNamespace="http://sample.bpel.org/bpel/sample"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelationArtifacts.wsdl"
namespace="http://sample.bpel.org/bpel/sampleArtifacts"/>
+ <bpws:partnerLinks>
+ <bpws:partnerLink myRole="OnEventCorrelationProvider"
partnerRole="OnEventCorrelationProvider" name="client"
partnerLinkType="tns:OnEventCorrelation"/>
+ </bpws:partnerLinks>
+ <bpws:variables>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="input"/>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="output"/>
+ <bpws:variable type="xsd:string" name="s"/>
+ </bpws:variables>
+ <bpws:correlationSets>
+ <bpws:correlationSet name="CorrelationSet"
properties="ns:input"/>
+ </bpws:correlationSets>
+ <bpws:sequence name="main">
+ <bpws:receive createInstance="yes" operation="opInOut"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex1">
+ <bpws:correlations>
+ <bpws:correlation initiate="yes"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($input.payload, '-b')</bpws:from>
+ <bpws:to>$input.payload</bpws:to>
+ </bpws:copy>
+ <bpws:copy>
+ <bpws:from>'tIn1'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:invoke partnerLink="client" operation="opIn"
inputVariable="input"/>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'tIn2'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT2S'</bpws:for></bpws:wait>
+ <bpws:invoke partnerLink="client" operation="opIn"
inputVariable="input"/>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'tInOut3'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT2S'</bpws:for></bpws:wait>
+ <bpws:invoke partnerLink="client" operation="opInOut"
outputVariable="output" inputVariable="input"/>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$output.data</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'tInOut4'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT2S'</bpws:for></bpws:wait>
+ <bpws:invoke partnerLink="client" operation="opInOut"
outputVariable="output" inputVariable="input"/>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $output.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat('result-', $s)</bpws:from>
+ <bpws:to>$output.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="opInOut" partnerLink="client"
variable="output" messageExchange="mex1"/>
+
+ </bpws:sequence>
+</bpws:process>
+
+
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation101.bpel
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation101.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation101.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,111 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<bpws:process
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns="http://sample.bpel.org/bpel/sampleArtifacts"
xmlns:tns="http://sample.bpel.org/bpel/sample"
exitOnStandardFault="yes" name="OnEventCorrelation101"
suppressJoinFailure="yes"
targetNamespace="http://sample.bpel.org/bpel/sample"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelationArtifacts.wsdl"
namespace="http://sample.bpel.org/bpel/sampleArtifacts"/>
+ <bpws:partnerLinks>
+ <bpws:partnerLink myRole="OnEventCorrelationProvider"
partnerRole="OnEventCorrelationProvider" name="client"
partnerLinkType="tns:OnEventCorrelation"/>
+ </bpws:partnerLinks>
+ <bpws:variables>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="input"/>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="output"/>
+ <bpws:variable type="xsd:string" name="s"/>
+ </bpws:variables>
+ <bpws:correlationSets>
+ <bpws:correlationSet name="CorrelationSet"
properties="ns:input"/>
+ </bpws:correlationSets>
+ <bpws:sequence name="main">
+ <bpws:receive createInstance="yes" operation="opInOut"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex1">
+ <bpws:correlations>
+ <bpws:correlation initiate="yes"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($input.payload, '-b')</bpws:from>
+ <bpws:to>$input.payload</bpws:to>
+ </bpws:copy>
+ <bpws:copy>
+ <bpws:from>'tIn1'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:invoke partnerLink="client" operation="opIn"
inputVariable="input"/>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'tIn2'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT2S'</bpws:for></bpws:wait>
+ <bpws:invoke partnerLink="client" operation="opIn"
inputVariable="input"/>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'tInOut3'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT2S'</bpws:for></bpws:wait>
+ <bpws:invoke partnerLink="client" operation="opInOut"
outputVariable="output" inputVariable="input"/>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$output.data</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'tInOut4'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT2S'</bpws:for></bpws:wait>
+ <bpws:invoke partnerLink="client" operation="opInOut"
outputVariable="output" inputVariable="input"/>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $output.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat('result-', $s)</bpws:from>
+ <bpws:to>$output.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="opInOut" partnerLink="client"
variable="output" messageExchange="mex1"/>
+
+ </bpws:sequence>
+</bpws:process>
+
+
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation110.bpel
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation110.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation110.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,111 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<bpws:process
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns="http://sample.bpel.org/bpel/sampleArtifacts"
xmlns:tns="http://sample.bpel.org/bpel/sample"
exitOnStandardFault="yes" name="OnEventCorrelation110"
suppressJoinFailure="yes"
targetNamespace="http://sample.bpel.org/bpel/sample"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelationArtifacts.wsdl"
namespace="http://sample.bpel.org/bpel/sampleArtifacts"/>
+ <bpws:partnerLinks>
+ <bpws:partnerLink myRole="OnEventCorrelationProvider"
partnerRole="OnEventCorrelationProvider" name="client"
partnerLinkType="tns:OnEventCorrelation"/>
+ </bpws:partnerLinks>
+ <bpws:variables>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="input"/>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="output"/>
+ <bpws:variable type="xsd:string" name="s"/>
+ </bpws:variables>
+ <bpws:correlationSets>
+ <bpws:correlationSet name="CorrelationSet"
properties="ns:input"/>
+ </bpws:correlationSets>
+ <bpws:sequence name="main">
+ <bpws:receive createInstance="yes" operation="opInOut"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex1">
+ <bpws:correlations>
+ <bpws:correlation initiate="yes"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($input.payload, '-b')</bpws:from>
+ <bpws:to>$input.payload</bpws:to>
+ </bpws:copy>
+ <bpws:copy>
+ <bpws:from>'tIn1'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:invoke partnerLink="client" operation="opIn"
inputVariable="input"/>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'tIn2'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT2S'</bpws:for></bpws:wait>
+ <bpws:invoke partnerLink="client" operation="opIn"
inputVariable="input"/>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'tInOut3'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT2S'</bpws:for></bpws:wait>
+ <bpws:invoke partnerLink="client" operation="opInOut"
outputVariable="output" inputVariable="input"/>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$output.data</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'tInOut4'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT2S'</bpws:for></bpws:wait>
+ <bpws:invoke partnerLink="client" operation="opInOut"
outputVariable="output" inputVariable="input"/>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $output.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat('result-', $s)</bpws:from>
+ <bpws:to>$output.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="opInOut" partnerLink="client"
variable="output" messageExchange="mex1"/>
+
+ </bpws:sequence>
+</bpws:process>
+
+
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation111.bpel
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation111.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelation111.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,111 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<bpws:process
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns="http://sample.bpel.org/bpel/sampleArtifacts"
xmlns:tns="http://sample.bpel.org/bpel/sample"
exitOnStandardFault="yes" name="OnEventCorrelation111"
suppressJoinFailure="yes"
targetNamespace="http://sample.bpel.org/bpel/sample"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelationArtifacts.wsdl"
namespace="http://sample.bpel.org/bpel/sampleArtifacts"/>
+ <bpws:partnerLinks>
+ <bpws:partnerLink myRole="OnEventCorrelationProvider"
partnerRole="OnEventCorrelationProvider" name="client"
partnerLinkType="tns:OnEventCorrelation"/>
+ </bpws:partnerLinks>
+ <bpws:variables>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="input"/>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="output"/>
+ <bpws:variable type="xsd:string" name="s"/>
+ </bpws:variables>
+ <bpws:correlationSets>
+ <bpws:correlationSet name="CorrelationSet"
properties="ns:input"/>
+ </bpws:correlationSets>
+ <bpws:sequence name="main">
+ <bpws:receive createInstance="yes" operation="opInOut"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex1">
+ <bpws:correlations>
+ <bpws:correlation initiate="yes"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($input.payload, '-b')</bpws:from>
+ <bpws:to>$input.payload</bpws:to>
+ </bpws:copy>
+ <bpws:copy>
+ <bpws:from>'tIn1'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:invoke partnerLink="client" operation="opIn"
inputVariable="input"/>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'tIn2'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT2S'</bpws:for></bpws:wait>
+ <bpws:invoke partnerLink="client" operation="opIn"
inputVariable="input"/>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'tInOut3'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT2S'</bpws:for></bpws:wait>
+ <bpws:invoke partnerLink="client" operation="opInOut"
outputVariable="output" inputVariable="input"/>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$output.data</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'tInOut4'</bpws:from>
+ <bpws:to>$input.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT2S'</bpws:for></bpws:wait>
+ <bpws:invoke partnerLink="client" operation="opInOut"
outputVariable="output" inputVariable="input"/>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $output.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat('result-', $s)</bpws:from>
+ <bpws:to>$output.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="opInOut" partnerLink="client"
variable="output" messageExchange="mex1"/>
+
+ </bpws:sequence>
+</bpws:process>
+
+
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationArtifacts.wsdl
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationArtifacts.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationArtifacts.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns:tns="http://sample.bpel.org/bpel/sampleArtifacts"
+
xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop"
+
xmlns:xs="http://www.w3.org/2001/XMLSchema"
+
xmlns:bpel="http://sample.bpel.org/bpel/sample"
+ name="OnEventCorrelationArtifacts"
+
targetNamespace="http://sample.bpel.org/bpel/sampleArtifacts"
+
xmlns="http://schemas.xmlsoap.org/wsdl/"
+ >
+<vprop:property name="input" type="xs:string"/>
+<vprop:propertyAlias messageType="bpel:OnEventCorrelationMessage"
part="payload" propertyName="tns:input">
+<!--vprop:query><![CDATA[bpel:input]]></vprop:query-->
+</vprop:propertyAlias>
+<import location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+</definitions>
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB000.bpel
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB000.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB000.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,111 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<bpws:process
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns="http://sample.bpel.org/bpel/sampleArtifacts"
xmlns:tns="http://sample.bpel.org/bpel/sample"
exitOnStandardFault="yes" name="OnEventCorrelationB000"
suppressJoinFailure="yes"
targetNamespace="http://sample.bpel.org/bpel/sample"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelationArtifacts.wsdl"
namespace="http://sample.bpel.org/bpel/sampleArtifacts"/>
+ <bpws:partnerLinks>
+ <bpws:partnerLink myRole="OnEventCorrelationProvider"
name="client" partnerLinkType="tns:OnEventCorrelation"/>
+ </bpws:partnerLinks>
+ <bpws:variables>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="input"/>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="output"/>
+ <bpws:variable type="xsd:string" name="s"/>
+ </bpws:variables>
+ <bpws:correlationSets>
+ <bpws:correlationSet name="CorrelationSet"
properties="ns:input"/>
+ </bpws:correlationSets>
+ <bpws:sequence name="main">
+
+ <bpws:receive createInstance="yes" operation="opIn"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input">
+ <bpws:correlations>
+ <bpws:correlation initiate="yes"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$input.data</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT1S'</bpws:for></bpws:wait>
+
+ <bpws:receive createInstance="no" operation="opIn"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input">
+ <bpws:correlations>
+ <bpws:correlation initiate="no" set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $input.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT1S'</bpws:for></bpws:wait>
+
+ <bpws:receive createInstance="no" operation="opInOut"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex1">
+ <bpws:correlations>
+ <bpws:correlation initiate="no" set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $input.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$input.payload</bpws:from>
+ <bpws:to>$output.payload</bpws:to>
+ </bpws:copy>
+ <bpws:copy>
+ <bpws:from>'r1'</bpws:from>
+ <bpws:to>$output.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="opInOut" partnerLink="client"
variable="output" messageExchange="mex1"/>
+
+ <bpws:wait><bpws:for>'PT1S'</bpws:for></bpws:wait>
+
+ <bpws:receive createInstance="no" operation="opInOut"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex2">
+ <bpws:correlations>
+ <bpws:correlation initiate="no" set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $input.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$s</bpws:from>
+ <bpws:to>$output.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="opInOut" partnerLink="client"
variable="output" messageExchange="mex2"/>
+ </bpws:sequence>
+</bpws:process>
+
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB001.bpel
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB001.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB001.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,111 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<bpws:process
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns="http://sample.bpel.org/bpel/sampleArtifacts"
xmlns:tns="http://sample.bpel.org/bpel/sample"
exitOnStandardFault="yes" name="OnEventCorrelationB001"
suppressJoinFailure="yes"
targetNamespace="http://sample.bpel.org/bpel/sample"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelationArtifacts.wsdl"
namespace="http://sample.bpel.org/bpel/sampleArtifacts"/>
+ <bpws:partnerLinks>
+ <bpws:partnerLink myRole="OnEventCorrelationProvider"
name="client" partnerLinkType="tns:OnEventCorrelation"/>
+ </bpws:partnerLinks>
+ <bpws:variables>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="input"/>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="output"/>
+ <bpws:variable type="xsd:string" name="s"/>
+ </bpws:variables>
+ <bpws:correlationSets>
+ <bpws:correlationSet name="CorrelationSet"
properties="ns:input"/>
+ </bpws:correlationSets>
+ <bpws:sequence name="main">
+
+ <bpws:receive createInstance="yes" operation="opIn"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input">
+ <bpws:correlations>
+ <bpws:correlation initiate="yes"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$input.data</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT1S'</bpws:for></bpws:wait>
+
+ <bpws:receive createInstance="no" operation="opIn"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input">
+ <bpws:correlations>
+ <bpws:correlation initiate="no" set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $input.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT1S'</bpws:for></bpws:wait>
+
+ <bpws:receive createInstance="no" operation="opInOut"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex1">
+ <bpws:correlations>
+ <bpws:correlation initiate="no" set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $input.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$input.payload</bpws:from>
+ <bpws:to>$output.payload</bpws:to>
+ </bpws:copy>
+ <bpws:copy>
+ <bpws:from>'r1'</bpws:from>
+ <bpws:to>$output.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="opInOut" partnerLink="client"
variable="output" messageExchange="mex1"/>
+
+ <bpws:wait><bpws:for>'PT1S'</bpws:for></bpws:wait>
+
+ <bpws:receive createInstance="no" operation="opInOut"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex2">
+ <bpws:correlations>
+ <bpws:correlation initiate="no" set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $input.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$s</bpws:from>
+ <bpws:to>$output.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="opInOut" partnerLink="client"
variable="output" messageExchange="mex2"/>
+ </bpws:sequence>
+</bpws:process>
+
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB010.bpel
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB010.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB010.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,111 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<bpws:process
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns="http://sample.bpel.org/bpel/sampleArtifacts"
xmlns:tns="http://sample.bpel.org/bpel/sample"
exitOnStandardFault="yes" name="OnEventCorrelationB010"
suppressJoinFailure="yes"
targetNamespace="http://sample.bpel.org/bpel/sample"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelationArtifacts.wsdl"
namespace="http://sample.bpel.org/bpel/sampleArtifacts"/>
+ <bpws:partnerLinks>
+ <bpws:partnerLink myRole="OnEventCorrelationProvider"
name="client" partnerLinkType="tns:OnEventCorrelation"/>
+ </bpws:partnerLinks>
+ <bpws:variables>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="input"/>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="output"/>
+ <bpws:variable type="xsd:string" name="s"/>
+ </bpws:variables>
+ <bpws:correlationSets>
+ <bpws:correlationSet name="CorrelationSet"
properties="ns:input"/>
+ </bpws:correlationSets>
+ <bpws:sequence name="main">
+
+ <bpws:receive createInstance="yes" operation="opIn"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input">
+ <bpws:correlations>
+ <bpws:correlation initiate="yes"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$input.data</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT1S'</bpws:for></bpws:wait>
+
+ <bpws:receive createInstance="no" operation="opIn"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input">
+ <bpws:correlations>
+ <bpws:correlation initiate="no" set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $input.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT1S'</bpws:for></bpws:wait>
+
+ <bpws:receive createInstance="no" operation="opInOut"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex1">
+ <bpws:correlations>
+ <bpws:correlation initiate="no" set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $input.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$input.payload</bpws:from>
+ <bpws:to>$output.payload</bpws:to>
+ </bpws:copy>
+ <bpws:copy>
+ <bpws:from>'r1'</bpws:from>
+ <bpws:to>$output.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="opInOut" partnerLink="client"
variable="output" messageExchange="mex1"/>
+
+ <bpws:wait><bpws:for>'PT1S'</bpws:for></bpws:wait>
+
+ <bpws:receive createInstance="no" operation="opInOut"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex2">
+ <bpws:correlations>
+ <bpws:correlation initiate="no" set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $input.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$s</bpws:from>
+ <bpws:to>$output.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="opInOut" partnerLink="client"
variable="output" messageExchange="mex2"/>
+ </bpws:sequence>
+</bpws:process>
+
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB011.bpel
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB011.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB011.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,111 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<bpws:process
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns="http://sample.bpel.org/bpel/sampleArtifacts"
xmlns:tns="http://sample.bpel.org/bpel/sample"
exitOnStandardFault="yes" name="OnEventCorrelationB011"
suppressJoinFailure="yes"
targetNamespace="http://sample.bpel.org/bpel/sample"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelationArtifacts.wsdl"
namespace="http://sample.bpel.org/bpel/sampleArtifacts"/>
+ <bpws:partnerLinks>
+ <bpws:partnerLink myRole="OnEventCorrelationProvider"
name="client" partnerLinkType="tns:OnEventCorrelation"/>
+ </bpws:partnerLinks>
+ <bpws:variables>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="input"/>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="output"/>
+ <bpws:variable type="xsd:string" name="s"/>
+ </bpws:variables>
+ <bpws:correlationSets>
+ <bpws:correlationSet name="CorrelationSet"
properties="ns:input"/>
+ </bpws:correlationSets>
+ <bpws:sequence name="main">
+
+ <bpws:receive createInstance="yes" operation="opIn"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input">
+ <bpws:correlations>
+ <bpws:correlation initiate="yes"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$input.data</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT1S'</bpws:for></bpws:wait>
+
+ <bpws:receive createInstance="no" operation="opIn"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input">
+ <bpws:correlations>
+ <bpws:correlation initiate="no" set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $input.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT1S'</bpws:for></bpws:wait>
+
+ <bpws:receive createInstance="no" operation="opInOut"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex1">
+ <bpws:correlations>
+ <bpws:correlation initiate="no" set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $input.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$input.payload</bpws:from>
+ <bpws:to>$output.payload</bpws:to>
+ </bpws:copy>
+ <bpws:copy>
+ <bpws:from>'r1'</bpws:from>
+ <bpws:to>$output.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="opInOut" partnerLink="client"
variable="output" messageExchange="mex1"/>
+
+ <bpws:wait><bpws:for>'PT1S'</bpws:for></bpws:wait>
+
+ <bpws:receive createInstance="no" operation="opInOut"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex2">
+ <bpws:correlations>
+ <bpws:correlation initiate="no" set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $input.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$s</bpws:from>
+ <bpws:to>$output.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="opInOut" partnerLink="client"
variable="output" messageExchange="mex2"/>
+ </bpws:sequence>
+</bpws:process>
+
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB100.bpel
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB100.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB100.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,111 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<bpws:process
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns="http://sample.bpel.org/bpel/sampleArtifacts"
xmlns:tns="http://sample.bpel.org/bpel/sample"
exitOnStandardFault="yes" name="OnEventCorrelationB100"
suppressJoinFailure="yes"
targetNamespace="http://sample.bpel.org/bpel/sample"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelationArtifacts.wsdl"
namespace="http://sample.bpel.org/bpel/sampleArtifacts"/>
+ <bpws:partnerLinks>
+ <bpws:partnerLink myRole="OnEventCorrelationProvider"
name="client" partnerLinkType="tns:OnEventCorrelation"/>
+ </bpws:partnerLinks>
+ <bpws:variables>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="input"/>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="output"/>
+ <bpws:variable type="xsd:string" name="s"/>
+ </bpws:variables>
+ <bpws:correlationSets>
+ <bpws:correlationSet name="CorrelationSet"
properties="ns:input"/>
+ </bpws:correlationSets>
+ <bpws:sequence name="main">
+
+ <bpws:receive createInstance="yes" operation="opIn"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input">
+ <bpws:correlations>
+ <bpws:correlation initiate="yes"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$input.data</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT1S'</bpws:for></bpws:wait>
+
+ <bpws:receive createInstance="no" operation="opIn"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input">
+ <bpws:correlations>
+ <bpws:correlation initiate="no" set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $input.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT1S'</bpws:for></bpws:wait>
+
+ <bpws:receive createInstance="no" operation="opInOut"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex1">
+ <bpws:correlations>
+ <bpws:correlation initiate="no" set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $input.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$input.payload</bpws:from>
+ <bpws:to>$output.payload</bpws:to>
+ </bpws:copy>
+ <bpws:copy>
+ <bpws:from>'r1'</bpws:from>
+ <bpws:to>$output.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="opInOut" partnerLink="client"
variable="output" messageExchange="mex1"/>
+
+ <bpws:wait><bpws:for>'PT1S'</bpws:for></bpws:wait>
+
+ <bpws:receive createInstance="no" operation="opInOut"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex2">
+ <bpws:correlations>
+ <bpws:correlation initiate="no" set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $input.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$s</bpws:from>
+ <bpws:to>$output.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="opInOut" partnerLink="client"
variable="output" messageExchange="mex2"/>
+ </bpws:sequence>
+</bpws:process>
+
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB101.bpel
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB101.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB101.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,111 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<bpws:process
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns="http://sample.bpel.org/bpel/sampleArtifacts"
xmlns:tns="http://sample.bpel.org/bpel/sample"
exitOnStandardFault="yes" name="OnEventCorrelationB101"
suppressJoinFailure="yes"
targetNamespace="http://sample.bpel.org/bpel/sample"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelationArtifacts.wsdl"
namespace="http://sample.bpel.org/bpel/sampleArtifacts"/>
+ <bpws:partnerLinks>
+ <bpws:partnerLink myRole="OnEventCorrelationProvider"
name="client" partnerLinkType="tns:OnEventCorrelation"/>
+ </bpws:partnerLinks>
+ <bpws:variables>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="input"/>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="output"/>
+ <bpws:variable type="xsd:string" name="s"/>
+ </bpws:variables>
+ <bpws:correlationSets>
+ <bpws:correlationSet name="CorrelationSet"
properties="ns:input"/>
+ </bpws:correlationSets>
+ <bpws:sequence name="main">
+
+ <bpws:receive createInstance="yes" operation="opIn"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input">
+ <bpws:correlations>
+ <bpws:correlation initiate="yes"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$input.data</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT1S'</bpws:for></bpws:wait>
+
+ <bpws:receive createInstance="no" operation="opIn"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input">
+ <bpws:correlations>
+ <bpws:correlation initiate="no" set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $input.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT1S'</bpws:for></bpws:wait>
+
+ <bpws:receive createInstance="no" operation="opInOut"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex1">
+ <bpws:correlations>
+ <bpws:correlation initiate="no" set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $input.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$input.payload</bpws:from>
+ <bpws:to>$output.payload</bpws:to>
+ </bpws:copy>
+ <bpws:copy>
+ <bpws:from>'r1'</bpws:from>
+ <bpws:to>$output.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="opInOut" partnerLink="client"
variable="output" messageExchange="mex1"/>
+
+ <bpws:wait><bpws:for>'PT1S'</bpws:for></bpws:wait>
+
+ <bpws:receive createInstance="no" operation="opInOut"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex2">
+ <bpws:correlations>
+ <bpws:correlation initiate="no" set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $input.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$s</bpws:from>
+ <bpws:to>$output.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="opInOut" partnerLink="client"
variable="output" messageExchange="mex2"/>
+ </bpws:sequence>
+</bpws:process>
+
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB110.bpel
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB110.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB110.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,111 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<bpws:process
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns="http://sample.bpel.org/bpel/sampleArtifacts"
xmlns:tns="http://sample.bpel.org/bpel/sample"
exitOnStandardFault="yes" name="OnEventCorrelationB110"
suppressJoinFailure="yes"
targetNamespace="http://sample.bpel.org/bpel/sample"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelationArtifacts.wsdl"
namespace="http://sample.bpel.org/bpel/sampleArtifacts"/>
+ <bpws:partnerLinks>
+ <bpws:partnerLink myRole="OnEventCorrelationProvider"
name="client" partnerLinkType="tns:OnEventCorrelation"/>
+ </bpws:partnerLinks>
+ <bpws:variables>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="input"/>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="output"/>
+ <bpws:variable type="xsd:string" name="s"/>
+ </bpws:variables>
+ <bpws:correlationSets>
+ <bpws:correlationSet name="CorrelationSet"
properties="ns:input"/>
+ </bpws:correlationSets>
+ <bpws:sequence name="main">
+
+ <bpws:receive createInstance="yes" operation="opIn"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input">
+ <bpws:correlations>
+ <bpws:correlation initiate="yes"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$input.data</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT1S'</bpws:for></bpws:wait>
+
+ <bpws:receive createInstance="no" operation="opIn"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input">
+ <bpws:correlations>
+ <bpws:correlation initiate="no" set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $input.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT1S'</bpws:for></bpws:wait>
+
+ <bpws:receive createInstance="no" operation="opInOut"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex1">
+ <bpws:correlations>
+ <bpws:correlation initiate="no" set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $input.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$input.payload</bpws:from>
+ <bpws:to>$output.payload</bpws:to>
+ </bpws:copy>
+ <bpws:copy>
+ <bpws:from>'r1'</bpws:from>
+ <bpws:to>$output.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="opInOut" partnerLink="client"
variable="output" messageExchange="mex1"/>
+
+ <bpws:wait><bpws:for>'PT1S'</bpws:for></bpws:wait>
+
+ <bpws:receive createInstance="no" operation="opInOut"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex2">
+ <bpws:correlations>
+ <bpws:correlation initiate="no" set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $input.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$s</bpws:from>
+ <bpws:to>$output.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="opInOut" partnerLink="client"
variable="output" messageExchange="mex2"/>
+ </bpws:sequence>
+</bpws:process>
+
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB111.bpel
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB111.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/OnEventCorrelationB111.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,111 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<bpws:process
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns="http://sample.bpel.org/bpel/sampleArtifacts"
xmlns:tns="http://sample.bpel.org/bpel/sample"
exitOnStandardFault="yes" name="OnEventCorrelationB111"
suppressJoinFailure="yes"
targetNamespace="http://sample.bpel.org/bpel/sample"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelationArtifacts.wsdl"
namespace="http://sample.bpel.org/bpel/sampleArtifacts"/>
+ <bpws:partnerLinks>
+ <bpws:partnerLink myRole="OnEventCorrelationProvider"
name="client" partnerLinkType="tns:OnEventCorrelation"/>
+ </bpws:partnerLinks>
+ <bpws:variables>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="input"/>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="output"/>
+ <bpws:variable type="xsd:string" name="s"/>
+ </bpws:variables>
+ <bpws:correlationSets>
+ <bpws:correlationSet name="CorrelationSet"
properties="ns:input"/>
+ </bpws:correlationSets>
+ <bpws:sequence name="main">
+
+ <bpws:receive createInstance="yes" operation="opIn"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input">
+ <bpws:correlations>
+ <bpws:correlation initiate="yes"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$input.data</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT1S'</bpws:for></bpws:wait>
+
+ <bpws:receive createInstance="no" operation="opIn"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input">
+ <bpws:correlations>
+ <bpws:correlation initiate="no" set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $input.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:wait><bpws:for>'PT1S'</bpws:for></bpws:wait>
+
+ <bpws:receive createInstance="no" operation="opInOut"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex1">
+ <bpws:correlations>
+ <bpws:correlation initiate="no" set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $input.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$input.payload</bpws:from>
+ <bpws:to>$output.payload</bpws:to>
+ </bpws:copy>
+ <bpws:copy>
+ <bpws:from>'r1'</bpws:from>
+ <bpws:to>$output.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="opInOut" partnerLink="client"
variable="output" messageExchange="mex1"/>
+
+ <bpws:wait><bpws:for>'PT1S'</bpws:for></bpws:wait>
+
+ <bpws:receive createInstance="no" operation="opInOut"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex2">
+ <bpws:correlations>
+ <bpws:correlation initiate="no" set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat($s, $input.data)</bpws:from>
+ <bpws:to>$s</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$s</bpws:from>
+ <bpws:to>$output.data</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="opInOut" partnerLink="client"
variable="output" messageExchange="mex2"/>
+ </bpws:sequence>
+</bpws:process>
+
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/deploy.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/deploy.xml
(rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/deploy.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,176 @@
+<?xml version='1.0' encoding='UTF-8'?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<dd:deploy
xmlns:dd="http://www.apache.org/ode/schemas/dd/2007/03"
+
xmlns:bpel="http://sample.bpel.org/bpel/sample"
+ >
+
+
+ <dd:process name="bpel:OnEventCorrelation000"
fileName="OnEventCorrelation000.bpel">
+ <!--dd:process-events generate="none"/-->
+ <dd:in-memory>false</dd:in-memory>
+ <dd:provide partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelation000"
port="OnEventCorrelation" />
+ </dd:provide>
+ <dd:invoke partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelationB000"
port="OnEventCorrelationB" />
+ </dd:invoke>
+ </dd:process>
+ <dd:process name="bpel:OnEventCorrelationB000"
fileName="OnEventCorrelationB000.bpel">
+ <dd:in-memory>false</dd:in-memory>
+ <dd:provide partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelationB000"
port="OnEventCorrelationB" />
+ </dd:provide>
+ </dd:process>
+
+ <dd:process name="bpel:OnEventCorrelation100"
fileName="OnEventCorrelation100.bpel">
+ <!--dd:process-events generate="none"/-->
+ <dd:in-memory>true</dd:in-memory>
+ <dd:provide partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelation100"
port="OnEventCorrelation" />
+ </dd:provide>
+ <dd:invoke partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelationB100"
port="OnEventCorrelationB" />
+ </dd:invoke>
+ </dd:process>
+ <dd:process name="bpel:OnEventCorrelationB100"
fileName="OnEventCorrelationB100.bpel">
+ <dd:in-memory>false</dd:in-memory>
+ <dd:provide partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelationB100"
port="OnEventCorrelationB" />
+ </dd:provide>
+ </dd:process>
+
+ <dd:process name="bpel:OnEventCorrelation010"
fileName="OnEventCorrelation010.bpel">
+ <!--dd:process-events generate="none"/-->
+ <dd:in-memory>false</dd:in-memory>
+ <dd:provide partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelation010"
port="OnEventCorrelation" />
+ </dd:provide>
+ <dd:invoke partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelationB010Fwd"
port="OnEventCorrelationB" />
+ </dd:invoke>
+ </dd:process>
+ <dd:process name="bpel:OnEventCorrelationB010"
fileName="OnEventCorrelationB010.bpel">
+ <dd:in-memory>false</dd:in-memory>
+ <dd:provide partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelationB010"
port="OnEventCorrelationB" />
+ </dd:provide>
+ </dd:process>
+
+ <dd:process name="bpel:OnEventCorrelation110"
fileName="OnEventCorrelation110.bpel">
+ <!--dd:process-events generate="none"/-->
+ <dd:in-memory>true</dd:in-memory>
+ <dd:provide partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelation110"
port="OnEventCorrelation" />
+ </dd:provide>
+ <dd:invoke partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelationB110Fwd"
port="OnEventCorrelationB" />
+ </dd:invoke>
+ </dd:process>
+ <dd:process name="bpel:OnEventCorrelationB110"
fileName="OnEventCorrelationB110.bpel">
+ <dd:in-memory>false</dd:in-memory>
+ <dd:provide partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelationB110"
port="OnEventCorrelationB" />
+ </dd:provide>
+ </dd:process>
+
+ <dd:process name="bpel:OnEventCorrelation001"
fileName="OnEventCorrelation001.bpel">
+ <!--dd:process-events generate="none"/-->
+ <dd:in-memory>false</dd:in-memory>
+ <dd:provide partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelation001"
port="OnEventCorrelation" />
+ </dd:provide>
+ <dd:invoke partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelationB001"
port="OnEventCorrelationB" />
+ </dd:invoke>
+ </dd:process>
+ <dd:process name="bpel:OnEventCorrelationB001"
fileName="OnEventCorrelationB001.bpel">
+ <dd:in-memory>true</dd:in-memory>
+ <dd:provide partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelationB001"
port="OnEventCorrelationB" />
+ </dd:provide>
+ </dd:process>
+
+ <dd:process name="bpel:OnEventCorrelation101"
fileName="OnEventCorrelation101.bpel">
+ <!--dd:process-events generate="none"/-->
+ <dd:in-memory>true</dd:in-memory>
+ <dd:provide partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelation101"
port="OnEventCorrelation" />
+ </dd:provide>
+ <dd:invoke partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelationB101"
port="OnEventCorrelationB" />
+ </dd:invoke>
+ </dd:process>
+ <dd:process name="bpel:OnEventCorrelationB101"
fileName="OnEventCorrelationB101.bpel">
+ <dd:in-memory>true</dd:in-memory>
+ <dd:provide partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelationB101"
port="OnEventCorrelationB" />
+ </dd:provide>
+ </dd:process>
+
+ <dd:process name="bpel:OnEventCorrelation011"
fileName="OnEventCorrelation011.bpel">
+ <!--dd:process-events generate="none"/-->
+ <dd:in-memory>false</dd:in-memory>
+ <dd:provide partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelation011"
port="OnEventCorrelation" />
+ </dd:provide>
+ <dd:invoke partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelationB011Fwd"
port="OnEventCorrelationB" />
+ </dd:invoke>
+ </dd:process>
+ <dd:process name="bpel:OnEventCorrelationB011"
fileName="OnEventCorrelationB011.bpel">
+ <dd:in-memory>true</dd:in-memory>
+ <dd:provide partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelationB011"
port="OnEventCorrelationB" />
+ </dd:provide>
+ </dd:process>
+
+ <dd:process name="bpel:OnEventCorrelation111"
fileName="OnEventCorrelation111.bpel">
+ <!--dd:process-events generate="none"/-->
+ <dd:in-memory>true</dd:in-memory>
+ <dd:provide partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelation111"
port="OnEventCorrelation" />
+ </dd:provide>
+ <dd:invoke partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelationB111Fwd"
port="OnEventCorrelationB" />
+ </dd:invoke>
+ </dd:process>
+ <dd:process name="bpel:OnEventCorrelationB111"
fileName="OnEventCorrelationB111.bpel">
+ <dd:in-memory>true</dd:in-memory>
+ <dd:provide partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelationB111"
port="OnEventCorrelationB" />
+ </dd:provide>
+ </dd:process>
+
+
+ <dd:process name="bpel:EPRTest" fileName="EPRTest.bpel">
+ <!--dd:process-events generate="none"/-->
+ <dd:provide partnerLink="client">
+ <dd:service name="bpel:EPRTest" port="default" />
+ </dd:provide>
+ </dd:process>
+
+ <dd:process name="bpel:EPRTest2" fileName="EPRTest2.bpel">
+ <dd:provide partnerLink="client">
+ <dd:service name="bpel:EPRTest2" port="default" />
+ </dd:provide>
+ </dd:process>
+
+</dd:deploy>
+
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/smx.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/smx.xml
(rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/smx.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,110 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+
http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+-->
+<beans
xmlns:sm="http://servicemix.apache.org/config/1.0"
+
xmlns:http="http://servicemix.apache.org/http/1.0"
+
xmlns:eip="http://servicemix.apache.org/eip/1.0"
+
xmlns:util="http://www.springframework.org/schema/util"
+
xmlns:jencks="http://jencks.org/2.0"
+ xmlns:mws="http://ode/bpel/unit-test.wsdl"
+ xmlns:ws="http://playmobile.pl/process/mnpm/portIn"
+ xmlns:sem="http://playmobile.pl/service/mnpm"
+
xmlns:bpel="http://sample.bpel.org/bpel/sample"
+ >
+
+ <util:map id="jndiEntries">
+ <entry key="java:comp/env/jdbc/ode"
value-ref="odeDS"/>
+ </util:map>
+
+ <sm:container
+ id="jbi"
+ embedded="true"
+ rootDir="target/test/smx"
+ transactionManager="#transactionManager"
+ depends-on="jndi"
+
+ <sm:activationSpecs>
+ <sm:activationSpec id="ms-eip">
+ <sm:component>
+ <eip:component>
+ <eip:endpoints>
+ <eip:content-based-router service="bpel:OnEventCorrelationB010Fwd"
endpoint="OnEventCorrelationB" forwardOperation="true">
+ <eip:rules>
+ <eip:routing-rule>
+ <eip:target>
+ <eip:exchange-target service="bpel:OnEventCorrelationB010"/>
+ </eip:target>
+ </eip:routing-rule>
+ </eip:rules>
+ </eip:content-based-router>
+
+ <eip:content-based-router service="bpel:OnEventCorrelationB110Fwd"
endpoint="OnEventCorrelationB" forwardOperation="true">
+ <eip:rules>
+ <eip:routing-rule>
+ <eip:target>
+ <eip:exchange-target service="bpel:OnEventCorrelationB110"/>
+ </eip:target>
+ </eip:routing-rule>
+ </eip:rules>
+ </eip:content-based-router>
+
+ <eip:content-based-router service="bpel:OnEventCorrelationB011Fwd"
endpoint="OnEventCorrelationB" forwardOperation="true">
+ <eip:rules>
+ <eip:routing-rule>
+ <eip:target>
+ <eip:exchange-target service="bpel:OnEventCorrelationB011"/>
+ </eip:target>
+ </eip:routing-rule>
+ </eip:rules>
+ </eip:content-based-router>
+
+ <eip:content-based-router service="bpel:OnEventCorrelationB111Fwd"
endpoint="OnEventCorrelationB" forwardOperation="true">
+ <eip:rules>
+ <eip:routing-rule>
+ <eip:target>
+ <eip:exchange-target service="bpel:OnEventCorrelationB111"/>
+ </eip:target>
+ </eip:routing-rule>
+ </eip:rules>
+ </eip:content-based-router>
+
+
+ </eip:endpoints>
+ </eip:component>
+ </sm:component>
+ </sm:activationSpec>
+ <sm:activationSpec id="http">
+ <sm:component>
+ <http:component>
+ <http:endpoints>
+ <http:endpoint
+ service="bpel:EPRTest2"
+ endpoint="http"
+ role="consumer"
+ locationURI="http://localhost:8198/EPRTest2/"
+
defaultMep="http://www.w3.org/2004/08/wsdl/in-out"
+ defaultOperation="opInOut"
+ soap="true" />
+ </http:endpoints>
+ </http:component>
+ </sm:component>
+ </sm:activationSpec>
+ </sm:activationSpecs>
+ </sm:container>
+</beans>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/test.properties
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/test.properties
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/CommunicationJbiTest/test.properties 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,27 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+#
http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+1nmr.service={http://sample.bpel.org/bpel/sample}OnEventCorrelation010
+1nmr.operation=opInOut
+1request=<msg><payload>abc3-010</payload><data>t3-010</data></msg>
+1response=.*result-r1tIn1tIn2tInOut3tInOut4.*
+
+2nmr.service={http://sample.bpel.org/bpel/sample}EPRTest
+2nmr.operation=opInOut
+2request=<msg><payload>test</payload><data>EPRTest</data></msg>
+2response=.*EPRTest-EPRTest2-EPRTest2.*
+
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/smx.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/smx.xml
(rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/smx.xml 2010-04-14 18:25:55
UTC (rev 620)
@@ -0,0 +1,40 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+
http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+-->
+<beans
xmlns:sm="http://servicemix.apache.org/config/1.0"
+
xmlns:http="http://servicemix.apache.org/http/1.0"
+
xmlns:eip="http://servicemix.apache.org/eip/1.0"
+
xmlns:util="http://www.springframework.org/schema/util"
+
xmlns:jencks="http://jencks.org/2.0"
+ xmlns:mws="http://ode/bpel/unit-test.wsdl"
+ >
+
+ <util:map id="jndiEntries">
+ <entry key="java:comp/env/jdbc/ode"
value-ref="odeDS"/>
+ </util:map>
+
+ <sm:container
+ id="jbi"
+ embedded="true"
+ rootDir="target/test/smx"
+ transactionManager="#transactionManager"
+ depends-on="jndi"
+
+ </sm:container>
+</beans>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/test.properties
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/test.properties
(rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/test.properties 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,47 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+#
http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+manualDeploy=true
+
+1deploy=v1-1
+
+2nmr.service={http://sample.bpel.org/bpel/sample}OnEventCorrelation
+2nmr.operation=initiate
+2request=<msg><payload>test</payload><payload2/></msg>
+2response=.*test1.*
+
+3nmr.service={http://sample.bpel.org/bpel/sample}OnEventCorrelation
+3nmr.operation=complete
+3request=<msg><payload>test</payload><payload2/></msg>
+3response=.*test3-old.*
+
+4nmr.service={http://sample.bpel.org/bpel/sample}OnEventCorrelation
+4nmr.operation=initiate
+4request=<msg><payload>test</payload><payload2/></msg>
+4response=.*test1.*
+
+5undeploy=v1-1
+
+6deploy=v2-1
+
+7nmr.service={http://sample.bpel.org/bpel/sample}OnEventCorrelation
+7nmr.operation=complete
+7request=<msg><payload>test</payload><payload2/></msg>
+7response=.*test3-new.*
+
+8undeploy=v2-1
+
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v1-1/OnEventCorrelation.bpel
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v1-1/OnEventCorrelation.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v1-1/OnEventCorrelation.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,68 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<bpws:process
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns="http://sample.bpel.org/bpel/sampleArtifacts"
xmlns:tns="http://sample.bpel.org/bpel/sample"
exitOnStandardFault="yes" name="OnEventCorrelation"
suppressJoinFailure="yes"
targetNamespace="http://sample.bpel.org/bpel/sample"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelationArtifacts.wsdl"
namespace="http://sample.bpel.org/bpel/sampleArtifacts"/>
+ <bpws:partnerLinks>
+ <bpws:partnerLink myRole="OnEventCorrelationProvider"
name="client" partnerLinkType="tns:OnEventCorrelation"/>
+ </bpws:partnerLinks>
+ <bpws:variables>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="input"/>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="output"/>
+ <bpws:variable type="xsd:int" name="i"/>
+ <bpws:variable type="xsd:int" name="j"/>
+ </bpws:variables>
+ <bpws:correlationSets>
+ <bpws:correlationSet name="CorrelationSet"
properties="ns:input"/>
+ </bpws:correlationSets>
+ <bpws:sequence name="main">
+ <bpws:scope>
+ <bpws:sequence>
+ <bpws:receive createInstance="yes" operation="initiate"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input">
+ <bpws:correlations>
+ <bpws:correlation initiate="yes"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'test1'</bpws:from>
+ <bpws:to>$output.payload</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="initiate" partnerLink="client"
variable="output"/>
+
+
+ <bpws:receive operation="complete" partnerLink="client"
portType="tns:OnEventCorrelation" variable="input">
+ <bpws:correlations>
+ <bpws:correlation initiate="no"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:empty name="e6"/>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'test3-old'</bpws:from>
+ <bpws:to>$output.payload</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="complete" partnerLink="client"
variable="output"/>
+ </bpws:sequence>
+ </bpws:scope>
+ </bpws:sequence>
+</bpws:process>
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v1-1/OnEventCorrelation.wsdl
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v1-1/OnEventCorrelation.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v1-1/OnEventCorrelation.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,66 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions
xmlns="http://schemas.xmlsoap.org/wsdl/"
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
xmlns:tns="http://sample.bpel.org/bpel/sample"
xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/"
name="OnEventCorrelation"
targetNamespace="http://sample.bpel.org/bpel/sample"
+xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+>
+ <message name="OnEventCorrelationMessage">
+ <part type="xsd:string" name="payload"/>
+ <part type="xsd:string" name="payload2"/>
+ </message>
+ <portType name="OnEventCorrelation">
+ <operation name="initiate">
+ <input message="tns:OnEventCorrelationMessage"/>
+ <output message="tns:OnEventCorrelationMessage"/>
+ </operation>
+ <operation name="complete">
+ <input message="tns:OnEventCorrelationMessage"/>
+ <output message="tns:OnEventCorrelationMessage"/>
+ </operation>
+ </portType>
+ <binding name="OnEventCorrelationBinding"
type="tns:OnEventCorrelation">
+ <wsdlsoap:binding style="rpc"
transport="http://schemas.xmlsoap.org/soap/http"/>
+ <operation name="initiate">
+ <wsdlsoap:operation soapAction="initiate"/>
+ <input>
+ <wsdlsoap:body use="literal"/>
+ </input>
+ <output>
+ <wsdlsoap:body use="literal"/>
+ </output>
+ </operation>
+ <operation name="complete">
+ <wsdlsoap:operation soapAction="complete"/>
+ <input>
+ <wsdlsoap:body use="literal"/>
+ </input>
+ <output>
+ <wsdlsoap:body use="literal"/>
+ </output>
+ </operation>
+ </binding>
+ <service name="OnEventCorrelation">
+ <port binding="tns:OnEventCorrelationBinding"
name="OnEventCorrelation">
+ <wsdlsoap:address
location="http://localhost:8080/ode/processes/OnEventCorrelation/"/>
+ </port>
+ </service>
+ <plnk:partnerLinkType name="OnEventCorrelation">
+ <plnk:role name="OnEventCorrelationProvider"
portType="tns:OnEventCorrelation"/>
+ </plnk:partnerLinkType>
+</definitions>
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v1-1/OnEventCorrelationArtifacts.wsdl
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v1-1/OnEventCorrelationArtifacts.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v1-1/OnEventCorrelationArtifacts.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns:tns="http://sample.bpel.org/bpel/sampleArtifacts"
+
xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop"
+
xmlns:xs="http://www.w3.org/2001/XMLSchema"
+
xmlns:bpel="http://sample.bpel.org/bpel/sample"
+ name="OnEventCorrelationArtifacts"
+
targetNamespace="http://sample.bpel.org/bpel/sampleArtifacts"
+
xmlns="http://schemas.xmlsoap.org/wsdl/"
+ >
+<vprop:property name="input" type="xs:string"/>
+<vprop:propertyAlias messageType="bpel:OnEventCorrelationMessage"
part="payload" propertyName="tns:input">
+<!--vprop:query><![CDATA[bpel:input]]></vprop:query-->
+</vprop:propertyAlias>
+<import location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+</definitions>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v1-1/deploy.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v1-1/deploy.xml
(rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v1-1/deploy.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,31 @@
+<?xml version='1.0' encoding='UTF-8'?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<dd:deploy
xmlns:dd="http://www.apache.org/ode/schemas/dd/2007/03"
+
xmlns:bpel="http://sample.bpel.org/bpel/sample"
+ >
+
+ <dd:process
+ name="bpel:OnEventCorrelation"
fileName="OnEventCorrelation.bpel">
+ <!--dd:process-events generate="none"/-->
+ <dd:provide partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelation"
port="OnEventCorrelation" />
+ </dd:provide>
+ </dd:process>
+</dd:deploy>
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v2-1/OnEventCorrelation.bpel
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v2-1/OnEventCorrelation.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v2-1/OnEventCorrelation.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,68 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<bpws:process
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns="http://sample.bpel.org/bpel/sampleArtifacts"
xmlns:tns="http://sample.bpel.org/bpel/sample"
exitOnStandardFault="yes" name="OnEventCorrelation"
suppressJoinFailure="yes"
targetNamespace="http://sample.bpel.org/bpel/sample"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelationArtifacts.wsdl"
namespace="http://sample.bpel.org/bpel/sampleArtifacts"/>
+ <bpws:partnerLinks>
+ <bpws:partnerLink myRole="OnEventCorrelationProvider"
name="client" partnerLinkType="tns:OnEventCorrelation"/>
+ </bpws:partnerLinks>
+ <bpws:variables>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="input"/>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="output"/>
+ <bpws:variable type="xsd:int" name="i"/>
+ <bpws:variable type="xsd:int" name="j"/>
+ </bpws:variables>
+ <bpws:correlationSets>
+ <bpws:correlationSet name="CorrelationSet"
properties="ns:input"/>
+ </bpws:correlationSets>
+ <bpws:sequence name="main">
+ <bpws:scope>
+ <bpws:sequence>
+ <bpws:receive createInstance="yes" operation="initiate"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input">
+ <bpws:correlations>
+ <bpws:correlation initiate="yes"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'test1'</bpws:from>
+ <bpws:to>$output.payload</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="initiate" partnerLink="client"
variable="output"/>
+
+
+ <bpws:receive operation="complete" partnerLink="client"
portType="tns:OnEventCorrelation" variable="input">
+ <bpws:correlations>
+ <bpws:correlation initiate="no"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:empty name="e6"/>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'test3-new'</bpws:from>
+ <bpws:to>$output.payload</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="complete" partnerLink="client"
variable="output"/>
+ </bpws:sequence>
+ </bpws:scope>
+ </bpws:sequence>
+</bpws:process>
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v2-1/OnEventCorrelation.wsdl
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v2-1/OnEventCorrelation.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v2-1/OnEventCorrelation.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,66 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions
xmlns="http://schemas.xmlsoap.org/wsdl/"
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
xmlns:tns="http://sample.bpel.org/bpel/sample"
xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/"
name="OnEventCorrelation"
targetNamespace="http://sample.bpel.org/bpel/sample"
+xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+>
+ <message name="OnEventCorrelationMessage">
+ <part type="xsd:string" name="payload"/>
+ <part type="xsd:string" name="payload2"/>
+ </message>
+ <portType name="OnEventCorrelation">
+ <operation name="initiate">
+ <input message="tns:OnEventCorrelationMessage"/>
+ <output message="tns:OnEventCorrelationMessage"/>
+ </operation>
+ <operation name="complete">
+ <input message="tns:OnEventCorrelationMessage"/>
+ <output message="tns:OnEventCorrelationMessage"/>
+ </operation>
+ </portType>
+ <binding name="OnEventCorrelationBinding"
type="tns:OnEventCorrelation">
+ <wsdlsoap:binding style="rpc"
transport="http://schemas.xmlsoap.org/soap/http"/>
+ <operation name="initiate">
+ <wsdlsoap:operation soapAction="initiate"/>
+ <input>
+ <wsdlsoap:body use="literal"/>
+ </input>
+ <output>
+ <wsdlsoap:body use="literal"/>
+ </output>
+ </operation>
+ <operation name="complete">
+ <wsdlsoap:operation soapAction="complete"/>
+ <input>
+ <wsdlsoap:body use="literal"/>
+ </input>
+ <output>
+ <wsdlsoap:body use="literal"/>
+ </output>
+ </operation>
+ </binding>
+ <service name="OnEventCorrelation">
+ <port binding="tns:OnEventCorrelationBinding"
name="OnEventCorrelation">
+ <wsdlsoap:address
location="http://localhost:8080/ode/processes/OnEventCorrelation/"/>
+ </port>
+ </service>
+ <plnk:partnerLinkType name="OnEventCorrelation">
+ <plnk:role name="OnEventCorrelationProvider"
portType="tns:OnEventCorrelation"/>
+ </plnk:partnerLinkType>
+</definitions>
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v2-1/OnEventCorrelationArtifacts.wsdl
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v2-1/OnEventCorrelationArtifacts.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v2-1/OnEventCorrelationArtifacts.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns:tns="http://sample.bpel.org/bpel/sampleArtifacts"
+
xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop"
+
xmlns:xs="http://www.w3.org/2001/XMLSchema"
+
xmlns:bpel="http://sample.bpel.org/bpel/sample"
+ name="OnEventCorrelationArtifacts"
+
targetNamespace="http://sample.bpel.org/bpel/sampleArtifacts"
+
xmlns="http://schemas.xmlsoap.org/wsdl/"
+ >
+<vprop:property name="input" type="xs:string"/>
+<vprop:propertyAlias messageType="bpel:OnEventCorrelationMessage"
part="payload" propertyName="tns:input">
+<!--vprop:query><![CDATA[bpel:input]]></vprop:query-->
+</vprop:propertyAlias>
+<import location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+</definitions>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v2-1/deploy.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v2-1/deploy.xml
(rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/DigestJbiTest/v2-1/deploy.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,31 @@
+<?xml version='1.0' encoding='UTF-8'?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<dd:deploy
xmlns:dd="http://www.apache.org/ode/schemas/dd/2007/03"
+
xmlns:bpel="http://sample.bpel.org/bpel/sample"
+ >
+
+ <dd:process
+ name="bpel:OnEventCorrelation"
fileName="OnEventCorrelation.bpel">
+ <!--dd:process-events generate="none"/-->
+ <dd:provide partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelation"
port="OnEventCorrelation" />
+ </dd:provide>
+ </dd:process>
+</dd:deploy>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/Ping.bpel
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/Ping.bpel
(rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/Ping.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,101 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<process
+ name="Ping"
+
xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
+ targetNamespace="urn:/Ping.bpel"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:tns="urn:/Ping.bpel"
+ xmlns:ping="urn:/Ping.wsdl"
+ xmlns:pong="urn:/Pong.wsdl"
+
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath1.0">
+
+ <import location="Ping.wsdl"
+ namespace="urn:/Ping.wsdl"
+
importType="http://schemas.xmlsoap.org/wsdl/" />
+
+ <import location="Pong.wsdl"
+ namespace="urn:/Pong.wsdl"
+
importType="http://schemas.xmlsoap.org/wsdl/" />
+
+ <partnerLinks>
+ <partnerLink name="PingPartnerLink"
+ partnerLinkType="ping:PingPartnerLinkType"
+ myRole="Provider" />
+ <partnerLink name="PongPartnerLink"
+ partnerLinkType="pong:PongPartnerLinkType"
+ partnerRole="Provider"
+ initializePartnerRole="yes" />
+ </partnerLinks>
+
+ <variables>
+ <variable messageType="ping:PingRequest"
name="pingRequest"/>
+ <variable messageType="ping:PingResponse"
name="pingResponse"/>
+ <variable messageType="pong:PongRequest"
name="pongRequest"/>
+ <variable messageType="pong:PongResponse"
name="pongResponse"/>
+ <variable type="xsd:string" name="text" />
+ </variables>
+
+ <sequence name="Main">
+ <receive name="pingReceive"
+ createInstance="yes"
+ operation="Ping"
+ partnerLink="PingPartnerLink"
+ portType="ping:PingPortType"
+ variable="pingRequest"/>
+
+ <assign name="assignPongRequest">
+ <!-- add "ping" text to the input text -->
+ <copy>
+ <from>concat($pingRequest.body/ping:text, '
ping')</from>
+ <to variable="text"/>
+ </copy>
+ <!-- initialize pongRequest -->
+ <copy>
+ <from>
+ <literal>
+ <pong:PongRequest>
+ <pong:text/>
+ </pong:PongRequest>
+ </literal>
+ </from>
+ <to>$pongRequest.body</to>
+ </copy>
+ <!-- copy new text into pongRequest -->
+ <copy>
+ <from>$text</from>
+ <to>$pongRequest.body/pong:text</to>
+ </copy>
+ </assign>
+
+ <invoke name="invokePong"
+ operation="Pong"
+ inputVariable="pongRequest"
+ outputVariable="pongResponse"
+ partnerLink="PongPartnerLink"
+ portType="pong:PongPortType"/>
+
+ <reply name="pingReply"
+ partnerLink="PingPartnerLink"
+ portType="ping:PingPortType"
+ operation="Ping"
+ variable="pingResponse"/>
+ </sequence>
+</process>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/Ping.wsdl
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/Ping.wsdl
(rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/Ping.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,73 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions name="Ping"
+ targetNamespace="urn:/Ping.wsdl"
+ xmlns:tns="urn:/Ping.wsdl"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns="http://schemas.xmlsoap.org/wsdl/">
+
+ <types>
+ <schema targetNamespace="urn:/Ping.wsdl"
+
xmlns="http://www.w3.org/2001/XMLSchema">
+ <element name="PingRequest">
+ <complexType>
+ <all>
+ <element name="text" type="string"/>
+ </all>
+ </complexType>
+ </element>
+ <element name="PingResponse">
+ <complexType>
+ <all>
+ <element name="text" type="string"/>
+ </all>
+ </complexType>
+ </element>
+ </schema>
+ </types>
+
+ <message name="PingRequest">
+ <part name="body" element="tns:PingRequest"/>
+ </message>
+
+ <message name="PingResponse">
+ </message>
+
+ <portType name="PingPortType">
+ <operation name="Ping">
+ <input message="tns:PingRequest"/>
+ <output message="tns:PingResponse"/>
+ </operation>
+ </portType>
+
+ <plnk:partnerLinkType name="PingPartnerLinkType">
+ <plnk:role name="Provider"
portType="tns:PingPortType"/>
+ </plnk:partnerLinkType>
+
+ <!--
+
+ This is an abstract interface/portType definition. Note the lack of
+ binding and service: these are defined by the HTTP binding component.
+ See ping-http/Ping.wsdl for details.
+
+ -->
+
+</definitions>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/Pong.bpel
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/Pong.bpel
(rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/Pong.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,71 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<process
+ name="Pong"
+
xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
+ targetNamespace="urn:/Pong.bpel"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:tns="urn:/Pong.bpel"
+ xmlns:pong="urn:/Pong.wsdl"
+
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath1.0">
+
+ <import location="Pong.wsdl"
+ namespace="urn:/Pong.wsdl"
+
importType="http://schemas.xmlsoap.org/wsdl/" />
+
+ <import location="Pong.wsdl"
+ namespace="urn:/Pong.wsdl"
+
importType="http://schemas.xmlsoap.org/wsdl/" />
+
+ <partnerLinks>
+ <partnerLink name="PongPartnerLink"
+ partnerLinkType="pong:PongPartnerLinkType"
+ myRole="Provider" />
+ </partnerLinks>
+
+ <variables>
+ <variable messageType="pong:PongRequest"
name="pongRequest"/>
+ <variable messageType="pong:PongResponse"
name="pongResponse"/>
+ <variable type="xsd:string" name="text" />
+ </variables>
+
+ <sequence name="Main">
+ <receive name="pongReceive"
+ createInstance="yes"
+ operation="Pong"
+ partnerLink="PongPartnerLink"
+ portType="pong:PongPortType"
+ variable="pongRequest"/>
+
+ <assign name="assignPongRequest">
+ <!-- add "ping" text to the input text -->
+ <copy>
+ <from>concat($pongRequest.body/pong:text, '
pong')</from>
+ <to>$text</to>
+ </copy>
+ </assign>
+
+ <reply name="pongReply"
+ partnerLink="PongPartnerLink"
+ portType="pong:PongPortType"
+ operation="Pong"
+ variable="pongResponse"/>
+ </sequence>
+</process>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/Pong.wsdl
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/Pong.wsdl
(rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/Pong.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,73 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions name="Pong"
+ targetNamespace="urn:/Pong.wsdl"
+ xmlns:tns="urn:/Pong.wsdl"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns="http://schemas.xmlsoap.org/wsdl/">
+
+ <types>
+ <schema targetNamespace="urn:/Pong.wsdl"
+
xmlns="http://www.w3.org/2001/XMLSchema">
+ <element name="PongRequest">
+ <complexType>
+ <all>
+ <element name="text" type="string"/>
+ </all>
+ </complexType>
+ </element>
+ <element name="PongResponse">
+ <complexType>
+ <all>
+ <element name="text" type="string"/>
+ </all>
+ </complexType>
+ </element>
+ </schema>
+ </types>
+
+ <message name="PongRequest">
+ <part name="body" element="tns:PongRequest"/>
+ </message>
+
+ <message name="PongResponse">
+ </message>
+
+ <portType name="PongPortType">
+ <operation name="Pong">
+ <input message="tns:PongRequest"/>
+ <output message="tns:PongResponse"/>
+ </operation>
+ </portType>
+
+ <plnk:partnerLinkType name="PongPartnerLinkType">
+ <plnk:role name="Provider"
portType="tns:PongPortType"/>
+ </plnk:partnerLinkType>
+
+ <!--
+
+ This is an abstract interface/portType definition. Note the lack of
+ binding and service. Since Pong is only exposed on the JBI bus, the
+ JBI endpoint is defined in Pong.dd.
+
+ -->
+
+</definitions>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/deploy.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/deploy.xml
(rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/deploy.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,42 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<deploy
xmlns="http://www.apache.org/ode/schemas/dd/2007/03"
+ xmlns:pingProcess="urn:/Ping.bpel"
+ xmlns:pongProcess="urn:/Pong.bpel"
+ xmlns:ping="urn:/Ping.wsdl"
+ xmlns:pong="urn:/Pong.wsdl">
+
+ <process name="pingProcess:Ping">
+ <active>true</active>
+ <provide partnerLink="PingPartnerLink">
+ <service name="ping:PingService" port="PingPort"/>
+ </provide>
+ <invoke partnerLink="PongPartnerLink">
+ <service name="pong:PongServiceFwd" port="PongPort"/>
+ </invoke>
+ </process>
+ <process name="pongProcess:Pong">
+ <active>true</active>
+ <provide partnerLink="PongPartnerLink">
+ <service name="pong:PongService" port="PongPort"/>
+ </provide>
+ </process>
+
+</deploy>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/smx.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/smx.xml
(rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/smx.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,79 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+
http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+-->
+<beans
xmlns:sm="http://servicemix.apache.org/config/1.0"
+
xmlns:http="http://servicemix.apache.org/http/1.0"
+
xmlns:eip="http://servicemix.apache.org/eip/1.0"
+ xmlns:ping="urn:/Ping.wsdl"
+ xmlns:pong="urn:/Pong.wsdl"
+
xmlns:util="http://www.springframework.org/schema/util"
+ >
+
+ <util:map id="jndiEntries">
+ <entry key="java:comp/env/jdbc/ode"
value-ref="odeDS"/>
+ </util:map>
+
+ <sm:container
+ id="jbi"
+ embedded="true"
+ rootDir="target/test/smx"
+ transactionManager="#transactionManager"
+ depends-on="jndi"
+
+ <sm:activationSpecs>
+ <sm:activationSpec id="pingpong-eip">
+ <sm:component>
+ <eip:component>
+ <eip:endpoints>
+ <eip:content-based-router service="pong:PongServiceFwd"
endpoint="PongPort" forwardOperation="true">
+ <eip:rules>
+ <eip:routing-rule>
+ <eip:target>
+ <eip:exchange-target service="pong:PongService"/>
+ </eip:target>
+ </eip:routing-rule>
+ </eip:rules>
+ </eip:content-based-router>
+ </eip:endpoints>
+ </eip:component>
+ </sm:component>
+ </sm:activationSpec>
+ <sm:activationSpec id="pingpong-http">
+ <sm:component>
+ <http:component>
+ <http:endpoints>
+ <http:endpoint
+ service="ping:PingService"
+ endpoint="http"
+ targetService="ping:PingService"
+ targetEndpoint="PingPort"
+ defaultOperation="Ping"
+ role="consumer"
+ locationURI="http://localhost:8198/PingHttp/"
+
defaultMep="http://www.w3.org/2004/08/wsdl/in-out"
+ wsdlResource="classpath:EmptyRespJbiTest/Ping.wsdl"
+ soapVersion="1.1"
+ soap="true" />
+ </http:endpoints>
+ </http:component>
+ </sm:component>
+ </sm:activationSpec>
+ </sm:activationSpecs>
+ </sm:container>
+</beans>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/test.properties
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/test.properties
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/EmptyRespJbiTest/test.properties 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,20 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+#
http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+http.url=http://localhost:8198/PingHttp/
+request=<soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">&l...
xmlns:ping="urn:/Ping.wsdl"><ping:text>hello</ping:text></ping:PingRequest></soapenv:Body></soapenv:Envelope>
+response=.*<soapenv:Body />.*
+
Modified: branches/ODE/ODE-1.x/jbi/src/test/resources/ExtVarJbiTest/smx.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/ExtVarJbiTest/smx.xml 2010-04-14 15:43:12
UTC (rev 619)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/ExtVarJbiTest/smx.xml 2010-04-14 18:25:55
UTC (rev 620)
@@ -23,58 +23,34 @@
xmlns:util="http://www.springframework.org/schema/util"
xmlns:jencks="http://jencks.org/2.0"
-
- <bean id="transactionManager"
class="org.apache.geronimo.transaction.manager.GeronimoTransactionManager"/>
-
- <jencks:connectionTracker id="connectionTracker"
geronimoTransactionManager="#transactionManager" />
-
- <jencks:workManager
- id="workManager"
- threadPoolSize="200"
- transactionManager="#transactionManager" />
-
- <jencks:bootstrapContext
- id="bootstrapContext"
- workManager="#workManager"
- transactionManager="#transactionManager" />
-
<jencks:poolingSupport
- id="poolingSupport"
+ id="poolingSupport2"
connectionMaxIdleMinutes="5"
poolMaxSize="20"
/>
<jencks:connectionManager
- id="connectionManager"
+ id="connectionManager2"
containerManagedSecurity="false"
- transaction="xa"
+ transaction="local"
transactionManager="#transactionManager"
- poolingSupport="#poolingSupport"
+ poolingSupport="#poolingSupport2"
connectionTracker="#connectionTracker"
/>
-
- <bean id="localDerbyMCF"
class="org.tranql.connector.derby.EmbeddedXAMCF">
+ <bean id="localDerbyMCF"
class="org.tranql.connector.derby.EmbeddedLocalMCF">
<property name="databaseName"
value="target/test/testdb"/>
<property name="createDatabase" value="true"/>
<property name="userName" value = "sa"/>
<property name="password" value = ""/>
</bean>
- <bean id="localDerbyDataSource"
class="org.springframework.jca.support.LocalConnectionFactoryBean">
+ <bean id="localDerbyDataSource"
class="org.jencks.factory.ConnectionFactoryFactoryBean">
<property name="managedConnectionFactory"
ref="localDerbyMCF"/>
- <property name="connectionManager"
ref="connectionManager"/>
+ <property name="connectionManager"
ref="connectionManager2"/>
</bean>
- <bean id="jndi"
- class="org.apache.xbean.spring.jndi.SpringInitialContextFactory"
- factory-method="makeInitialContext"
- singleton="true"
- depends-on="bootstrapContext"
- >
- <property name="entries" ref="jndiEntries" />
- </bean>
-
<util:map id="jndiEntries">
- <entry key="testds" value-ref="localDerbyDataSource"/>
+ <entry key="java:comp/env/jdbc/ode"
value-ref="odeDS"/>
+ <entry key="testds" value-ref="localDerbyDataSource"/>
</util:map>
<sm:container
Modified: branches/ODE/ODE-1.x/jbi/src/test/resources/HelloWorldJbiTest/HelloWorld2.bpel
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/HelloWorldJbiTest/HelloWorld2.bpel 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/HelloWorldJbiTest/HelloWorld2.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -1,4 +1,22 @@
<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
<bpws:process exitOnStandardFault="yes" name="HelloWorld2"
targetNamespace="urn:/HeaderTest.bpel"
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
Modified: branches/ODE/ODE-1.x/jbi/src/test/resources/HelloWorldJbiTest/HelloWorld2.wsdl
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/HelloWorldJbiTest/HelloWorld2.wsdl 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/HelloWorldJbiTest/HelloWorld2.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -26,7 +26,7 @@
<types>
<schema targetNamespace="urn:/HelloWorld2.wsdl"
-
xmlns="http://www.w3.org/2000/10/XMLSchema">
+
xmlns="http://www.w3.org/2001/XMLSchema">
<element name="HelloRequest">
<complexType>
<all>
Modified: branches/ODE/ODE-1.x/jbi/src/test/resources/HelloWorldJbiTest/smx.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/HelloWorldJbiTest/smx.xml 2010-04-14
15:43:12 UTC (rev 619)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/HelloWorldJbiTest/smx.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -24,17 +24,8 @@
xmlns:util="http://www.springframework.org/schema/util"
- <bean id="transactionManager"
class="org.apache.geronimo.transaction.manager.GeronimoTransactionManager"/>
-
- <bean id="jndi"
- class="org.apache.xbean.spring.jndi.SpringInitialContextFactory"
- factory-method="makeInitialContext"
- singleton="true"
-
- <property name="entries"
ref="jndiEntries" />
- </bean>
-
<util:map id="jndiEntries">
+ <entry key="java:comp/env/jdbc/ode"
value-ref="odeDS"/>
</util:map>
<sm:container
@@ -54,7 +45,7 @@
endpoint="http"
defaultOperation="Hello"
role="consumer"
- locationURI="http://localhost:8192/HelloHttp/"
+ locationURI="http://localhost:8198/HelloHttp/"
defaultMep="http://www.w3.org/2004/08/wsdl/in-out"
soap="true" />
</http:endpoints>
Modified: branches/ODE/ODE-1.x/jbi/src/test/resources/HelloWorldJbiTest/test.properties
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/HelloWorldJbiTest/test.properties 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/HelloWorldJbiTest/test.properties 2010-04-14
18:25:55 UTC (rev 620)
@@ -14,7 +14,7 @@
# See the License for the specific language governing permissions and
# limitations under the License.
#
-http.url=http://localhost:8192/HelloHttp/
+http.url=http://localhost:8198/HelloHttp/
request=<SOAP-ENV:Envelope
xmlns:SOAP-ENV='http://schemas.xmlsoap.org/soap/envelope/'><...
xmlns="urn:/HelloWorld2.wsdl"><text>hello</text></HelloRequest></SOAP-ENV:Body></SOAP-ENV:Envelope>
response=.*hello World.*
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionExternalJbiTest/Main.bpel
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionExternalJbiTest/Main.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionExternalJbiTest/Main.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,111 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<process name="MagicSessionMain"
+ targetNamespace="http://ode/bpel/unit-test"
+
xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
+ xmlns:tns="http://ode/bpel/unit-test"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+ xmlns:test="http://ode/bpel/unit-test.wsdl">
+
+ <import location="Main.wsdl"
namespace="http://ode/bpel/unit-test.wsdl"
+
importType="http://schemas.xmlsoap.org/wsdl/" />
+
+ <partnerLinks>
+ <partnerLink name="responderPartnerLink"
partnerLinkType="test:ResponderPartnerLinkType"
+ myRole="main" partnerRole="responder"
initializePartnerRole="yes"/>
+ <partnerLink name="executePartnerLink"
partnerLinkType="test:ExecutePartnerLinkType"
+ myRole="executor"/>
+ </partnerLinks>
+
+ <variables>
+ <variable name="dummy" messageType="test:ExecuteMessage"/>
+ <variable name="dummy2"
messageType="test:InitiateMessage"/>
+ <variable name="dummy3"
messageType="test:CallbackMessage"/>
+ <variable name="dummy4"
messageType="test:DoubleCallMessage"/>
+ <variable name="dummy5"
messageType="test:DoubleCallbackMessage"/>
+ <variable name="eprmessage"
messageType="test:TripleCallMessage"/>
+ <variable name="myepr"
messageType="test:TripleCallbackMessage"/>
+ <variable name="result" messageType="test:ResultMessage"/>
+ </variables>
+
+ <sequence>
+ <!-- Start message -->
+ <receive name="start" partnerLink="executePartnerLink"
+ portType="test:MSExecutePortType" operation="execute"
createInstance="yes" variable="dummy"/>
+
+ <!-- Initializing message, starting the responder process with the magic session
+ and expecting a callback -->
+ <assign>
+ <copy keepSrcElementName="yes">
+ <from partnerLink="responderPartnerLink"
endpointReference="myRole"/>
+ <to>$dummy2.reply-to/*</to>
+ </copy>
+ <copy>
+ <from>123</from>
+ <to variable="dummy2" part="payload"/>
+ </copy>
+ </assign>
+ <invoke name="initiate" partnerLink="responderPartnerLink"
portType="test:MSResponderPortType"
+ operation="initiate" inputVariable="dummy2"/>
+
+ <receive name="callback" partnerLink="responderPartnerLink"
+ portType="test:MSMainPortType" operation="callback"
variable="dummy3"/>
+
+ <!-- Initializing message, calling our partner again with magic session (double
invocation) -->
+ <assign>
+ <copy>
+ <from>123</from>
+ <to variable="dummy4" part="payload"/>
+ </copy>
+ </assign>
+ <invoke name="get-endpoint" partnerLink="responderPartnerLink"
portType="test:MSResponderPortType"
+ operation="doubleCall" inputVariable="dummy4"/>
+
+ <receive name="doubleCallback"
partnerLink="responderPartnerLink"
+ portType="test:MSMainPortType"
operation="doubleCallback" variable="dummy5"/>
+
+ <!-- Sending our endpoint explicitly to have our partner calling us back using it
+ (demonstrating assignment) -->
+ <assign>
+ <copy keepSrcElementName="yes">
+ <from partnerLink="responderPartnerLink"
endpointReference="myRole"/>
+ <to>$eprmessage.payload/*</to>
+ </copy>
+ </assign>
+ <invoke name="eprPassing" partnerLink="responderPartnerLink"
portType="test:MSResponderPortType"
+ operation="EndpointReference"
inputVariable="eprmessage"/>
+
+ <receive name="tripleCallback"
partnerLink="responderPartnerLink"
+ portType="test:MSMainPortType"
operation="tripleCallback" variable="myepr"/>
+
+ <!-- Done. -->
+ <assign>
+ <copy>
+ <from>'OK'</from>
+ <to variable="result" part="ack"/>
+ </copy>
+ </assign>
+ <reply name="end" partnerLink="executePartnerLink"
+ portType="test:MSExecutePortType" operation="execute"
variable="result"/>
+
+ </sequence>
+</process>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionExternalJbiTest/Main.wsdl
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionExternalJbiTest/Main.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionExternalJbiTest/Main.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,178 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<wsdl:definitions
+ targetNamespace="http://ode/bpel/unit-test.wsdl"
+
xmlns="http://schemas.xmlsoap.org/wsdl/"
+ xmlns:tns="http://ode/bpel/unit-test.wsdl"
+
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype">
+
+ <wsdl:message name="ExecuteMessage">
+ <wsdl:part name="payload" type="xsd:string"/>
+ </wsdl:message>
+
+ <wsdl:message name="CallbackMessage">
+ <wsdl:part name="payload" type="xsd:string"/>
+ </wsdl:message>
+
+ <wsdl:message name="DoubleCallbackMessage">
+ <wsdl:part name="payload" type="xsd:string"/>
+ </wsdl:message>
+
+ <wsdl:message name="TripleCallbackMessage">
+ <wsdl:part name="payload" type="xsd:string"/>
+ </wsdl:message>
+
+ <wsdl:message name="ResultMessage">
+ <wsdl:part name="ack" type="xsd:string"/>
+ </wsdl:message>
+
+ <wsdl:message name="InitiateMessage">
+ <wsdl:part name="payload" type="xsd:string"/>
+ <wsdl:part name="reply-to" type="xsd:anyType"/>
+ </wsdl:message>
+
+ <wsdl:message name="DoubleCallMessage">
+ <wsdl:part name="payload" type="xsd:string"/>
+ </wsdl:message>
+
+ <wsdl:message name="TripleCallMessage">
+ <wsdl:part name="payload" type="xsd:anyType"/>
+ </wsdl:message>
+
+ <wsdl:portType name="MSExecutePortType">
+ <wsdl:operation name="execute">
+ <wsdl:input message="tns:ExecuteMessage"
name="Execute"/>
+ <wsdl:output message="tns:ResultMessage"
name="Result"/>
+ </wsdl:operation>
+ </wsdl:portType>
+ <wsdl:portType name="MSMainPortType">
+ <wsdl:operation name="callback">
+ <wsdl:input message="tns:CallbackMessage"
name="Callback"/>
+ </wsdl:operation>
+ <wsdl:operation name="doubleCallback">
+ <wsdl:input message="tns:DoubleCallbackMessage"
name="DoubleCallback"/>
+ </wsdl:operation>
+ <wsdl:operation name="tripleCallback">
+ <wsdl:input message="tns:TripleCallbackMessage"
name="TripleCallback"/>
+ </wsdl:operation>
+ </wsdl:portType>
+
+ <wsdl:portType name="MSResponderPortType">
+ <wsdl:operation name="initiate">
+ <wsdl:input message="tns:InitiateMessage"
name="Callback"/>
+ </wsdl:operation>
+ <wsdl:operation name="doubleCall">
+ <wsdl:input message="tns:DoubleCallMessage"
name="DoubleCallback"/>
+ </wsdl:operation>
+ <wsdl:operation name="EndpointReference">
+ <wsdl:input message="tns:TripleCallMessage"
name="EndpointReference"/>
+ </wsdl:operation>
+ </wsdl:portType>
+
+ <wsdl:binding name="MSExecuteBinding"
type="tns:MSExecutePortType">
+ <soap:binding style="rpc"
transport="http://schemas.xmlsoap.org/soap/http"/>
+ <wsdl:operation name="execute">
+ <soap:operation soapAction="" style="rpc"/>
+ <wsdl:input>
+ <soap:body namespace="http://ode/bpel/unit-test.wsdl"
use="literal"/>
+ </wsdl:input>
+ <wsdl:output>
+ <soap:body namespace="http://ode/bpel/unit-test.wsdl"
use="literal"/>
+ </wsdl:output>
+ </wsdl:operation>
+ </wsdl:binding>
+ <wsdl:binding name="MSMainBinding"
type="tns:MSMainPortType">
+ <soap:binding style="rpc"
transport="http://schemas.xmlsoap.org/soap/http"/>
+ <wsdl:operation name="callback">
+ <soap:operation soapAction="" style="rpc"/>
+ <wsdl:input>
+ <soap:body namespace="http://ode/bpel/unit-test.wsdl"
use="literal"/>
+ </wsdl:input>
+ </wsdl:operation>
+ <wsdl:operation name="doubleCallback">
+ <soap:operation soapAction="" style="rpc"/>
+ <wsdl:input>
+ <soap:body namespace="http://ode/bpel/unit-test.wsdl"
use="literal"/>
+ </wsdl:input>
+ </wsdl:operation>
+ <wsdl:operation name="tripleCallback">
+ <soap:operation soapAction="" style="rpc"/>
+ <wsdl:input>
+ <soap:body namespace="http://ode/bpel/unit-test.wsdl"
use="literal"/>
+ </wsdl:input>
+ </wsdl:operation>
+ </wsdl:binding>
+
+ <wsdl:binding name="MSResponderBinding"
type="tns:MSResponderPortType">
+ <soap:binding style="rpc"
transport="http://schemas.xmlsoap.org/soap/http"/>
+ <wsdl:operation name="initiate">
+ <soap:operation soapAction="" style="rpc"/>
+ <wsdl:input>
+ <soap:body namespace="http://ode/bpel/unit-test.wsdl"
use="literal"/>
+ </wsdl:input>
+ </wsdl:operation>
+ <wsdl:operation name="doubleCall">
+ <soap:operation soapAction="" style="rpc"/>
+ <wsdl:input>
+ <soap:body namespace="http://ode/bpel/unit-test.wsdl"
use="literal"/>
+ </wsdl:input>
+ </wsdl:operation>
+ <wsdl:operation name="EndpointReference">
+ <soap:operation soapAction="" style="rpc"/>
+ <wsdl:input>
+ <soap:body namespace="http://ode/bpel/unit-test.wsdl"
use="literal"/>
+ </wsdl:input>
+ </wsdl:operation>
+ </wsdl:binding>
+
+ <!-- This service should be used to start the example. -->
+ <wsdl:service name="MSMainExecuteService">
+ <wsdl:port name="MSExecutePort"
binding="tns:MSExecuteBinding">
+ <soap:address
location="http://localhost:8080/ode/processes/MSMainExecuteService"/>
+ </wsdl:port>
+ </wsdl:service>
+
+ <!-- This service is internal, only used by the responder. -->
+ <wsdl:service name="MSMainService">
+ <wsdl:port name="MSMainPort"
binding="tns:MSMainBinding">
+ <soap:address
location="http://localhost:8080/ode/processes/MSMainService"/>
+ </wsdl:port>
+ </wsdl:service>
+
+ <!-- Service responding to the main service requests. -->
+ <wsdl:service name="MSResponderService">
+ <wsdl:port name="MSResponderPort"
binding="tns:MSResponderBinding">
+ <soap:address
location="http://localhost:8080/ode/processes/MSResponderService"/>
+ </wsdl:port>
+ </wsdl:service>
+
+ <plnk:partnerLinkType name="ResponderPartnerLinkType">
+ <plnk:role name="responder"
portType="tns:MSResponderPortType"/>
+ <plnk:role name="main" portType="tns:MSMainPortType"/>
+ </plnk:partnerLinkType>
+
+ <plnk:partnerLinkType name="ExecutePartnerLinkType">
+ <plnk:role name="executor"
portType="tns:MSExecutePortType"/>
+ </plnk:partnerLinkType>
+</wsdl:definitions>
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionExternalJbiTest/Responder.bpel
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionExternalJbiTest/Responder.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionExternalJbiTest/Responder.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,92 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<process name="MagicSessionResponder"
+ targetNamespace="http://ode/bpel/responder"
+
xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
+ xmlns:tns="http://ode/bpel/responder"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:resp="http://ode/bpel/unit-test.wsdl">
+
+ <import location="Main.wsdl"
namespace="http://ode/bpel/unit-test.wsdl"
+
importType="http://schemas.xmlsoap.org/wsdl/" />
+
+ <partnerLinks>
+ <partnerLink name="mainPartnerLink"
partnerLinkType="resp:ResponderPartnerLinkType"
+ myRole="responder" partnerRole="main"
initializePartnerRole="no"/>
+ </partnerLinks>
+
+ <variables>
+ <variable name="dummy2"
messageType="resp:InitiateMessage"/>
+ <variable name="dummy3"
messageType="resp:CallbackMessage"/>
+ <variable name="dummy4"
messageType="resp:DoubleCallMessage"/>
+ <variable name="dummy5"
messageType="resp:DoubleCallbackMessage"/>
+ <variable name="eprmessage"
messageType="resp:TripleCallMessage"/>
+ <variable name="dummy6"
messageType="resp:TripleCallbackMessage"/>
+ </variables>
+
+ <sequence>
+ <!-- Starting process and first callback -->
+ <receive name="start" partnerLink="mainPartnerLink"
variable="dummy2"
+ portType="resp:MSResponderPortType" operation="initiate"
createInstance="yes"/>
+ <assign>
+ <copy>
+ <from>$dummy2.reply-to/*</from>
+ <to partnerLink="mainPartnerLink"/>
+ </copy>
+ <copy>
+ <from>123</from>
+ <to variable="dummy3" part="payload"/>
+ </copy>
+ </assign>
+ <invoke name="callback" partnerLink="mainPartnerLink"
+ portType="resp:MSMainPortType" operation="callback"
inputVariable="dummy3"/>
+
+ <!-- Second callback -->
+ <receive name="doubleCall" partnerLink="mainPartnerLink"
variable="dummy4"
+ portType="resp:MSResponderPortType"
operation="doubleCall"/>
+ <assign>
+ <copy>
+ <from>123</from>
+ <to variable="dummy5" part="payload"/>
+ </copy>
+ </assign>
+ <invoke name="doubleCallback" partnerLink="mainPartnerLink"
+ portType="resp:MSMainPortType" operation="doubleCallback"
inputVariable="dummy5"/>
+
+ <!-- Callback on the epr explicitly provided by partner in the message
+ (demonstrating assignment) -->
+ <receive name="eprPassing" partnerLink="mainPartnerLink"
variable="eprmessage"
+ portType="resp:MSResponderPortType"
operation="EndpointReference"/>
+ <assign>
+ <copy>
+ <from>$eprmessage.payload/*</from>
+ <to partnerLink="mainPartnerLink"/>
+ </copy>
+ <copy>
+ <from>123</from>
+ <to variable="dummy6" part="payload"/>
+ </copy>
+ </assign>
+ <invoke name="tripleCallback" partnerLink="mainPartnerLink"
+ portType="resp:MSMainPortType" operation="tripleCallback"
inputVariable="dummy6"/>
+
+ </sequence>
+</process>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionExternalJbiTest/deploy.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionExternalJbiTest/deploy.xml
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionExternalJbiTest/deploy.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,41 @@
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<deploy
xmlns="http://www.apache.org/ode/schemas/dd/2007/03"
+ xmlns:main="http://ode/bpel/unit-test"
+ xmlns:mws="http://ode/bpel/unit-test.wsdl"
+ xmlns:resp="http://ode/bpel/responder">
+
+ <process name="main:MagicSessionMain">
+ <provide partnerLink="executePartnerLink">
+ <service name="mws:MSMainExecuteService"
port="MSExecutePort"/>
+ </provide>
+ <provide partnerLink="responderPartnerLink">
+ <service name="mws:MSMainService" port="MSMainPort"/>
+ </provide>
+ <invoke partnerLink="responderPartnerLink">
+ <service name="mws:MSResponderService2"
port="MSResponderPort"/>
+ </invoke>
+ </process>
+ <process name="resp:MagicSessionResponder">
+ <type>resp:MagicSessionResponder</type>
+ <provide partnerLink="mainPartnerLink">
+ <service name="mws:MSResponderService"
port="MSResponderPort"/>
+ </provide>
+ </process>
+</deploy>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionExternalJbiTest/smx.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionExternalJbiTest/smx.xml
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionExternalJbiTest/smx.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,69 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+
http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+-->
+<beans
xmlns:sm="http://servicemix.apache.org/config/1.0"
+
xmlns:http="http://servicemix.apache.org/http/1.0"
+
xmlns:eip="http://servicemix.apache.org/eip/1.0"
+
xmlns:util="http://www.springframework.org/schema/util"
+
xmlns:jencks="http://jencks.org/2.0"
+ xmlns:mws="http://ode/bpel/unit-test.wsdl"
+ >
+
+ <util:map id="jndiEntries">
+ <entry key="java:comp/env/jdbc/ode"
value-ref="odeDS"/>
+ </util:map>
+
+ <sm:container
+ id="jbi"
+ embedded="true"
+ rootDir="target/test/smx"
+ transactionManager="#transactionManager"
+ depends-on="jndi"
+
+ <sm:activationSpecs>
+ <sm:activationSpec id="ms-eip">
+ <sm:component>
+ <eip:component>
+ <eip:endpoints>
+ <eip:content-based-router
service="mws:MSMainService2" endpoint="MSMainPort"
forwardOperation="true">
+ <eip:rules>
+ <eip:routing-rule>
+ <eip:target>
+ <eip:exchange-target
service="mws:MSMainService"/>
+ </eip:target>
+ </eip:routing-rule>
+ </eip:rules>
+ </eip:content-based-router>
+
+ <eip:content-based-router
service="mws:MSResponderService2" endpoint="MSResponderPort"
forwardOperation="true">
+ <eip:rules>
+ <eip:routing-rule>
+ <eip:target>
+ <eip:exchange-target
service="mws:MSResponderService"/>
+ </eip:target>
+ </eip:routing-rule>
+ </eip:rules>
+ </eip:content-based-router>
+ </eip:endpoints>
+ </eip:component>
+ </sm:component>
+ </sm:activationSpec>
+ </sm:activationSpecs>
+ </sm:container>
+</beans>
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionExternalJbiTest/test.properties
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionExternalJbiTest/test.properties
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionExternalJbiTest/test.properties 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,22 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+#
http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+nmr.service={http://ode/bpel/unit-test.wsdl}MSMainExecuteService
+nmr.operation=execute
+request=<msg><payload>fire!</payload></msg>
+response=.*OK.*
+
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionJbiTest/Main.bpel
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionJbiTest/Main.bpel
(rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionJbiTest/Main.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,111 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<process name="MagicSessionMain"
+ targetNamespace="http://ode/bpel/unit-test"
+
xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
+ xmlns:tns="http://ode/bpel/unit-test"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+ xmlns:test="http://ode/bpel/unit-test.wsdl">
+
+ <import location="Main.wsdl"
namespace="http://ode/bpel/unit-test.wsdl"
+
importType="http://schemas.xmlsoap.org/wsdl/" />
+
+ <partnerLinks>
+ <partnerLink name="responderPartnerLink"
partnerLinkType="test:ResponderPartnerLinkType"
+ myRole="main" partnerRole="responder"
initializePartnerRole="yes"/>
+ <partnerLink name="executePartnerLink"
partnerLinkType="test:ExecutePartnerLinkType"
+ myRole="executor"/>
+ </partnerLinks>
+
+ <variables>
+ <variable name="dummy" messageType="test:ExecuteMessage"/>
+ <variable name="dummy2"
messageType="test:InitiateMessage"/>
+ <variable name="dummy3"
messageType="test:CallbackMessage"/>
+ <variable name="dummy4"
messageType="test:DoubleCallMessage"/>
+ <variable name="dummy5"
messageType="test:DoubleCallbackMessage"/>
+ <variable name="eprmessage"
messageType="test:TripleCallMessage"/>
+ <variable name="myepr"
messageType="test:TripleCallbackMessage"/>
+ <variable name="result" messageType="test:ResultMessage"/>
+ </variables>
+
+ <sequence>
+ <!-- Start message -->
+ <receive name="start" partnerLink="executePartnerLink"
+ portType="test:MSExecutePortType" operation="execute"
createInstance="yes" variable="dummy"/>
+
+ <!-- Initializing message, starting the responder process with the magic session
+ and expecting a callback -->
+ <assign>
+ <copy keepSrcElementName="yes">
+ <from partnerLink="responderPartnerLink"
endpointReference="myRole"/>
+ <to>$dummy2.reply-to/*</to>
+ </copy>
+ <copy>
+ <from>123</from>
+ <to variable="dummy2" part="payload"/>
+ </copy>
+ </assign>
+ <invoke name="initiate" partnerLink="responderPartnerLink"
portType="test:MSResponderPortType"
+ operation="initiate" inputVariable="dummy2"/>
+
+ <receive name="callback" partnerLink="responderPartnerLink"
+ portType="test:MSMainPortType" operation="callback"
variable="dummy3"/>
+
+ <!-- Initializing message, calling our partner again with magic session (double
invocation) -->
+ <assign>
+ <copy>
+ <from>123</from>
+ <to variable="dummy4" part="payload"/>
+ </copy>
+ </assign>
+ <invoke name="get-endpoint" partnerLink="responderPartnerLink"
portType="test:MSResponderPortType"
+ operation="doubleCall" inputVariable="dummy4"/>
+
+ <receive name="doubleCallback"
partnerLink="responderPartnerLink"
+ portType="test:MSMainPortType"
operation="doubleCallback" variable="dummy5"/>
+
+ <!-- Sending our endpoint explicitly to have our partner calling us back using it
+ (demonstrating assignment) -->
+ <assign>
+ <copy keepSrcElementName="yes">
+ <from partnerLink="responderPartnerLink"
endpointReference="myRole"/>
+ <to>$eprmessage.payload/*</to>
+ </copy>
+ </assign>
+ <invoke name="eprPassing" partnerLink="responderPartnerLink"
portType="test:MSResponderPortType"
+ operation="EndpointReference"
inputVariable="eprmessage"/>
+
+ <receive name="tripleCallback"
partnerLink="responderPartnerLink"
+ portType="test:MSMainPortType"
operation="tripleCallback" variable="myepr"/>
+
+ <!-- Done. -->
+ <assign>
+ <copy>
+ <from>'OK'</from>
+ <to variable="result" part="ack"/>
+ </copy>
+ </assign>
+ <reply name="end" partnerLink="executePartnerLink"
+ portType="test:MSExecutePortType" operation="execute"
variable="result"/>
+
+ </sequence>
+</process>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionJbiTest/Main.wsdl
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionJbiTest/Main.wsdl
(rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionJbiTest/Main.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,178 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<wsdl:definitions
+ targetNamespace="http://ode/bpel/unit-test.wsdl"
+
xmlns="http://schemas.xmlsoap.org/wsdl/"
+ xmlns:tns="http://ode/bpel/unit-test.wsdl"
+
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype">
+
+ <wsdl:message name="ExecuteMessage">
+ <wsdl:part name="payload" type="xsd:string"/>
+ </wsdl:message>
+
+ <wsdl:message name="CallbackMessage">
+ <wsdl:part name="payload" type="xsd:string"/>
+ </wsdl:message>
+
+ <wsdl:message name="DoubleCallbackMessage">
+ <wsdl:part name="payload" type="xsd:string"/>
+ </wsdl:message>
+
+ <wsdl:message name="TripleCallbackMessage">
+ <wsdl:part name="payload" type="xsd:string"/>
+ </wsdl:message>
+
+ <wsdl:message name="ResultMessage">
+ <wsdl:part name="ack" type="xsd:string"/>
+ </wsdl:message>
+
+ <wsdl:message name="InitiateMessage">
+ <wsdl:part name="payload" type="xsd:string"/>
+ <wsdl:part name="reply-to" type="xsd:anyType"/>
+ </wsdl:message>
+
+ <wsdl:message name="DoubleCallMessage">
+ <wsdl:part name="payload" type="xsd:string"/>
+ </wsdl:message>
+
+ <wsdl:message name="TripleCallMessage">
+ <wsdl:part name="payload" type="xsd:anyType"/>
+ </wsdl:message>
+
+ <wsdl:portType name="MSExecutePortType">
+ <wsdl:operation name="execute">
+ <wsdl:input message="tns:ExecuteMessage"
name="Execute"/>
+ <wsdl:output message="tns:ResultMessage"
name="Result"/>
+ </wsdl:operation>
+ </wsdl:portType>
+ <wsdl:portType name="MSMainPortType">
+ <wsdl:operation name="callback">
+ <wsdl:input message="tns:CallbackMessage"
name="Callback"/>
+ </wsdl:operation>
+ <wsdl:operation name="doubleCallback">
+ <wsdl:input message="tns:DoubleCallbackMessage"
name="DoubleCallback"/>
+ </wsdl:operation>
+ <wsdl:operation name="tripleCallback">
+ <wsdl:input message="tns:TripleCallbackMessage"
name="TripleCallback"/>
+ </wsdl:operation>
+ </wsdl:portType>
+
+ <wsdl:portType name="MSResponderPortType">
+ <wsdl:operation name="initiate">
+ <wsdl:input message="tns:InitiateMessage"
name="Callback"/>
+ </wsdl:operation>
+ <wsdl:operation name="doubleCall">
+ <wsdl:input message="tns:DoubleCallMessage"
name="DoubleCallback"/>
+ </wsdl:operation>
+ <wsdl:operation name="EndpointReference">
+ <wsdl:input message="tns:TripleCallMessage"
name="EndpointReference"/>
+ </wsdl:operation>
+ </wsdl:portType>
+
+ <wsdl:binding name="MSExecuteBinding"
type="tns:MSExecutePortType">
+ <soap:binding style="rpc"
transport="http://schemas.xmlsoap.org/soap/http"/>
+ <wsdl:operation name="execute">
+ <soap:operation soapAction="" style="rpc"/>
+ <wsdl:input>
+ <soap:body namespace="http://ode/bpel/unit-test.wsdl"
use="literal"/>
+ </wsdl:input>
+ <wsdl:output>
+ <soap:body namespace="http://ode/bpel/unit-test.wsdl"
use="literal"/>
+ </wsdl:output>
+ </wsdl:operation>
+ </wsdl:binding>
+ <wsdl:binding name="MSMainBinding"
type="tns:MSMainPortType">
+ <soap:binding style="rpc"
transport="http://schemas.xmlsoap.org/soap/http"/>
+ <wsdl:operation name="callback">
+ <soap:operation soapAction="" style="rpc"/>
+ <wsdl:input>
+ <soap:body namespace="http://ode/bpel/unit-test.wsdl"
use="literal"/>
+ </wsdl:input>
+ </wsdl:operation>
+ <wsdl:operation name="doubleCallback">
+ <soap:operation soapAction="" style="rpc"/>
+ <wsdl:input>
+ <soap:body namespace="http://ode/bpel/unit-test.wsdl"
use="literal"/>
+ </wsdl:input>
+ </wsdl:operation>
+ <wsdl:operation name="tripleCallback">
+ <soap:operation soapAction="" style="rpc"/>
+ <wsdl:input>
+ <soap:body namespace="http://ode/bpel/unit-test.wsdl"
use="literal"/>
+ </wsdl:input>
+ </wsdl:operation>
+ </wsdl:binding>
+
+ <wsdl:binding name="MSResponderBinding"
type="tns:MSResponderPortType">
+ <soap:binding style="rpc"
transport="http://schemas.xmlsoap.org/soap/http"/>
+ <wsdl:operation name="initiate">
+ <soap:operation soapAction="" style="rpc"/>
+ <wsdl:input>
+ <soap:body namespace="http://ode/bpel/unit-test.wsdl"
use="literal"/>
+ </wsdl:input>
+ </wsdl:operation>
+ <wsdl:operation name="doubleCall">
+ <soap:operation soapAction="" style="rpc"/>
+ <wsdl:input>
+ <soap:body namespace="http://ode/bpel/unit-test.wsdl"
use="literal"/>
+ </wsdl:input>
+ </wsdl:operation>
+ <wsdl:operation name="EndpointReference">
+ <soap:operation soapAction="" style="rpc"/>
+ <wsdl:input>
+ <soap:body namespace="http://ode/bpel/unit-test.wsdl"
use="literal"/>
+ </wsdl:input>
+ </wsdl:operation>
+ </wsdl:binding>
+
+ <!-- This service should be used to start the example. -->
+ <wsdl:service name="MSMainExecuteService">
+ <wsdl:port name="MSExecutePort"
binding="tns:MSExecuteBinding">
+ <soap:address
location="http://localhost:8080/ode/processes/MSMainExecuteService"/>
+ </wsdl:port>
+ </wsdl:service>
+
+ <!-- This service is internal, only used by the responder. -->
+ <wsdl:service name="MSMainService">
+ <wsdl:port name="MSMainPort"
binding="tns:MSMainBinding">
+ <soap:address
location="http://localhost:8080/ode/processes/MSMainService"/>
+ </wsdl:port>
+ </wsdl:service>
+
+ <!-- Service responding to the main service requests. -->
+ <wsdl:service name="MSResponderService">
+ <wsdl:port name="MSResponderPort"
binding="tns:MSResponderBinding">
+ <soap:address
location="http://localhost:8080/ode/processes/MSResponderService"/>
+ </wsdl:port>
+ </wsdl:service>
+
+ <plnk:partnerLinkType name="ResponderPartnerLinkType">
+ <plnk:role name="responder"
portType="tns:MSResponderPortType"/>
+ <plnk:role name="main" portType="tns:MSMainPortType"/>
+ </plnk:partnerLinkType>
+
+ <plnk:partnerLinkType name="ExecutePartnerLinkType">
+ <plnk:role name="executor"
portType="tns:MSExecutePortType"/>
+ </plnk:partnerLinkType>
+</wsdl:definitions>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionJbiTest/Responder.bpel
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionJbiTest/Responder.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionJbiTest/Responder.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,92 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<process name="MagicSessionResponder"
+ targetNamespace="http://ode/bpel/responder"
+
xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
+ xmlns:tns="http://ode/bpel/responder"
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:resp="http://ode/bpel/unit-test.wsdl">
+
+ <import location="Main.wsdl"
namespace="http://ode/bpel/unit-test.wsdl"
+
importType="http://schemas.xmlsoap.org/wsdl/" />
+
+ <partnerLinks>
+ <partnerLink name="mainPartnerLink"
partnerLinkType="resp:ResponderPartnerLinkType"
+ myRole="responder" partnerRole="main"
initializePartnerRole="no"/>
+ </partnerLinks>
+
+ <variables>
+ <variable name="dummy2"
messageType="resp:InitiateMessage"/>
+ <variable name="dummy3"
messageType="resp:CallbackMessage"/>
+ <variable name="dummy4"
messageType="resp:DoubleCallMessage"/>
+ <variable name="dummy5"
messageType="resp:DoubleCallbackMessage"/>
+ <variable name="eprmessage"
messageType="resp:TripleCallMessage"/>
+ <variable name="dummy6"
messageType="resp:TripleCallbackMessage"/>
+ </variables>
+
+ <sequence>
+ <!-- Starting process and first callback -->
+ <receive name="start" partnerLink="mainPartnerLink"
variable="dummy2"
+ portType="resp:MSResponderPortType" operation="initiate"
createInstance="yes"/>
+ <assign>
+ <copy>
+ <from>$dummy2.reply-to/*</from>
+ <to partnerLink="mainPartnerLink"/>
+ </copy>
+ <copy>
+ <from>123</from>
+ <to variable="dummy3" part="payload"/>
+ </copy>
+ </assign>
+ <invoke name="callback" partnerLink="mainPartnerLink"
+ portType="resp:MSMainPortType" operation="callback"
inputVariable="dummy3"/>
+
+ <!-- Second callback -->
+ <receive name="doubleCall" partnerLink="mainPartnerLink"
variable="dummy4"
+ portType="resp:MSResponderPortType"
operation="doubleCall"/>
+ <assign>
+ <copy>
+ <from>123</from>
+ <to variable="dummy5" part="payload"/>
+ </copy>
+ </assign>
+ <invoke name="doubleCallback" partnerLink="mainPartnerLink"
+ portType="resp:MSMainPortType" operation="doubleCallback"
inputVariable="dummy5"/>
+
+ <!-- Callback on the epr explicitly provided by partner in the message
+ (demonstrating assignment) -->
+ <receive name="eprPassing" partnerLink="mainPartnerLink"
variable="eprmessage"
+ portType="resp:MSResponderPortType"
operation="EndpointReference"/>
+ <assign>
+ <copy>
+ <from>$eprmessage.payload/*</from>
+ <to partnerLink="mainPartnerLink"/>
+ </copy>
+ <copy>
+ <from>123</from>
+ <to variable="dummy6" part="payload"/>
+ </copy>
+ </assign>
+ <invoke name="tripleCallback" partnerLink="mainPartnerLink"
+ portType="resp:MSMainPortType" operation="tripleCallback"
inputVariable="dummy6"/>
+
+ </sequence>
+</process>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionJbiTest/deploy.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionJbiTest/deploy.xml
(rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionJbiTest/deploy.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,44 @@
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<deploy
xmlns="http://www.apache.org/ode/schemas/dd/2007/03"
+ xmlns:main="http://ode/bpel/unit-test"
+ xmlns:mws="http://ode/bpel/unit-test.wsdl"
+ xmlns:resp="http://ode/bpel/responder">
+
+ <process name="main:MagicSessionMain">
+ <provide partnerLink="executePartnerLink">
+ <service name="mws:MSMainExecuteService"
port="MSExecutePort"/>
+ </provide>
+ <provide partnerLink="responderPartnerLink">
+ <service name="mws:MSMainService" port="MSMainPort"/>
+ </provide>
+ <invoke partnerLink="responderPartnerLink">
+ <service name="mws:MSResponderService"
port="MSResponderPort"/>
+ </invoke>
+ </process>
+ <process name="resp:MagicSessionResponder">
+ <type>resp:MagicSessionResponder</type>
+ <provide partnerLink="mainPartnerLink">
+ <service name="mws:MSResponderService"
port="MSResponderPort"/>
+ </provide>
+ <invoke partnerLink="mainPartnerLink">
+ <service name="mws:MSMainService" port="MSMainPort"/>
+ </invoke>
+ </process>
+</deploy>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionJbiTest/smx.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionJbiTest/smx.xml
(rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionJbiTest/smx.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,39 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+
http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+-->
+<beans
xmlns:sm="http://servicemix.apache.org/config/1.0"
+
xmlns:http="http://servicemix.apache.org/http/1.0"
+
xmlns:eip="http://servicemix.apache.org/eip/1.0"
+
xmlns:util="http://www.springframework.org/schema/util"
+
xmlns:jencks="http://jencks.org/2.0"
+ >
+
+ <util:map id="jndiEntries">
+ <entry key="java:comp/env/jdbc/ode"
value-ref="odeDS"/>
+ </util:map>
+
+ <sm:container
+ id="jbi"
+ embedded="true"
+ rootDir="target/test/smx"
+ transactionManager="#transactionManager"
+ depends-on="jndi"
+ >
+ </sm:container>
+</beans>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionJbiTest/test.properties
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionJbiTest/test.properties
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/MagicSessionJbiTest/test.properties 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,22 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+#
http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+nmr.service={http://ode/bpel/unit-test.wsdl}MSMainExecuteService
+nmr.operation=execute
+request=<msg><payload>fire!</payload></msg>
+response=.*OK.*
+
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/OnEventAlarmJbiTest/OnEventCorrelation.bpel
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/OnEventAlarmJbiTest/OnEventCorrelation.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/OnEventAlarmJbiTest/OnEventCorrelation.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,89 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<bpws:process
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns="http://sample.bpel.org/bpel/sampleArtifacts"
xmlns:tns="http://sample.bpel.org/bpel/sample"
exitOnStandardFault="yes" name="OnEventCorrelation"
suppressJoinFailure="yes"
targetNamespace="http://sample.bpel.org/bpel/sample"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelationArtifacts.wsdl"
namespace="http://sample.bpel.org/bpel/sampleArtifacts"/>
+ <bpws:partnerLinks>
+ <bpws:partnerLink myRole="OnEventCorrelationProvider"
name="client" partnerLinkType="tns:OnEventCorrelation"/>
+ </bpws:partnerLinks>
+ <bpws:variables>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="input"/>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="output"/>
+ </bpws:variables>
+ <bpws:correlationSets>
+ <bpws:correlationSet name="CorrelationSet"
properties="ns:input"/>
+ </bpws:correlationSets>
+ <bpws:sequence name="main">
+ <bpws:scope>
+ <bpws:sequence>
+ <bpws:receive createInstance="yes" operation="initiate"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input">
+ <bpws:correlations>
+ <bpws:correlation initiate="yes"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'test1'</bpws:from>
+ <bpws:to>$output.payload</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="initiate" partnerLink="client"
variable="output"/>
+ </bpws:sequence>
+ </bpws:scope>
+ <bpws:scope>
+ <bpws:eventHandlers>
+ <bpws:onEvent operation="complete" partnerLink="client"
portType="tns:OnEventCorrelation" variable="input"
messageType="tns:OnEventCorrelationMessage">
+ <bpws:correlations>
+ <bpws:correlation initiate="no"
set="CorrelationSet"/>
+ </bpws:correlations>
+ <bpws:scope>
+ <bpws:sequence>
+ <bpws:assign>
+ <bpws:copy>
+
<bpws:from>concat('ok2',$output.payload)</bpws:from>
+ <bpws:to>$output.payload</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="complete"
partnerLink="client" variable="output"/>
+ </bpws:sequence>
+ </bpws:scope>
+ </bpws:onEvent>
+ <bpws:onAlarm>
+ <bpws:for>'PT1S'</bpws:for>
+ <bpws:scope>
+ <bpws:sequence>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'ok3'</bpws:from>
+ <bpws:to>$output.payload</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ </bpws:sequence>
+ </bpws:scope>
+ </bpws:onAlarm>
+ </bpws:eventHandlers>
+ <bpws:sequence>
+ <bpws:wait>
+ <bpws:for>'PT10000S'</bpws:for>
+ </bpws:wait>
+ </bpws:sequence>
+ </bpws:scope>
+ </bpws:sequence>
+</bpws:process>
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/OnEventAlarmJbiTest/OnEventCorrelation.wsdl
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/OnEventAlarmJbiTest/OnEventCorrelation.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/OnEventAlarmJbiTest/OnEventCorrelation.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,66 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions
xmlns="http://schemas.xmlsoap.org/wsdl/"
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
xmlns:tns="http://sample.bpel.org/bpel/sample"
xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/"
name="OnEventCorrelation"
targetNamespace="http://sample.bpel.org/bpel/sample"
+xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+>
+ <message name="OnEventCorrelationMessage">
+ <part type="xsd:string" name="payload"/>
+ <part type="xsd:string" name="payload2"/>
+ </message>
+ <portType name="OnEventCorrelation">
+ <operation name="initiate">
+ <input message="tns:OnEventCorrelationMessage"/>
+ <output message="tns:OnEventCorrelationMessage"/>
+ </operation>
+ <operation name="complete">
+ <input message="tns:OnEventCorrelationMessage"/>
+ <output message="tns:OnEventCorrelationMessage"/>
+ </operation>
+ </portType>
+ <binding name="OnEventCorrelationBinding"
type="tns:OnEventCorrelation">
+ <wsdlsoap:binding style="rpc"
transport="http://schemas.xmlsoap.org/soap/http"/>
+ <operation name="initiate">
+ <wsdlsoap:operation soapAction="initiate"/>
+ <input>
+ <wsdlsoap:body use="literal"/>
+ </input>
+ <output>
+ <wsdlsoap:body use="literal"/>
+ </output>
+ </operation>
+ <operation name="complete">
+ <wsdlsoap:operation soapAction="complete"/>
+ <input>
+ <wsdlsoap:body use="literal"/>
+ </input>
+ <output>
+ <wsdlsoap:body use="literal"/>
+ </output>
+ </operation>
+ </binding>
+ <service name="OnEventCorrelation">
+ <port binding="tns:OnEventCorrelationBinding"
name="OnEventCorrelation">
+ <wsdlsoap:address
location="http://localhost:8080/ode/processes/OnEventCorrelation/"/>
+ </port>
+ </service>
+ <plnk:partnerLinkType name="OnEventCorrelation">
+ <plnk:role name="OnEventCorrelationProvider"
portType="tns:OnEventCorrelation"/>
+ </plnk:partnerLinkType>
+</definitions>
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/OnEventAlarmJbiTest/OnEventCorrelationArtifacts.wsdl
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/OnEventAlarmJbiTest/OnEventCorrelationArtifacts.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/OnEventAlarmJbiTest/OnEventCorrelationArtifacts.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns:tns="http://sample.bpel.org/bpel/sampleArtifacts"
+
xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop"
+
xmlns:xs="http://www.w3.org/2001/XMLSchema"
+
xmlns:bpel="http://sample.bpel.org/bpel/sample"
+ name="OnEventCorrelationArtifacts"
+
targetNamespace="http://sample.bpel.org/bpel/sampleArtifacts"
+
xmlns="http://schemas.xmlsoap.org/wsdl/"
+ >
+<vprop:property name="input" type="xs:string"/>
+<vprop:propertyAlias messageType="bpel:OnEventCorrelationMessage"
part="payload" propertyName="tns:input">
+<!--vprop:query><![CDATA[bpel:input]]></vprop:query-->
+</vprop:propertyAlias>
+<import location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+</definitions>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/OnEventAlarmJbiTest/deploy.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/OnEventAlarmJbiTest/deploy.xml
(rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/OnEventAlarmJbiTest/deploy.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,31 @@
+<?xml version='1.0' encoding='UTF-8'?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<dd:deploy
xmlns:dd="http://www.apache.org/ode/schemas/dd/2007/03"
+
xmlns:bpel="http://sample.bpel.org/bpel/sample"
+ >
+
+ <dd:process
+ name="bpel:OnEventCorrelation"
fileName="OnEventCorrelation.bpel">
+ <!--dd:process-events generate="none"/-->
+ <dd:provide partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelation"
port="OnEventCorrelation" />
+ </dd:provide>
+ </dd:process>
+</dd:deploy>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/OnEventAlarmJbiTest/smx.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/OnEventAlarmJbiTest/smx.xml
(rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/OnEventAlarmJbiTest/smx.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,60 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+
http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+-->
+<beans
xmlns:sm="http://servicemix.apache.org/config/1.0"
+
xmlns:http="http://servicemix.apache.org/http/1.0"
+
xmlns:eip="http://servicemix.apache.org/eip/1.0"
+
xmlns:util="http://www.springframework.org/schema/util"
+
xmlns:jencks="http://jencks.org/2.0"
+ xmlns:mws="http://ode/bpel/unit-test.wsdl"
+
xmlns:bpel="http://sample.bpel.org/bpel/sample"
+ >
+
+ <util:map id="jndiEntries">
+ <entry key="java:comp/env/jdbc/ode"
value-ref="odeDS"/>
+ </util:map>
+
+ <sm:container
+ id="jbi"
+ embedded="true"
+ rootDir="target/test/smx"
+ transactionManager="#transactionManager"
+ depends-on="jndi"
+
+ <sm:activationSpecs>
+ <sm:activationSpec id="ms-eip">
+ <sm:component>
+ <eip:component>
+ <eip:endpoints>
+ <eip:content-based-router service="bpel:OnEventCorrelation2Fwd"
endpoint="OnEventCorrelation2" forwardOperation="true">
+ <eip:rules>
+ <eip:routing-rule>
+ <eip:target>
+ <eip:exchange-target service="bpel:OnEventCorrelation2"/>
+ </eip:target>
+ </eip:routing-rule>
+ </eip:rules>
+ </eip:content-based-router>
+ </eip:endpoints>
+ </eip:component>
+ </sm:component>
+ </sm:activationSpec>
+ </sm:activationSpecs>
+ </sm:container>
+</beans>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/OnEventAlarmJbiTest/test.properties
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/OnEventAlarmJbiTest/test.properties
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/OnEventAlarmJbiTest/test.properties 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,26 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+#
http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+1nmr.service={http://sample.bpel.org/bpel/sample}OnEventCorrelation
+1nmr.operation=initiate
+1request=<message><payload>1000</payload><payload2>t</payload2></message>
+1response=.*test1.*
+2delay=2000
+3nmr.service={http://sample.bpel.org/bpel/sample}OnEventCorrelation
+3nmr.operation=complete
+3request=<message><payload>1000</payload><payload2>t2</payload2></message>
+3response=.*ok2ok3.*
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/OnEventCorrelation.bpel
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/OnEventCorrelation.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/OnEventCorrelation.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,130 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<bpws:process
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns="http://sample.bpel.org/bpel/sampleArtifacts"
xmlns:tns="http://sample.bpel.org/bpel/sample"
xmlns:ode="http://www.apache.org/ode/type/extension"
exitOnStandardFault="yes" name="OnEventCorrelation"
suppressJoinFailure="yes"
targetNamespace="http://sample.bpel.org/bpel/sample"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelationArtifacts.wsdl"
namespace="http://sample.bpel.org/bpel/sampleArtifacts"/>
+ <bpws:partnerLinks>
+ <bpws:partnerLink myRole="OnEventCorrelationProvider"
partnerRole="OnEventCorrelationProvider" name="client"
partnerLinkType="tns:OnEventCorrelation"/>
+ <bpws:partnerLink partnerRole="OnEventCorrelationProvider"
name="client2" partnerLinkType="tns:OnEventCorrelation"/>
+ </bpws:partnerLinks>
+ <bpws:variables>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="input"/>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="output"/>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="output2"/>
+ <bpws:variable type="xsd:int" name="i"/>
+ <bpws:variable type="xsd:int" name="j"/>
+ </bpws:variables>
+ <bpws:correlationSets>
+ <bpws:correlationSet name="CorrelationSet" properties="ns:input
ns:input2"/>
+ </bpws:correlationSets>
+ <bpws:sequence name="main">
+ <bpws:scope>
+ <bpws:sequence>
+ <bpws:receive createInstance="yes" operation="initiate"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex1">
+ <bpws:correlations>
+ <bpws:correlation initiate="yes"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:invoke partnerLink="client" operation="initiate"
outputVariable="output" inputVariable="input"/>
+
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat('first-', $ode:currentEventDateTime,
';', $output.payload)</bpws:from>
+ <bpws:to>$output.payload</bpws:to>
+ </bpws:copy>
+ <bpws:copy>
+ <bpws:from>0</bpws:from>
+ <bpws:to>$i</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+
+ <bpws:if>
+ <bpws:condition>$input.payload2 =
'livetest'</bpws:condition>
+ <bpws:sequence>
+ <bpws:invoke partnerLink="client"
operation="complete" outputVariable="output2"
inputVariable="input"/>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat('second-', $ode:currentEventDateTime,
';', $output2.payload, ";", $output.payload)</bpws:from>
+ <bpws:to>$output.payload</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ </bpws:sequence>
+ </bpws:if>
+
+ <bpws:reply operation="initiate" partnerLink="client"
variable="output" messageExchange="mex1"/>
+ <bpws:if>
+ <bpws:condition>$input.payload2 =
'rollbackOnFault'</bpws:condition>
+ <bpws:throw faultName="abc"/>
+ </bpws:if>
+ </bpws:sequence>
+ </bpws:scope>
+ <bpws:while>
+ <bpws:condition>$i < 4 </bpws:condition>
+ <bpws:sequence>
+ <bpws:empty name="e1"/>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>$i + 1</bpws:from>
+ <bpws:to>$i</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:pick>
+ <bpws:onMessage operation="initiate"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex2">
+ <bpws:correlations>
+ <bpws:correlation initiate="no"
set="CorrelationSet"/>
+ </bpws:correlations>
+ <bpws:sequence>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat('request-', $ode:currentEventDateTime,
';', $output.payload)</bpws:from>
+ <bpws:to>$output.payload</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="initiate"
partnerLink="client" variable="output"
messageExchange="mex2"/>
+ </bpws:sequence>
+ </bpws:onMessage>
+ <bpws:onAlarm>
+ <bpws:until>$ode:currentEventDateTime +
xsd:dayTimeDuration('PT10S')</bpws:until>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat('timer-',$ode:currentEventDateTime,
';', $output.payload)</bpws:from>
+ <bpws:to>$output.payload</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ </bpws:onAlarm>
+ </bpws:pick>
+ </bpws:sequence>
+ </bpws:while>
+
+
+ <bpws:receive createInstance="no" operation="initiate"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex3">
+ <bpws:correlations>
+ <bpws:correlation initiate="no"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>concat('final-',
$ode:currentEventDateTime)</bpws:from>
+ <bpws:to>$output.payload2</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="initiate" partnerLink="client"
variable="output" messageExchange="mex3"/>
+ </bpws:sequence>
+</bpws:process>
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/OnEventCorrelation.wsdl
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/OnEventCorrelation.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/OnEventCorrelation.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,66 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions
xmlns="http://schemas.xmlsoap.org/wsdl/"
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
xmlns:tns="http://sample.bpel.org/bpel/sample"
xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/"
name="OnEventCorrelation"
targetNamespace="http://sample.bpel.org/bpel/sample"
+xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+>
+ <message name="OnEventCorrelationMessage">
+ <part type="xsd:string" name="payload"/>
+ <part type="xsd:string" name="payload2"/>
+ </message>
+ <portType name="OnEventCorrelation">
+ <operation name="initiate">
+ <input message="tns:OnEventCorrelationMessage"/>
+ <output message="tns:OnEventCorrelationMessage"/>
+ </operation>
+ <operation name="complete">
+ <input message="tns:OnEventCorrelationMessage"/>
+ <output message="tns:OnEventCorrelationMessage"/>
+ </operation>
+ </portType>
+ <binding name="OnEventCorrelationBinding"
type="tns:OnEventCorrelation">
+ <wsdlsoap:binding style="rpc"
transport="http://schemas.xmlsoap.org/soap/http"/>
+ <operation name="initiate">
+ <wsdlsoap:operation soapAction="initiate"/>
+ <input>
+ <wsdlsoap:body use="literal"/>
+ </input>
+ <output>
+ <wsdlsoap:body use="literal"/>
+ </output>
+ </operation>
+ <operation name="complete">
+ <wsdlsoap:operation soapAction="complete"/>
+ <input>
+ <wsdlsoap:body use="literal"/>
+ </input>
+ <output>
+ <wsdlsoap:body use="literal"/>
+ </output>
+ </operation>
+ </binding>
+ <service name="OnEventCorrelation">
+ <port binding="tns:OnEventCorrelationBinding"
name="OnEventCorrelation">
+ <wsdlsoap:address
location="http://localhost:8080/ode/processes/OnEventCorrelation/"/>
+ </port>
+ </service>
+ <plnk:partnerLinkType name="OnEventCorrelation">
+ <plnk:role name="OnEventCorrelationProvider"
portType="tns:OnEventCorrelation"/>
+ </plnk:partnerLinkType>
+</definitions>
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/OnEventCorrelation2.bpel
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/OnEventCorrelation2.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/OnEventCorrelation2.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,73 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<bpws:process
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns="http://sample.bpel.org/bpel/sampleArtifacts"
xmlns:tns="http://sample.bpel.org/bpel/sample"
exitOnStandardFault="yes" name="OnEventCorrelation2"
suppressJoinFailure="yes"
targetNamespace="http://sample.bpel.org/bpel/sample"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelationArtifacts.wsdl"
namespace="http://sample.bpel.org/bpel/sampleArtifacts"/>
+ <bpws:partnerLinks>
+ <bpws:partnerLink myRole="OnEventCorrelationProvider"
name="client" partnerLinkType="tns:OnEventCorrelation"/>
+ </bpws:partnerLinks>
+ <bpws:variables>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="input"/>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="output"/>
+ <bpws:variable type="xsd:int" name="i"/>
+ <bpws:variable type="xsd:int" name="j"/>
+ </bpws:variables>
+ <bpws:correlationSets>
+ <bpws:correlationSet name="CorrelationSet" properties="ns:input
ns:input2"/>
+ </bpws:correlationSets>
+ <bpws:sequence name="main">
+ <bpws:scope>
+ <bpws:sequence>
+ <bpws:receive createInstance="yes" operation="initiate"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input" messageExchange="mex1">
+ <bpws:correlations>
+ <bpws:correlation initiate="yes"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'test2'</bpws:from>
+ <bpws:to>$output.payload</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="initiate" partnerLink="client"
variable="output" messageExchange="mex1"/>
+
+ <bpws:if>
+ <bpws:condition>$input.payload2 =
'livetest'</bpws:condition>
+ <bpws:sequence>
+ <bpws:receive createInstance="no"
operation="complete" partnerLink="client"
portType="tns:OnEventCorrelation" variable="input"
messageExchange="mex2">
+ <bpws:correlations>
+ <bpws:correlation initiate="no"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'test9'</bpws:from>
+ <bpws:to>$output.payload</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="complete"
partnerLink="client" variable="output"
messageExchange="mex2"/>
+ </bpws:sequence>
+ </bpws:if>
+
+ </bpws:sequence>
+
+ </bpws:scope>
+ </bpws:sequence>
+</bpws:process>
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/OnEventCorrelationArtifacts.wsdl
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/OnEventCorrelationArtifacts.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/OnEventCorrelationArtifacts.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,39 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<definitions
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns:tns="http://sample.bpel.org/bpel/sampleArtifacts"
+
xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop"
+
xmlns:xs="http://www.w3.org/2001/XMLSchema"
+
xmlns:bpel="http://sample.bpel.org/bpel/sample"
+ name="OnEventCorrelationArtifacts"
+
targetNamespace="http://sample.bpel.org/bpel/sampleArtifacts"
+
xmlns="http://schemas.xmlsoap.org/wsdl/"
+ >
+<vprop:property name="input" type="xs:string"/>
+<vprop:propertyAlias messageType="bpel:OnEventCorrelationMessage"
part="payload" propertyName="tns:input">
+<!--vprop:query><![CDATA[bpel:input]]></vprop:query-->
+</vprop:propertyAlias>
+<vprop:property name="input2" type="xs:string"/>
+<vprop:propertyAlias messageType="bpel:OnEventCorrelationMessage"
part="payload2" propertyName="tns:input2">
+<!--vprop:query><![CDATA[bpel:input]]></vprop:query-->
+</vprop:propertyAlias>
+<import location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+</definitions>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/deploy.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/deploy.xml
(rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/deploy.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,44 @@
+<?xml version='1.0' encoding='UTF-8'?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<dd:deploy
xmlns:dd="http://www.apache.org/ode/schemas/dd/2007/03"
+
xmlns:bpel="http://sample.bpel.org/bpel/sample"
+ >
+
+ <dd:process
+ name="bpel:OnEventCorrelation"
fileName="OnEventCorrelation.bpel">
+ <!--dd:process-events generate="none"/-->
+ <dd:property name="ble1">input</dd:property>
+ <dd:provide partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelationInit"
port="OnEventCorrelation" />
+ </dd:provide>
+ <dd:invoke partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelation2"
port="OnEventCorrelation2" />
+ </dd:invoke>
+ <dd:invoke partnerLink="client2">
+ <dd:service name="bpel:OnEventCorrelation2NonExistent"
port="OnEventCorrelation2" />
+ </dd:invoke>
+ </dd:process>
+ <dd:process
+ name="bpel:OnEventCorrelation2"
fileName="OnEventCorrelation2.bpel">
+ <dd:provide partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelation2"
port="OnEventCorrelation2" />
+ </dd:provide>
+ </dd:process>
+</dd:deploy>
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/initiateLiveRequest.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/initiateLiveRequest.xml
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/initiateLiveRequest.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<initiate>
+ <payload>abc7</payload>
+ <payload2>livetest</payload2>
+</initiate>
+
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/initiateRequest.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/initiateRequest.xml
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/initiateRequest.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<initiate>
+ <payload>abc7</payload>
+ <payload2>abc8</payload2>
+</initiate>
+
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/replayLiveRequest.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/replayLiveRequest.xml
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/replayLiveRequest.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,76 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<pmap:replay
xmlns:ns="http://www.apache.org/ode/pmapi/types/2006/08/02/"
xmlns:pmap="http://www.apache.org/ode/pmapi">
+ <replay>
+ <!--
+ <ns:replaceInstance>454277</ns:replaceInstance>
+ <ns:upgradeInstance>?</ns:upgradeInstance>
+-->
+ <ns:restoreInstance>
+ <ns:processType
xmlns:p="http://sample.bpel.org/bpel/sample">p:OnEventCorrel...
+ <ns:serviceConfig>
+ <ns:service
xmlns:sam="http://sample.bpel.org/bpel/sample">sam:OnEventCo...
+ <ns:replayType>
+ <ns:live/>
+ </ns:replayType>
+ </ns:serviceConfig>
+
+ <exchange
xmlns="http://www.apache.org/ode/pmapi/types/2006/08/02/">
+ <type>M</type>
+ <createTime>2009-04-01T16:41:29.873+02:00</createTime>
+ <service
xmlns:sam="http://sample.bpel.org/bpel/sample">sam:OnEventCo...
+ <operation>initiate</operation>
+ <in>
+ <initiate
xmlns:sam="http://sample.bpel.org/bpel/sample"
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns="">
+ <payload>abc7</payload>
+ <payload2>livetest</payload2>
+ </initiate>
+ </in>
+ <out>
+ <message xmlns="">
+ <payload>test1</payload>
+ <payload2 />
+ </message>
+ </out>
+ </exchange>
+
+ <exchange
xmlns="http://www.apache.org/ode/pmapi/types/2006/08/02/">
+ <type>M</type>
+ <createTime>2009-04-01T16:41:40.873+02:00</createTime>
+ <service
xmlns:sam="http://sample.bpel.org/bpel/sample">sam:OnEventCo...
+ <operation>initiate</operation>
+ <in>
+ <initiate
xmlns:sam="http://sample.bpel.org/bpel/sample"
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns="">
+ <payload>abc7</payload>
+ <payload2>livetest</payload2>
+ </initiate>
+ </in>
+ <out>
+ <message xmlns="">
+ <payload>test1</payload>
+ <payload2 />
+ </message>
+ </out>
+ </exchange>
+ </ns:restoreInstance>
+ </replay>
+ <balancerKey></balancerKey>
+</pmap:replay>
+
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/replayRequest.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/replayRequest.xml
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/replayRequest.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,68 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<pmap:replay
xmlns:ns="http://www.apache.org/ode/pmapi/types/2006/08/02/"
xmlns:pmap="http://www.apache.org/ode/pmapi">
+ <replay>
+<!--
+ <ns:replaceInstance>454277</ns:replaceInstance>
+ <ns:upgradeInstance>?</ns:upgradeInstance>
+-->
+ <ns:restoreInstance>
+ <ns:processType
xmlns:p="http://sample.bpel.org/bpel/sample">p:OnEventCorrel...
+ <exchange
xmlns="http://www.apache.org/ode/pmapi/types/2006/08/02/">
+ <type>M</type>
+ <createTime>2009-04-01T16:41:29.873+02:00</createTime>
+ <service
xmlns:sam="http://sample.bpel.org/bpel/sample">sam:OnEventCo...
+ <operation>initiate</operation>
+ <in>
+ <initiate
xmlns:sam="http://sample.bpel.org/bpel/sample"
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns="">
+ <payload>abc7</payload>
+ <payload2>abc8</payload2>
+ </initiate>
+ </in>
+ <out>
+ <message xmlns="">
+ <payload>test1</payload>
+ <payload2/>
+ </message>
+ </out>
+ </exchange>
+
+ <exchange
xmlns="http://www.apache.org/ode/pmapi/types/2006/08/02/">
+ <type>P</type>
+ <createTime>2009-04-01T16:41:32.998+02:00</createTime>
+ <service
xmlns:sam="http://sample.bpel.org/bpel/sample">sam:OnEventCo...
+ <operation>initiate</operation>
+ <in>
+ <initiate
xmlns:sam="http://sample.bpel.org/bpel/sample"
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns="">
+ <payload>abc7</payload>
+ <payload2>abc8</payload2>
+ </initiate>
+ </in>
+ <out>
+ <message xmlns="">
+ <payload>test5</payload>
+ <payload2/>
+ </message>
+ </out>
+ </exchange>
+ <exchange
xmlns="http://www.apache.org/ode/pmapi/types/2006/08/02/">
+ <type>M</type>
+ <createTime>2009-04-01T16:41:40.873+02:00</createTime>
+ <service
xmlns:sam="http://sample.bpel.org/bpel/sample">sam:OnEventCo...
+ <operation>initiate</operation>
+ <in>
+ <initiate
xmlns:sam="http://sample.bpel.org/bpel/sample"
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns="">
+ <payload>abc7</payload>
+ <payload2>abc8</payload2>
+ </initiate>
+ </in>
+ <out>
+ <message xmlns="">
+ <payload>test1</payload>
+ <payload2/>
+ </message>
+ </out>
+ </exchange>
+ </ns:restoreInstance>
+ </replay>
+</pmap:replay>
+
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/replayRollbackOnFault.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/replayRollbackOnFault.xml
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/replayRollbackOnFault.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,71 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<pmap:replay
xmlns:ns="http://www.apache.org/ode/pmapi/types/2006/08/02/"
xmlns:pmap="http://www.apache.org/ode/pmapi">
+ <replay>
+<!--
+ <ns:replaceInstance>454277</ns:replaceInstance>
+ <ns:upgradeInstance>?</ns:upgradeInstance>
+-->
+ <ns:restoreInstance>
+ <ns:processType
xmlns:p="http://sample.bpel.org/bpel/sample">p:OnEventCorrel...
+ <rollbackOnFault
xmlns="http://www.apache.org/ode/pmapi/types/2006/08/02/">tr...
+ <exchange
xmlns="http://www.apache.org/ode/pmapi/types/2006/08/02/">
+ <type>M</type>
+ <createTime>2009-04-01T16:41:29.873+02:00</createTime>
+ <service
xmlns:sam="http://sample.bpel.org/bpel/sample">sam:OnEventCo...
+ <operation>initiate</operation>
+ <in>
+ <initiate
xmlns:sam="http://sample.bpel.org/bpel/sample"
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns="">
+ <payload>abc7</payload>
+ <payload2>rollbackOnFault</payload2>
+ </initiate>
+ </in>
+ <out>
+ <message xmlns="">
+ <payload>test1</payload>
+ <payload2/>
+ </message>
+ </out>
+ </exchange>
+
+ <exchange
xmlns="http://www.apache.org/ode/pmapi/types/2006/08/02/">
+ <type>P</type>
+ <createTime>2009-04-01T16:41:32.998+02:00</createTime>
+ <service
xmlns:sam="http://sample.bpel.org/bpel/sample">sam:OnEventCo...
+ <operation>initiate</operation>
+ <in>
+ <initiate
xmlns:sam="http://sample.bpel.org/bpel/sample"
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns="">
+ <payload>abc7</payload>
+ <payload2>abc8</payload2>
+ </initiate>
+ </in>
+ <out>
+ <message xmlns="">
+ <payload>test5</payload>
+ <payload2/>
+ </message>
+ </out>
+ </exchange>
+
+ </ns:restoreInstance>
+ </replay>
+ <balancerKey></balancerKey>
+</pmap:replay>
+
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/replayRollbackOnFault2.xml
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/replayRollbackOnFault2.xml
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/replayRollbackOnFault2.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,71 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<pmap:replay
xmlns:ns="http://www.apache.org/ode/pmapi/types/2006/08/02/"
xmlns:pmap="http://www.apache.org/ode/pmapi">
+ <replay>
+<!--
+ <ns:replaceInstance>454277</ns:replaceInstance>
+ <ns:upgradeInstance>?</ns:upgradeInstance>
+-->
+ <ns:restoreInstance>
+ <ns:processType
xmlns:p="http://sample.bpel.org/bpel/sample">p:OnEventCorrel...
+ <rollbackOnFault
xmlns="http://www.apache.org/ode/pmapi/types/2006/08/02/">fa...
+ <exchange
xmlns="http://www.apache.org/ode/pmapi/types/2006/08/02/">
+ <type>M</type>
+ <createTime>2009-04-01T16:41:29.873+02:00</createTime>
+ <service
xmlns:sam="http://sample.bpel.org/bpel/sample">sam:OnEventCo...
+ <operation>initiate</operation>
+ <in>
+ <initiate
xmlns:sam="http://sample.bpel.org/bpel/sample"
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns="">
+ <payload>abc7</payload>
+ <payload2>rollbackOnFault</payload2>
+ </initiate>
+ </in>
+ <out>
+ <message xmlns="">
+ <payload>test1</payload>
+ <payload2/>
+ </message>
+ </out>
+ </exchange>
+
+ <exchange
xmlns="http://www.apache.org/ode/pmapi/types/2006/08/02/">
+ <type>P</type>
+ <createTime>2009-04-01T16:41:32.998+02:00</createTime>
+ <service
xmlns:sam="http://sample.bpel.org/bpel/sample">sam:OnEventCo...
+ <operation>initiate</operation>
+ <in>
+ <initiate
xmlns:sam="http://sample.bpel.org/bpel/sample"
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns="">
+ <payload>abc7</payload>
+ <payload2>abc8</payload2>
+ </initiate>
+ </in>
+ <out>
+ <message xmlns="">
+ <payload>test5</payload>
+ <payload2/>
+ </message>
+ </out>
+ </exchange>
+
+ </ns:restoreInstance>
+ </replay>
+ <balancerKey></balancerKey>
+</pmap:replay>
+
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/replayXQueryRequest.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/replayXQueryRequest.xml
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/replayXQueryRequest.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,95 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<pmap:replay
xmlns:ns="http://www.apache.org/ode/pmapi/types/2006/08/02/"
xmlns:pmap="http://www.apache.org/ode/pmapi">
+ <replay>
+ <!--
+ <ns:replaceInstance>454277</ns:replaceInstance>
+ <ns:upgradeInstance>?</ns:upgradeInstance>
+-->
+ <ns:restoreInstance>
+ <ns:processType
xmlns:p="http://sample.bpel.org/bpel/sample">p:OnEventCorrel...
+ <ns:serviceConfig>
+ <ns:service
xmlns:sam="http://sample.bpel.org/bpel/sample">sam:OnEventCo...
+ <ns:replayType>
+ <ns:mockQuery>
+ <ns:mockQueryResponse
xmlns:ns="http://www.apache.org/ode/pmapi/types/2006/08/02/"&am...
+ <ns:out>
+ <message xmlns="">
+ <payload>test6</payload>
+ <payload2/>
+ </message>
+ </ns:out>
+ </ns:mockQueryResponse>
+ <!--
+ <![CDATA[
+ <ns:mockQueryResponse
xmlns:ns="http://www.apache.org/ode/pmapi/types/2006/08/02/">
+ <ns:out>
+ <message xmlns="">
+ <payload>test6</payload>
+ <payload2/>
+ </message>
+ </ns:out>
+ </ns:mockQueryResponse>
+ ]]> -->
+ </ns:mockQuery>
+ </ns:replayType>
+ </ns:serviceConfig>
+
+ <exchange
xmlns="http://www.apache.org/ode/pmapi/types/2006/08/02/">
+ <type>M</type>
+ <createTime>2009-04-01T16:41:29.873+02:00</createTime>
+ <service
xmlns:sam="http://sample.bpel.org/bpel/sample">sam:OnEventCo...
+ <operation>initiate</operation>
+ <in>
+ <initiate
xmlns:sam="http://sample.bpel.org/bpel/sample"
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns="">
+ <payload>abc7</payload>
+ <payload2>abc8</payload2>
+ </initiate>
+ </in>
+ <out>
+ <message xmlns="">
+ <payload>test1</payload>
+ <payload2 />
+ </message>
+ </out>
+ </exchange>
+
+ <exchange
xmlns="http://www.apache.org/ode/pmapi/types/2006/08/02/">
+ <type>P</type>
+ <createTime>2009-04-01T16:41:32.998+02:00</createTime>
+ <service
xmlns:sam="http://sample.bpel.org/bpel/sample">sam:OnEventCo...
+ <operation>initiate</operation>
+ <in>
+ <initiate
xmlns:sam="http://sample.bpel.org/bpel/sample"
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns="">
+ <payload>abc7</payload>
+ <payload2>abc8</payload2>
+ </initiate>
+ </in>
+ <out>
+ <message xmlns="">
+ <payload>test5</payload>
+ <payload2 />
+ </message>
+ </out>
+ </exchange>
+ <exchange
xmlns="http://www.apache.org/ode/pmapi/types/2006/08/02/">
+ <type>M</type>
+ <createTime>2009-04-01T16:41:40.873+02:00</createTime>
+ <service
xmlns:sam="http://sample.bpel.org/bpel/sample">sam:OnEventCo...
+ <operation>initiate</operation>
+ <in>
+ <initiate
xmlns:sam="http://sample.bpel.org/bpel/sample"
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns="">
+ <payload>abc7</payload>
+ <payload2>abc8</payload2>
+ </initiate>
+ </in>
+ <out>
+ <message xmlns="">
+ <payload>test1</payload>
+ <payload2 />
+ </message>
+ </out>
+ </exchange>
+ </ns:restoreInstance>
+ </replay>
+</pmap:replay>
+
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/smx.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/smx.xml
(rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/smx.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,60 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+
http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+-->
+<beans
xmlns:sm="http://servicemix.apache.org/config/1.0"
+
xmlns:http="http://servicemix.apache.org/http/1.0"
+
xmlns:eip="http://servicemix.apache.org/eip/1.0"
+
xmlns:util="http://www.springframework.org/schema/util"
+
xmlns:jencks="http://jencks.org/2.0"
+ xmlns:mws="http://ode/bpel/unit-test.wsdl"
+
xmlns:bpel="http://sample.bpel.org/bpel/sample"
+ >
+
+ <util:map id="jndiEntries">
+ <entry key="java:comp/env/jdbc/ode"
value-ref="odeDS"/>
+ </util:map>
+
+ <sm:container
+ id="jbi"
+ embedded="true"
+ rootDir="target/test/smx"
+ transactionManager="#transactionManager"
+ depends-on="jndi"
+
+ <sm:activationSpecs>
+ <sm:activationSpec id="ms-eip">
+ <sm:component>
+ <eip:component>
+ <eip:endpoints>
+ <eip:content-based-router service="bpel:OnEventCorrelation2Fwd"
endpoint="OnEventCorrelation2" forwardOperation="true">
+ <eip:rules>
+ <eip:routing-rule>
+ <eip:target>
+ <eip:exchange-target service="bpel:OnEventCorrelation2"/>
+ </eip:target>
+ </eip:routing-rule>
+ </eip:rules>
+ </eip:content-based-router>
+ </eip:endpoints>
+ </eip:component>
+ </sm:component>
+ </sm:activationSpec>
+ </sm:activationSpecs>
+ </sm:container>
+</beans>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/test.properties
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/test.properties
(rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/ReplayerJbiTest/test.properties 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,54 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+#
http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+1nmr.service={http://www.apache.org/ode/pmapi}InstanceManagementService
+1nmr.operation=replay
+1request=(a)replayRequest.xml
+1response=.*
+2nmr.service={http://sample.bpel.org/bpel/sample}OnEventCorrelationInit
+2nmr.operation=initiate
+2request=(a)initiateRequest.xml
+2response=.*>timer-2009-04-01T14:42:00.873Z;timer-2009-04-01T14:41:50.873Z;request-2009-04-01T14:41:40.873Z;timer-2009-04-01T14:41:39.873Z;first-2009-04-01T14:41:29.873Z;test5<.*
+
+3nmr.service={http://www.apache.org/ode/pmapi}InstanceManagementService
+3nmr.operation=replay
+3request=(a)replayXQueryRequest.xml
+3response=.*
+4nmr.service={http://sample.bpel.org/bpel/sample}OnEventCorrelationInit
+4nmr.operation=initiate
+4request=(a)initiateRequest.xml
+4response=.*>timer-2009-04-01T14:42:00.873Z;timer-2009-04-01T14:41:50.873Z;request-2009-04-01T14:41:40.873Z;timer-2009-04-01T14:41:39.873Z;first-2009-04-01T14:41:29.873Z;test6<.*
+
+5nmr.service={http://www.apache.org/ode/pmapi}InstanceManagementService
+5nmr.operation=replay
+5request=(a)replayRollbackOnFault.xml
+5response=FAULT
+
+6nmr.service={http://www.apache.org/ode/pmapi}InstanceManagementService
+6nmr.operation=replay
+6request=(a)replayRollbackOnFault2.xml
+6response=.*
+
+7nmr.service={http://www.apache.org/ode/pmapi}InstanceManagementService
+7nmr.operation=replay
+7request=(a)replayLiveRequest.xml
+7response=.*
+
+8nmr.service={http://sample.bpel.org/bpel/sample}OnEventCorrelationInit
+8nmr.operation=initiate
+8request=(a)initiateLiveRequest.xml
+8response=.*>timer-2009-04-01T14:42:00.873Z;timer-2009-04-01T14:41:50.873Z;request-2009-04-01T14:41:40.873Z;timer-2009-04-01T14:41:39.873Z;second-2009-04-01T14:41:29.873Z;test9;first-2009-04-01T14:41:29.873Z;test2<.*
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/smx.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/smx.xml
(rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/smx.xml 2010-04-14 18:25:55
UTC (rev 620)
@@ -0,0 +1,40 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+
http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+-->
+<beans
xmlns:sm="http://servicemix.apache.org/config/1.0"
+
xmlns:http="http://servicemix.apache.org/http/1.0"
+
xmlns:eip="http://servicemix.apache.org/eip/1.0"
+
xmlns:util="http://www.springframework.org/schema/util"
+
xmlns:jencks="http://jencks.org/2.0"
+ xmlns:mws="http://ode/bpel/unit-test.wsdl"
+ >
+
+ <util:map id="jndiEntries">
+ <entry key="java:comp/env/jdbc/ode"
value-ref="odeDS"/>
+ </util:map>
+
+ <sm:container
+ id="jbi"
+ embedded="true"
+ rootDir="target/test/smx"
+ transactionManager="#transactionManager"
+ depends-on="jndi"
+
+ </sm:container>
+</beans>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/test.properties
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/test.properties
(rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/test.properties 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,48 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+#
http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+manualDeploy=true
+1deploy=v-1
+2nmr.service={http://sample.bpel.org/bpel/sample}OnEventCorrelation
+2nmr.operation=initiate
+2request=<msg><payload>test</payload><payload2/></msg>
+2response=.*test1.*
+3undeploy=v-1
+4deploy=v-1
+5deploy=v-2
+6nmr.service={http://sample.bpel.org/bpel/sample}OnEventCorrelation
+6nmr.operation=complete
+6request=<msg><payload>test</payload><payload2/></msg>
+6response=.*test3-old.*
+7nmr.service={http://sample.bpel.org/bpel/sample}OnEventCorrelation
+7nmr.operation=initiate
+7request=<msg><payload>test</payload><payload2/></msg>
+7response=.*test1.*
+8nmr.service={http://sample.bpel.org/bpel/sample}OnEventCorrelation
+8nmr.operation=complete
+8request=<msg><payload>test</payload><payload2/></msg>
+8response=.*test3-new.*
+9undeploy=v-1
+10nmr.service={http://sample.bpel.org/bpel/sample}OnEventCorrelation
+10nmr.operation=initiate
+10request=<msg><payload>test</payload><payload2/></msg>
+10response=.*test1.*
+11nmr.service={http://sample.bpel.org/bpel/sample}OnEventCorrelation
+11nmr.operation=complete
+11request=<msg><payload>test</payload><payload2/></msg>
+11response=.*test3-new.*
+
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-1/OnEventCorrelation.bpel
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-1/OnEventCorrelation.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-1/OnEventCorrelation.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,68 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+
http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+-->
+<bpws:process
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns="http://sample.bpel.org/bpel/sampleArtifacts"
xmlns:tns="http://sample.bpel.org/bpel/sample"
exitOnStandardFault="yes" name="OnEventCorrelation"
suppressJoinFailure="yes"
targetNamespace="http://sample.bpel.org/bpel/sample"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelationArtifacts.wsdl"
namespace="http://sample.bpel.org/bpel/sampleArtifacts"/>
+ <bpws:partnerLinks>
+ <bpws:partnerLink myRole="OnEventCorrelationProvider"
name="client" partnerLinkType="tns:OnEventCorrelation"/>
+ </bpws:partnerLinks>
+ <bpws:variables>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="input"/>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="output"/>
+ <bpws:variable type="xsd:int" name="i"/>
+ <bpws:variable type="xsd:int" name="j"/>
+ </bpws:variables>
+ <bpws:correlationSets>
+ <bpws:correlationSet name="CorrelationSet"
properties="ns:input"/>
+ </bpws:correlationSets>
+ <bpws:sequence name="main">
+ <bpws:scope>
+ <bpws:sequence>
+ <bpws:receive createInstance="yes" operation="initiate"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input">
+ <bpws:correlations>
+ <bpws:correlation initiate="yes"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'test1'</bpws:from>
+ <bpws:to>$output.payload</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="initiate" partnerLink="client"
variable="output"/>
+
+
+ <bpws:receive operation="complete" partnerLink="client"
portType="tns:OnEventCorrelation" variable="input">
+ <bpws:correlations>
+ <bpws:correlation initiate="no"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:empty name="e6"/>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'test3-old'</bpws:from>
+ <bpws:to>$output.payload</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="complete" partnerLink="client"
variable="output"/>
+ </bpws:sequence>
+ </bpws:scope>
+ </bpws:sequence>
+</bpws:process>
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-1/OnEventCorrelation.wsdl
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-1/OnEventCorrelation.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-1/OnEventCorrelation.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,66 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+
http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+-->
+<definitions
xmlns="http://schemas.xmlsoap.org/wsdl/"
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
xmlns:tns="http://sample.bpel.org/bpel/sample"
xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/"
name="OnEventCorrelation"
targetNamespace="http://sample.bpel.org/bpel/sample"
+xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+>
+ <message name="OnEventCorrelationMessage">
+ <part type="xsd:string" name="payload"/>
+ <part type="xsd:string" name="payload2"/>
+ </message>
+ <portType name="OnEventCorrelation">
+ <operation name="initiate">
+ <input message="tns:OnEventCorrelationMessage"/>
+ <output message="tns:OnEventCorrelationMessage"/>
+ </operation>
+ <operation name="complete">
+ <input message="tns:OnEventCorrelationMessage"/>
+ <output message="tns:OnEventCorrelationMessage"/>
+ </operation>
+ </portType>
+ <binding name="OnEventCorrelationBinding"
type="tns:OnEventCorrelation">
+ <wsdlsoap:binding style="rpc"
transport="http://schemas.xmlsoap.org/soap/http"/>
+ <operation name="initiate">
+ <wsdlsoap:operation soapAction="initiate"/>
+ <input>
+ <wsdlsoap:body use="literal"/>
+ </input>
+ <output>
+ <wsdlsoap:body use="literal"/>
+ </output>
+ </operation>
+ <operation name="complete">
+ <wsdlsoap:operation soapAction="complete"/>
+ <input>
+ <wsdlsoap:body use="literal"/>
+ </input>
+ <output>
+ <wsdlsoap:body use="literal"/>
+ </output>
+ </operation>
+ </binding>
+ <service name="OnEventCorrelation">
+ <port binding="tns:OnEventCorrelationBinding"
name="OnEventCorrelation">
+ <wsdlsoap:address
location="http://localhost:8080/ode/processes/OnEventCorrelation/"/>
+ </port>
+ </service>
+ <plnk:partnerLinkType name="OnEventCorrelation">
+ <plnk:role name="OnEventCorrelationProvider"
portType="tns:OnEventCorrelation"/>
+ </plnk:partnerLinkType>
+</definitions>
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-1/OnEventCorrelationArtifacts.wsdl
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-1/OnEventCorrelationArtifacts.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-1/OnEventCorrelationArtifacts.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+
http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+-->
+<definitions
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns:tns="http://sample.bpel.org/bpel/sampleArtifacts"
+
xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop"
+
xmlns:xs="http://www.w3.org/2001/XMLSchema"
+
xmlns:bpel="http://sample.bpel.org/bpel/sample"
+ name="OnEventCorrelationArtifacts"
+
targetNamespace="http://sample.bpel.org/bpel/sampleArtifacts"
+
xmlns="http://schemas.xmlsoap.org/wsdl/"
+ >
+<vprop:property name="input" type="xs:string"/>
+<vprop:propertyAlias messageType="bpel:OnEventCorrelationMessage"
part="payload" propertyName="tns:input">
+<!--vprop:query><![CDATA[bpel:input]]></vprop:query-->
+</vprop:propertyAlias>
+<import location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+</definitions>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-1/deploy.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-1/deploy.xml
(rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-1/deploy.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,31 @@
+<?xml version='1.0' encoding='UTF-8'?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+
http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+-->
+<dd:deploy
xmlns:dd="http://www.apache.org/ode/schemas/dd/2007/03"
+
xmlns:bpel="http://sample.bpel.org/bpel/sample"
+ >
+
+ <dd:process
+ name="bpel:OnEventCorrelation"
fileName="OnEventCorrelation.bpel">
+ <!--dd:process-events generate="none"/-->
+ <dd:provide partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelation"
port="OnEventCorrelation" />
+ </dd:provide>
+ </dd:process>
+</dd:deploy>
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-2/OnEventCorrelation.bpel
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-2/OnEventCorrelation.bpel
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-2/OnEventCorrelation.bpel 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,68 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+
http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+-->
+<bpws:process
xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns="http://sample.bpel.org/bpel/sampleArtifacts"
xmlns:tns="http://sample.bpel.org/bpel/sample"
exitOnStandardFault="yes" name="OnEventCorrelation"
suppressJoinFailure="yes"
targetNamespace="http://sample.bpel.org/bpel/sample"
expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+ <bpws:import
importType="http://schemas.xmlsoap.org/wsdl/"
location="OnEventCorrelationArtifacts.wsdl"
namespace="http://sample.bpel.org/bpel/sampleArtifacts"/>
+ <bpws:partnerLinks>
+ <bpws:partnerLink myRole="OnEventCorrelationProvider"
name="client" partnerLinkType="tns:OnEventCorrelation"/>
+ </bpws:partnerLinks>
+ <bpws:variables>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="input"/>
+ <bpws:variable messageType="tns:OnEventCorrelationMessage"
name="output"/>
+ <bpws:variable type="xsd:int" name="i"/>
+ <bpws:variable type="xsd:int" name="j"/>
+ </bpws:variables>
+ <bpws:correlationSets>
+ <bpws:correlationSet name="CorrelationSet"
properties="ns:input"/>
+ </bpws:correlationSets>
+ <bpws:sequence name="main">
+ <bpws:scope>
+ <bpws:sequence>
+ <bpws:receive createInstance="yes" operation="initiate"
partnerLink="client" portType="tns:OnEventCorrelation"
variable="input">
+ <bpws:correlations>
+ <bpws:correlation initiate="yes"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'test1'</bpws:from>
+ <bpws:to>$output.payload</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="initiate" partnerLink="client"
variable="output"/>
+
+
+ <bpws:receive operation="complete" partnerLink="client"
portType="tns:OnEventCorrelation" variable="input">
+ <bpws:correlations>
+ <bpws:correlation initiate="no"
set="CorrelationSet"/>
+ </bpws:correlations>
+ </bpws:receive>
+ <bpws:empty name="e6"/>
+ <bpws:assign>
+ <bpws:copy>
+ <bpws:from>'test3-new'</bpws:from>
+ <bpws:to>$output.payload</bpws:to>
+ </bpws:copy>
+ </bpws:assign>
+ <bpws:reply operation="complete" partnerLink="client"
variable="output"/>
+ </bpws:sequence>
+ </bpws:scope>
+ </bpws:sequence>
+</bpws:process>
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-2/OnEventCorrelation.wsdl
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-2/OnEventCorrelation.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-2/OnEventCorrelation.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,66 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+
http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+-->
+<definitions
xmlns="http://schemas.xmlsoap.org/wsdl/"
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
xmlns:tns="http://sample.bpel.org/bpel/sample"
xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/"
name="OnEventCorrelation"
targetNamespace="http://sample.bpel.org/bpel/sample"
+xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+>
+ <message name="OnEventCorrelationMessage">
+ <part type="xsd:string" name="payload"/>
+ <part type="xsd:string" name="payload2"/>
+ </message>
+ <portType name="OnEventCorrelation">
+ <operation name="initiate">
+ <input message="tns:OnEventCorrelationMessage"/>
+ <output message="tns:OnEventCorrelationMessage"/>
+ </operation>
+ <operation name="complete">
+ <input message="tns:OnEventCorrelationMessage"/>
+ <output message="tns:OnEventCorrelationMessage"/>
+ </operation>
+ </portType>
+ <binding name="OnEventCorrelationBinding"
type="tns:OnEventCorrelation">
+ <wsdlsoap:binding style="rpc"
transport="http://schemas.xmlsoap.org/soap/http"/>
+ <operation name="initiate">
+ <wsdlsoap:operation soapAction="initiate"/>
+ <input>
+ <wsdlsoap:body use="literal"/>
+ </input>
+ <output>
+ <wsdlsoap:body use="literal"/>
+ </output>
+ </operation>
+ <operation name="complete">
+ <wsdlsoap:operation soapAction="complete"/>
+ <input>
+ <wsdlsoap:body use="literal"/>
+ </input>
+ <output>
+ <wsdlsoap:body use="literal"/>
+ </output>
+ </operation>
+ </binding>
+ <service name="OnEventCorrelation">
+ <port binding="tns:OnEventCorrelationBinding"
name="OnEventCorrelation">
+ <wsdlsoap:address
location="http://localhost:8080/ode/processes/OnEventCorrelation/"/>
+ </port>
+ </service>
+ <plnk:partnerLinkType name="OnEventCorrelation">
+ <plnk:role name="OnEventCorrelationProvider"
portType="tns:OnEventCorrelation"/>
+ </plnk:partnerLinkType>
+</definitions>
Added:
branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-2/OnEventCorrelationArtifacts.wsdl
===================================================================
---
branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-2/OnEventCorrelationArtifacts.wsdl
(rev 0)
+++
branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-2/OnEventCorrelationArtifacts.wsdl 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+
http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+-->
+<definitions
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns:tns="http://sample.bpel.org/bpel/sampleArtifacts"
+
xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop"
+
xmlns:xs="http://www.w3.org/2001/XMLSchema"
+
xmlns:bpel="http://sample.bpel.org/bpel/sample"
+ name="OnEventCorrelationArtifacts"
+
targetNamespace="http://sample.bpel.org/bpel/sampleArtifacts"
+
xmlns="http://schemas.xmlsoap.org/wsdl/"
+ >
+<vprop:property name="input" type="xs:string"/>
+<vprop:propertyAlias messageType="bpel:OnEventCorrelationMessage"
part="payload" propertyName="tns:input">
+<!--vprop:query><![CDATA[bpel:input]]></vprop:query-->
+</vprop:propertyAlias>
+<import location="OnEventCorrelation.wsdl"
namespace="http://sample.bpel.org/bpel/sample"/>
+</definitions>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-2/deploy.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-2/deploy.xml
(rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/RetireJbiTest/v-2/deploy.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,31 @@
+<?xml version='1.0' encoding='UTF-8'?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+
http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+-->
+<dd:deploy
xmlns:dd="http://www.apache.org/ode/schemas/dd/2007/03"
+
xmlns:bpel="http://sample.bpel.org/bpel/sample"
+ >
+
+ <dd:process
+ name="bpel:OnEventCorrelation"
fileName="OnEventCorrelation.bpel">
+ <!--dd:process-events generate="none"/-->
+ <dd:provide partnerLink="client">
+ <dd:service name="bpel:OnEventCorrelation"
port="OnEventCorrelation" />
+ </dd:provide>
+ </dd:process>
+</dd:deploy>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/fault.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/fault.xml (rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/fault.xml 2010-04-14 18:25:55 UTC (rev
620)
@@ -0,0 +1,25 @@
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<fault
xmlns="http://java.sun.com/xml/ns/jbi/wsdl-11-wrapper">
+ <part
xmlns:t="http://www.example.org/test/">
+ <t:NewOperationFault>
+ <t:NewOperationFault>abc</t:NewOperationFault>
+ </t:NewOperationFault>
+ </part>
+</fault>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/fault1.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/fault1.xml (rev
0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/fault1.xml 2010-04-14 18:25:55 UTC (rev
620)
@@ -0,0 +1,25 @@
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<fault
xmlns="http://java.sun.com/xml/ns/jbi/wsdl-11-wrapper">
+ <part
xmlns:t="http://www.example.org/test/">
+ <t:NewOperationFault1>
+ <t:NewOperationFault1>abc1</t:NewOperationFault1>
+ </t:NewOperationFault1>
+ </part>
+</fault>
Modified: branches/ODE/ODE-1.x/jbi/src/test/resources/log4j.properties
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/log4j.properties 2010-04-14 15:43:12 UTC
(rev 619)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/log4j.properties 2010-04-14 18:25:55 UTC
(rev 620)
@@ -1,35 +1,52 @@
-#
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements. See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-#
-#
http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
-# implied.
-#
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-#
-
-#
-# The logging properties used during tests..
-#
-log4j.rootLogger=DEBUG, file
-#log4j.rootLogger=INFO, file
-
-log4j.appender.file=org.apache.log4j.FileAppender
-log4j.appender.file.File=target/test/test.log
-log4j.appender.file.layout=org.apache.log4j.PatternLayout
-log4j.appender.file.layout.ConversionPattern=%d{MM-dd@HH:mm:ss} %-5p (%13F:%L) %3x - %m%n
-
-log4j.appender.stdout=org.apache.log4j.ConsoleAppender
-log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
-log4j.appender.stdout.layout.ConversionPattern=%d{MM-dd@HH:mm:ss} %-5p (%13F:%L) %3x -
%m%n
-
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+#
http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+# implied.
+#
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+#
+
+#
+# The logging properties used during tests..
+#
+#log4j.rootLogger=DEBUG, file
+log4j.rootLogger=INFO, file
+
+log4j.appender.file=org.apache.log4j.FileAppender
+log4j.appender.file.File=target/test/test.log
+log4j.appender.file.layout=org.apache.log4j.PatternLayout
+log4j.appender.file.layout.ConversionPattern=%d{MM-dd@HH:mm:ss} %-5p (%13F:%L) %3x - %m%n
+
+log4j.appender.stdout=org.apache.log4j.ConsoleAppender
+log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
+log4j.appender.stdout.layout.ConversionPattern=%d{MM-dd@HH:mm:ss} %-5p (%13F:%L) %3x -
%m%n
+
+log4j.category.org.apache.servicemix.jbi.nmr.flow.seda=DEBUG
+#log4j.category.org.apache.ode.jbi.msgmap=TRACE
+#log4j.category.org.apache.ode.jbi.EndpointReferenceContextImpl=DEBUG
+#log4j.category.org.apache.ode.bpel=DEBUG
+#log4j.category.org.apache.ode.dao.jpa.CorrelatorDAOImpl=TRACE
+#log4j.category.org.apache.ode.dao.jpa.MessageDAOImpl=TRACE
+log4j.category.httpclient=DEBUG
+log4j.category.httpclient.Wire=DEBUG
+log4j.category.org.apache.ode.jbi.JbiTestBase=DEBUG
+#log4j.category.org.apache.ode.bpel.runtime.SCOPE=DEBUG
+#log4j.category.org.apache.ode.bpel.runtime.EH_EVENT=DEBUG
+#log4j.category.org.apache.ode.bpel.runtime.EH_ALARM=DEBUG
+#log4j.category.org.apache.ode.daohib.bpel.CorrelatorDaoImpl=DEBUG
+#log4j.category.org.apache.ode.bpel.elang=DEBUG
+#log4j.category.org.apache.ode.bpel.compiler=DEBUG
+log4j.category.org.apache.ode.bpel.iapi.BpelEventListener=DEBUG
+log4j.category.org.apache.ode.bpel.engine=DEBUG
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/smx-base.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/smx-base.xml (rev
0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/smx-base.xml 2010-04-14 18:25:55 UTC (rev
620)
@@ -0,0 +1,86 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+
http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+-->
+<beans
xmlns:sm="http://servicemix.apache.org/config/1.0"
+
xmlns:http="http://servicemix.apache.org/http/1.0"
+
xmlns:eip="http://servicemix.apache.org/eip/1.0"
+
xmlns:util="http://www.springframework.org/schema/util"
+
xmlns:jencks="http://jencks.org/2.0"
+ >
+
+ <bean id="transactionManager"
class="org.apache.geronimo.transaction.manager.GeronimoTransactionManager"/>
+
+ <jencks:connectionTracker id="connectionTracker"
geronimoTransactionManager="#transactionManager" />
+
+ <jencks:workManager
+ id="workManager"
+ threadPoolSize="200"
+ transactionManager="#transactionManager" />
+
+ <jencks:bootstrapContext
+ id="bootstrapContext"
+ workManager="#workManager"
+ transactionManager="#transactionManager" />
+
+ <jencks:poolingSupport
+ id="poolingSupport"
+ connectionMaxIdleMinutes="5"
+ poolMaxSize="20"
+ />
+
+ <jencks:connectionManager
+ id="connectionManager"
+ containerManagedSecurity="false"
+ transaction="local"
+ transactionManager="#transactionManager"
+ poolingSupport="#poolingSupport"
+ connectionTracker="#connectionTracker"
+ />
+
+ <bean id="odeMCF"
class="org.tranql.connector.derby.EmbeddedLocalMCF">
+ <property name="databaseName"
value="target/test/smx/ode/hibdb"/>
+ <property name="createDatabase" value="false"/>
+ <property name="userName" value = "sa"/>
+ <property name="password" value = ""/>
+ </bean>
+ <!--
+ <bean id="odeMCF"
class="org.tranql.connector.oracle.LocalMCF">
+ <property name="databaseName" value="XE"/>
+ <property name="userName" value="ode12"/>
+ <property name="password" value="ode12"/>
+ <property name="portNumber" value="1521"/>
+ <property name="serverName" value="localhost"/>
+ <property name="driverType" value="thin"/>
+ </bean>
+ -->
+
+ <bean id="odeDS"
class="org.jencks.factory.ConnectionFactoryFactoryBean">
+ <property name="managedConnectionFactory" ref="odeMCF"/>
+ <property name="connectionManager"
ref="connectionManager"/>
+ </bean>
+
+ <bean id="jndi"
+ class="org.apache.xbean.spring.jndi.SpringInitialContextFactory"
+ factory-method="makeInitialContext"
+ singleton="true"
+ depends-on="bootstrapContext"
+
+ <property name="entries"
ref="jndiEntries" />
+ </bean>
+</beans>
Added: branches/ODE/ODE-1.x/jbi/src/test/resources/test.wsdl
===================================================================
--- branches/ODE/ODE-1.x/jbi/src/test/resources/test.wsdl (rev 0)
+++ branches/ODE/ODE-1.x/jbi/src/test/resources/test.wsdl 2010-04-14 18:25:55 UTC (rev
620)
@@ -0,0 +1,72 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<wsdl:definitions
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:tns="http://www.example.org/test/"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema" name="test"
targetNamespace="http://www.example.org/test/">
+ <wsdl:types>
+ <xsd:schema
targetNamespace="http://www.example.org/test/">
+ <xsd:element name="NewOperation">
+ <xsd:complexType>
+ <xsd:sequence>
+ <xsd:element name="in" type="xsd:string"/>
+ </xsd:sequence>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="NewOperationResponse">
+ <xsd:complexType>
+ <xsd:sequence>
+ <xsd:element name="out" type="xsd:string"/>
+ </xsd:sequence>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="NewOperationFault">
+ <xsd:complexType>
+ <xsd:sequence>
+ <xsd:element name="NewOperationFault"
type="xsd:string"></xsd:element>
+ </xsd:sequence>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="NewOperationFault1">
+ <xsd:complexType>
+ <xsd:sequence>
+ <xsd:element name="NewOperationFault1"
type="xsd:string"></xsd:element>
+ </xsd:sequence>
+ </xsd:complexType>
+ </xsd:element>
+ </xsd:schema>
+ </wsdl:types>
+ <wsdl:message name="NewOperationRequest">
+ <wsdl:part element="tns:NewOperation" name="parameters"/>
+ </wsdl:message>
+ <wsdl:message name="NewOperationResponse">
+ <wsdl:part element="tns:NewOperationResponse"
name="parameters"/>
+ </wsdl:message>
+ <wsdl:message name="NewOperationFault">
+ <wsdl:part name="parameters"
element="tns:NewOperationFault"></wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="NewOperationFault1">
+ <wsdl:part name="parameters"
element="tns:NewOperationFault1"></wsdl:part>
+ </wsdl:message>
+ <wsdl:portType name="test">
+ <wsdl:operation name="NewOperation">
+ <wsdl:input message="tns:NewOperationRequest"/>
+ <wsdl:output message="tns:NewOperationResponse"/>
+ <wsdl:fault name="fault"
message="tns:NewOperationFault"></wsdl:fault>
+ <wsdl:fault name="fault1"
message="tns:NewOperationFault1"></wsdl:fault>
+ </wsdl:operation>
+ </wsdl:portType>
+ <wsdl:binding name="testSOAP" type="tns:test">
+ <soap:binding style="document"
transport="http://schemas.xmlsoap.org/soap/http"/>
+ <wsdl:operation name="NewOperation">
+ <soap:operation
soapAction="http://www.example.org/test/NewOperation"/>
+ <wsdl:input>
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output>
+ <soap:body use="literal"/>
+ </wsdl:output>
+ </wsdl:operation>
+ </wsdl:binding>
+ <wsdl:service name="test">
+ <wsdl:port binding="tns:testSOAP" name="testSOAP">
+ <soap:address
location="http://www.example.org/"/>
+ </wsdl:port>
+ </wsdl:service>
+</wsdl:definitions>
Added: branches/ODE/ODE-1.x/jbi-bundle/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi-bundle/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/jbi-bundle/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,130 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project
xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/maven-v4_0_0.xsd">
+
+ <!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+
http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jbi-bundle</artifactId>
+ <name>ODE :: JBI Bundle</name>
+ <packaging>bundle</packaging>
+ <modelVersion>4.0.0</modelVersion>
+
+ <properties>
+ <jbi.version>1.1.0</jbi.version>
+ </properties>
+
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.felix</groupId>
+ <artifactId>maven-bundle-plugin</artifactId>
+ <version>1.4.3</version>
+ <extensions>true</extensions>
+ <configuration>
+ <instructions>
+
<Bundle-SymbolicName>${pom.artifactId}</Bundle-SymbolicName>
+
<Export-Package>org.apache.ode*;version=${ode.version};-split-package:=merge-first</Export-Package>
+ <Import-Package>
+ !com.sun.mirror*,
+ !junit.framework*,
+ !org.apache.axis2.client*,
+ !org.apache.tools.ant*,
+ javax.jbi*;version="1.0",
+ javax.transaction*;version="1.1",
+ org.tranql.connector.jdbc,
+ org.apache.commons.httpclient*;version="3.0",
+ org.apache.commons.logging*;version="1.1",
+ org.apache.commons*,
+ org.apache.geronimo.transaction.manager;version="2.0",
+ org.osgi.service.command;version="[0.2,1)",
+ org.springframework.beans.factory.xml;version="2.5",
+ org.apache.geronimo.transaction.manager,
+ org.tranql.connector.jdbc,
+ org.w3c.dom,
+ org.xml.sax,
+ org.xml.sax.ext,
+ org.xml.sax.helpers,
+ org.jaxen.saxpath,
+ net.sf.saxon.xpath,
+ *;resolution:=optional
+ </Import-Package>
+<Embed-Dependency>*;inline=**.xsd|schemaorg_apache_xmlbeans/**|**.xml</Embed-Dependency>
+
+ <DynamicImport-Package>*</DynamicImport-Package>
+<Include-Resource>
+src/main/resources,
+@../dao-jpa-ojpa-derby/target/ode-dao-jpa-ojpa-derby-${project.version}.zip,
+@../dao-hibernate-db/target/ode-dao-hibernate-db-${project.version}.zip,
+</Include-Resource>
+
+ </instructions>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+ <dependencies>
+
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jbi</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-schemas</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-dao-hibernate</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-dao-jpa</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jbi</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.osgi</groupId>
+ <artifactId>org.osgi.core</artifactId>
+ <version>4.2.0</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.servicemix.specs</groupId>
+ <artifactId>org.apache.servicemix.specs.jbi-api-1.0</artifactId>
+ <version>${jbi.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>commons-io</groupId>
+ <artifactId>commons-io</artifactId>
+ </dependency>
+ </dependencies>
+</project>
Added: branches/ODE/ODE-1.x/jbi-bundle/src/main/filtered-resources/features.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi-bundle/src/main/filtered-resources/features.xml
(rev 0)
+++ branches/ODE/ODE-1.x/jbi-bundle/src/main/filtered-resources/features.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http///www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+<features>
+
<repository>mvn:org.apache.servicemix.nmr/apache-servicemix-nmr/${servicemix.nmr.version}/xml/features</repository>
+ <feature name="ode" version="${ode.version}">
+ <feature
version="${servicemix.nmr.version}">transaction</feature>
+
<bundle>mvn:org.apache.geronimo.specs/geronimo-jta_1.1_spec/${geronimo.specs.version}</bundle>
+
<bundle>mvn:org.apache.geronimo.specs/geronimo-jms_1.1_spec/${geronimo.specs.version}</bundle>
+
<bundle>mvn:org.apache.servicemix.specs/org.apache.servicemix.specs.stax-api-1.0/${servicemix.specs.version}</bundle>
+
<bundle>mvn:commons-collections/commons-collections/${commons.collections.version}</bundle>
+
<bundle>mvn:commons-pool/commons-pool/${commons.pool.version}</bundle>
+
<bundle>mvn:commons-lang/commons-lang/${commons.lang.version}</bundle>
+
<bundle>mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.commons-httpclient/${commons.httpclient.bundle.version}</bundle>
+ <bundle>mvn:org.apache.derby/derby/${derby.version}</bundle>
+
<bundle>mvn:org.apache.ode/ode-jbi-karaf/${ode.version}/jar/bundle</bundle>
+ </feature>
+</features>
Added:
branches/ODE/ODE-1.x/jbi-bundle/src/main/java/org/apache/ode/jbi/osgi/ServiceUnitActivator.java
===================================================================
---
branches/ODE/ODE-1.x/jbi-bundle/src/main/java/org/apache/ode/jbi/osgi/ServiceUnitActivator.java
(rev 0)
+++
branches/ODE/ODE-1.x/jbi-bundle/src/main/java/org/apache/ode/jbi/osgi/ServiceUnitActivator.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,119 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.ode.jbi.osgi;
+
+import java.io.File;
+import java.io.FileWriter;
+import java.io.InputStream;
+import java.net.URL;
+import java.util.Enumeration;
+
+import javax.jbi.component.Component;
+import javax.jbi.component.ServiceUnitManager;
+
+import org.apache.commons.io.IOUtils;
+import org.osgi.framework.Bundle;
+import org.osgi.framework.BundleActivator;
+import org.osgi.framework.BundleContext;
+import org.osgi.framework.ServiceReference;
+
+/**
+ * @author mproch
+ *
+ */
+public class ServiceUnitActivator implements BundleActivator {
+
+ File rootDir;
+ String generatedName;
+
+ public void start(BundleContext context) throws Exception {
+ generatedName = context.getBundle().getSymbolicName();
+ rootDir = context.getDataFile("bpelData");
+ rootDir.mkdirs();
+ Enumeration<?> en = context.getBundle().findEntries("/",
"*", false);
+ while (en.hasMoreElements()) {
+ copyOne(rootDir, (URL) en.nextElement());
+ }
+ ServiceReference[] refs = context.getAllServiceReferences(
+ "javax.jbi.component.Component",
"(&(NAME=OdeBpelEngine))");
+ if (refs == null || refs.length != 1) {
+ throw new RuntimeException("no appropriate service :(");
+ }
+ ServiceUnitManager suM = ((Component) context.getService(refs[0]))
+ .getServiceUnitManager();
+ ClassLoader l = Thread.currentThread().getContextClassLoader();
+ try {
+ ClassLoader suL = suM.getClass().getClassLoader();
+ Thread.currentThread().setContextClassLoader(new BundleClassLoader(suL,
context.getBundle()));
+ suM.deploy(generatedName, rootDir.getAbsolutePath());
+ suM.init(generatedName, rootDir.getAbsolutePath());
+ suM.start(generatedName);
+ } finally {
+ Thread.currentThread().setContextClassLoader(l);
+ }
+
+ }
+
+ private void copyOne(File dest, URL url) throws Exception {
+ File d = new File(dest, url.getPath());
+ InputStream str = url.openStream();
+ if (str != null) {
+ FileWriter wr = new FileWriter(d);
+ try {
+ IOUtils.copy(str, wr);
+ } finally {
+ wr.flush();
+ wr.close();
+ }
+ }
+ }
+
+ public void stop(BundleContext context) throws Exception {
+ ServiceReference[] refs = context.getAllServiceReferences(
+ "javax.jbi.component.Component",
"(&(NAME=OdeBpelEngine))");
+ if (refs == null || refs.length != 1) {
+ throw new RuntimeException("no appropriate service :(");
+ }
+ ServiceUnitManager suM = ((Component) context.getService(refs[0]))
+ .getServiceUnitManager();
+ suM.shutDown(generatedName);
+ suM.undeploy(generatedName, rootDir.getAbsolutePath());
+
+ }
+
+ public class BundleClassLoader extends ClassLoader {
+ private final Bundle delegate;
+
+ public BundleClassLoader(ClassLoader parent, Bundle delegate) {
+ super(parent);
+ this.delegate = delegate;
+ }
+
+ @Override
+ public Class<?> loadClass(String name) throws ClassNotFoundException {
+ try {
+ return getParent().loadClass(name);
+ } catch (Exception e) {
+ return delegate.loadClass(name);
+ }
+ }
+ }
+
+}
Added: branches/ODE/ODE-1.x/jbi-bundle/src/main/resources/META-INF/persistence.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi-bundle/src/main/resources/META-INF/persistence.xml
(rev 0)
+++ branches/ODE/ODE-1.x/jbi-bundle/src/main/resources/META-INF/persistence.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,57 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<persistence
xmlns="http://java.sun.com/xml/ns/persistence"
+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ version="1.0">
+ <persistence-unit name="ode-dao">
+ <!--
+ This properties file is used specifically by the
+ OpenJPA Enhancer.
+ -->
+
<provider>org.apache.openjpa.persistence.PersistenceProviderImpl</provider>
+ <class>org.apache.ode.dao.jpa.ActivityRecoveryDAOImpl</class>
+ <class>org.apache.ode.dao.jpa.CorrelationSetDAOImpl</class>
+ <class>org.apache.ode.dao.jpa.CorrelatorDAOImpl</class>
+ <class>org.apache.ode.dao.jpa.EventDAOImpl</class>
+ <class>org.apache.ode.dao.jpa.FaultDAOImpl</class>
+ <class>org.apache.ode.dao.jpa.MessageDAOImpl</class>
+ <class>org.apache.ode.dao.jpa.MessageExchangeDAOImpl</class>
+ <class>org.apache.ode.dao.jpa.MessageRouteDAOImpl</class>
+ <class>org.apache.ode.dao.jpa.PartnerLinkDAOImpl</class>
+ <class>org.apache.ode.dao.jpa.ProcessDAOImpl</class>
+ <class>org.apache.ode.dao.jpa.ProcessInstanceDAOImpl</class>
+ <class>org.apache.ode.dao.jpa.ScopeDAOImpl</class>
+ <class>org.apache.ode.dao.jpa.XmlDataDAOImpl</class>
+ <class>org.apache.ode.dao.jpa.CorrSetProperty</class>
+ <class>org.apache.ode.dao.jpa.MexProperty</class>
+ <class>org.apache.ode.dao.jpa.XmlDataProperty</class>
+ </persistence-unit>
+ <persistence-unit name="ode-store">
+ <!--
+ This properties file is used specifically by the
+ OpenJPA Enhancer.
+ -->
+
<provider>org.apache.openjpa.persistence.PersistenceProviderImpl</provider>
+ <class>org.apache.ode.store.jpa.ProcessConfDaoImpl</class>
+ <class>org.apache.ode.store.jpa.ProcessConfPropertyDaoImpl</class>
+ <class>org.apache.ode.store.jpa.DeploymentUnitDaoImpl</class>
+ <class>org.apache.ode.store.jpa.VersionTrackerDAOImpl</class>
+ </persistence-unit>
+</persistence>
Added: branches/ODE/ODE-1.x/jbi-bundle/src/main/resources/META-INF/spring/ode-jbi.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi-bundle/src/main/resources/META-INF/spring/ode-jbi.xml
(rev 0)
+++
branches/ODE/ODE-1.x/jbi-bundle/src/main/resources/META-INF/spring/ode-jbi.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,66 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+
http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+ -->
+<beans
xmlns="http://www.springframework.org/schema/beans"
+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+
xmlns:ctx="http://www.springframework.org/schema/context"
+
xmlns:osgi="http://www.springframework.org/schema/osgi"
+
xmlns:osgix="http://www.springframework.org/schema/osgi-compendium&q...
+
xmlns:util="http://www.springframework.org/schema/util"
+ xsi:schemaLocation="
+
http://www.springframework.org/schema/beans
+
http://www.springframework.org/schema/beans/spring-beans.xsd
+
http://www.springframework.org/schema/context
+
http://www.springframework.org/schema/context/spring-context.xsd
+
http://www.springframework.org/schema/util
+
http://www.springframework.org/schema/util/spring-util.xsd
+
http://www.springframework.org/schema/osgi
+
http://www.springframework.org/schema/osgi/spring-osgi.xsd
+
http://www.springframework.org/schema/osgi-compendium
+
http://www.springframework.org/schema/osgi-compendium/spring-osgi-compend...
+
+ <bean id="ode-config-properties"
class="org.apache.ode.jbi.OdeConfigProperties">
+ <constructor-arg ref="cmProps"/>
+ </bean>
+
+ <bean id="ode-component-lifecycle"
class="org.apache.ode.jbi.OdeLifeCycle">
+ <constructor-arg ref="ode-config-properties"/>
+ </bean>
+
+ <bean id="ode-jbi-component"
class="org.apache.ode.jbi.OdeComponent">
+ <constructor-arg ref="ode-component-lifecycle"/>
+ </bean>
+
+ <osgi:service ref="ode-jbi-component"
interface="javax.jbi.component.Component">
+ <osgi:service-properties>
+ <entry key="NAME" value="OdeBpelEngine" />
+ <entry key="TYPE" value="service-engine" />
+ </osgi:service-properties>
+ </osgi:service>
+
+ <osgix:cm-properties id="cmProps"
persistent-id="org.apache.ode.jbi">
+ <prop key="ode-jbi.pidNamespace">urn:ode-jbi</prop>
+ <prop key="ode-jbi.allowIncompleteDeployment">false</prop>
+ <prop key="ode-jbi.db.mode">EMBEDDED</prop>
+ <prop
key="ode-jbi.db.ext.dataSource">java:comp/env/jdbc/ode</prop>
+ <prop
key="ode-jbi.messageMapper">org.apache.ode.jbi.msgmap.ServiceMixMapper,org.apache.ode.jbi.msgmap.JbiWsdl11WrapperMapper</prop>
+ <prop key="ode-jbi.jca.port">0</prop>
+ </osgix:cm-properties>
+
+</beans>
Added: branches/ODE/ODE-1.x/jbi-karaf/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi-karaf/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/jbi-karaf/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+
http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+<project
xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/maven-v4_0_0.xsd">
+
+ <modelVersion>4.0.0</modelVersion>
+
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <artifactId>ode-jbi-karaf</artifactId>
+ <name>ODE :: JBI Karaf Features</name>
+ <packaging>jar</packaging>
+
+ <build>
+ <resources>
+ <resource>
+ <directory>src/main/resources</directory>
+ <filtering>true</filtering>
+ </resource>
+ </resources>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-resources-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>filter</id>
+ <phase>generate-resources</phase>
+ <goals>
+ <goal>resources</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>build-helper-maven-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>attach-artifacts</id>
+ <phase>package</phase>
+ <goals>
+ <goal>attach-artifact</goal>
+ </goals>
+ <configuration>
+ <artifacts>
+ <artifact>
+ <file>target/classes/features.xml</file>
+ <type>xml</type>
+ <classifier>features</classifier>
+ </artifact>
+ </artifacts>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+
+</project>
Added: branches/ODE/ODE-1.x/jbi-karaf/src/main/resources/features.xml
===================================================================
--- branches/ODE/ODE-1.x/jbi-karaf/src/main/resources/features.xml
(rev 0)
+++ branches/ODE/ODE-1.x/jbi-karaf/src/main/resources/features.xml 2010-04-14 18:25:55 UTC
(rev 620)
@@ -0,0 +1,76 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http///www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+<features>
+ <feature name="ode-core-deps" version="${ode.version}">
+ <feature>transaction</feature>
+
<bundle>mvn:commons-collections/commons-collections/${commons.collections.version}</bundle>
+ <bundle>mvn:commons-beanutils/commons-beanutils/1.8.2</bundle>
+ <bundle>mvn:commons-io/commons-io/1.4</bundle>
+ <bundle>wrap:mvn:jaxen/jaxen/1.1.1</bundle>
+
<bundle>mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.saxon/9.1.0.8_1-SNAPSHOT</bundle>
+ </feature>
+ <feature name="ode-core" version="${ode.version}">
+ <bundle>mvn:org.apache.ode/ode-jbi-bundle/${ode.version}</bundle>
+ </feature>
+ <feature name="ode-hib-deps" version="${project.version}">
+ <bundle>wrap:mvn:dom4j/dom4j/1.6.1</bundle>
+ <bundle>wrap:mvn:org.hibernate/hibernate/3.2.5.ga</bundle>
+ </feature>
+ <feature name="ode-jpa-deps" version="${project.version}">
+
<bundle>mvn:org.apache.servicemix.specs/org.apache.servicemix.specs.java-persistence-api-1.1.1/1.4.0</bundle>
+
<bundle>mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.serp/1.13.1_2</bundle>
+
<bundle>mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.openjpa/1.2.1_2</bundle>
+ </feature>
+ <feature name="ode-derby-deps"
version="${project.version}">
+ <bundle>wrap:mvn:org.tranql/tranql-connector/1.4</bundle>
+ <bundle>mvn:org.apache.derby/derby/${derby.version}</bundle>
+ </feature>
+ <feature name="ode-sqlserver-deps"
version="${project.version}">
+ <bundle>wrap:mvn:com.microsoft.sqlserver/sqljdbc/1.2</bundle>
+ <bundle>wrap:mvn:org.tranql/tranql-connector/1.4</bundle>
+
<bundle>wrap:mvn:org.tranql/tranql-connector-sqlserver2005-common/1.1</bundle>
+ </feature>
+ <feature name="ode-oracle-deps"
version="${project.version}">
+ <bundle>wrap:mvn:oracle/ojdbc5/11.1.0.6.0</bundle>
+ <bundle>wrap:mvn:org.tranql/tranql-connector/1.4</bundle>
+
<bundle>wrap:mvn:org.tranql/tranql-connector-oracle-common/1.4</bundle>
+ </feature>
+ <feature name="ode" version="${project.version}">
+ <feature
version="${project.version}">ode-derby-deps</feature>
+ <feature
version="${project.version}">ode-jpa-deps</feature>
+ <feature
version="${project.version}">ode-core-deps</feature>
+ <feature version="${project.version}">ode-core</feature>
+ </feature>
+ <feature name="ode-hib-oracle"
version="${project.version}">
+ <feature
version="${project.version}">ode-oracle-deps</feature>
+ <feature
version="${project.version}">ode-hib-deps</feature>
+ <feature
version="${project.version}">ode-core-deps</feature>
+ <feature version="${project.version}">ode-core</feature>
+ </feature>
+ <feature name="ode-hib-sqlserver"
version="${project.version}">
+ <feature
version="${project.version}">ode-sqlserver-deps</feature>
+ <feature
version="${project.version}">ode-hib-deps</feature>
+ <feature
version="${project.version}">ode-core-deps</feature>
+ <feature version="${project.version}">ode-core</feature>
+ </feature>
+ <feature name="examples-ode-ping-pong"
version="${project.version}">
+ <feature version="${project.version}">ode</feature>
+
<bundle>mvn:org.apache.ode.examples/ping-pong-bundle/${project.version}</bundle>
+ </feature>
+</features>
Added: branches/ODE/ODE-1.x/jbi-karaf-commands/org.apache.ode.commands.bnd
===================================================================
--- branches/ODE/ODE-1.x/jbi-karaf-commands/org.apache.ode.commands.bnd
(rev 0)
+++ branches/ODE/ODE-1.x/jbi-karaf-commands/org.apache.ode.commands.bnd 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,10 @@
+Bundle-Name: Apache ODE Commands
+Bundle-Version: ${ode.version}
+Require-Bundle: org.apache.ode.jbi
+
+Import-Package: org.osgi.service.command,*
+Private-Package: org.apache.ode.karaf.commands;version=${ode.version}
+Include-Resource: src/main/resources
+
+-removeheaders = Include-Resource
+
Added:
branches/ODE/ODE-1.x/jbi-karaf-commands/src/main/java/org/apache/ode/karaf/commands/OdeCommandsBase.java
===================================================================
---
branches/ODE/ODE-1.x/jbi-karaf-commands/src/main/java/org/apache/ode/karaf/commands/OdeCommandsBase.java
(rev 0)
+++
branches/ODE/ODE-1.x/jbi-karaf-commands/src/main/java/org/apache/ode/karaf/commands/OdeCommandsBase.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,104 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.ode.karaf.commands;
+
+import java.util.List;
+import java.util.concurrent.Callable;
+import java.util.concurrent.ExecutorService;
+import java.util.concurrent.Executors;
+import java.util.concurrent.Future;
+import java.util.concurrent.TimeUnit;
+
+import javax.management.*;
+
+import org.apache.felix.karaf.shell.console.OsgiCommandSupport;
+import org.apache.ode.bpel.pmapi.*;
+import org.apache.ode.jbi.OdeContext;
+
+public abstract class OdeCommandsBase extends OsgiCommandSupport {
+
+ protected static String COMPONENT_NAME =
"org.apache.servicemix:Type=Component,Name=OdeBpelEngine,SubType=Management";
+
+ protected static final String LIST_ALL_PROCESSES = "listAllProcesses";
+ protected static final String LIST_ALL_INSTANCES = "listAllInstances";
+ protected static final String TERMINATE = "terminate";
+
+ protected MBeanServer getMBeanServer() {
+ OdeContext ode = OdeContext.getInstance();
+ if (ode != null) {
+ return ode.getContext().getMBeanServer();
+ }
+ return null;
+ }
+
+ /**
+ * Invokes an operation on the ODE MBean server
+ *
+ * @param <T>
+ * @param operationName
+ * @param args
+ * @param T
+ * @return
+ */
+ @SuppressWarnings("unchecked")
+ protected <T> T invoke(final String operationName, final Object[] params,
+ final String[] signature, Class<?> T, long timeoutInSeconds)
+ throws Exception {
+ ExecutorService executor = Executors.newSingleThreadExecutor();
+ Callable<T> callable = new Callable<T>() {
+ public T call() throws Exception {
+ MBeanServer server = getMBeanServer();
+ if (server != null) {
+ return (T) server.invoke(new ObjectName(COMPONENT_NAME),
+ operationName, params, signature);
+ }
+ return null;
+ }
+ };
+ Future<T> future = executor.submit(callable);
+ executor.shutdown();
+ return future.get(timeoutInSeconds, TimeUnit.SECONDS);
+ }
+
+ protected List<TProcessInfo> getProcesses(long timeoutInSeconds)
+ throws Exception {
+ ProcessInfoListDocument result = invoke(LIST_ALL_PROCESSES, null, null,
+ ProcessInfoListDocument.class, timeoutInSeconds);
+ if (result != null) {
+ return result.getProcessInfoList().getProcessInfoList();
+ }
+ return null;
+ }
+
+ protected List<TInstanceInfo> getActiveInstances(long timeoutInSeconds)
+ throws Exception {
+ InstanceInfoListDocument instances = invoke(LIST_ALL_INSTANCES, null,
+ null, InstanceInfoListDocument.class, timeoutInSeconds);
+ if (instances != null) {
+ return instances.getInstanceInfoList().getInstanceInfoList();
+ }
+ return null;
+ }
+
+ protected void terminate(Long iid, long timeoutInSeconds) throws Exception {
+ invoke(TERMINATE, new Long[] { iid }, new String[] { Long.class
+ .getName() }, InstanceInfoDocument.class, timeoutInSeconds);
+ }
+}
Added:
branches/ODE/ODE-1.x/jbi-karaf-commands/src/main/java/org/apache/ode/karaf/commands/OdeListCommand.java
===================================================================
---
branches/ODE/ODE-1.x/jbi-karaf-commands/src/main/java/org/apache/ode/karaf/commands/OdeListCommand.java
(rev 0)
+++
branches/ODE/ODE-1.x/jbi-karaf-commands/src/main/java/org/apache/ode/karaf/commands/OdeListCommand.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,98 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.ode.karaf.commands;
+
+import java.util.List;
+import java.util.Set;
+import java.util.TreeSet;
+import java.util.concurrent.TimeoutException;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+import org.apache.felix.gogo.commands.Command;
+import org.apache.ode.bpel.pmapi.TInstanceInfo;
+import org.apache.ode.bpel.pmapi.TInstanceStatus;
+import org.apache.ode.bpel.pmapi.TProcessInfo;
+
+/**
+ * Lists the deployed process as well as the active instances
+ *
+ * @author daniel
+ */
+@Command(scope = "ode", name = "list", description = "Lists ode
processes and active instances")
+public class OdeListCommand extends OdeCommandsBase {
+
+ private static final Log __log = LogFactory.getLog(OdeListCommand.class);
+
+ private long timeoutInSeconds = 30;
+
+ @Override
+ protected Object doExecute() throws Exception {
+ try {
+ System.out.println("Existing processes");
+ System.out.println("------------------");
+ List<TProcessInfo> processes = getProcesses(timeoutInSeconds);
+ if (processes != null) {
+ Set<String> sorted = new TreeSet<String>(
+ String.CASE_INSENSITIVE_ORDER);
+ for (TProcessInfo info : processes) {
+ sorted.add(info.getDefinitionInfo().getProcessName()
+ .getLocalPart());
+ }
+ for (String s : sorted) {
+ System.out.println(s);
+ }
+ }
+ System.out.println();
+
+ System.out.println("Active instances");
+ System.out.println("----------------");
+ List<TInstanceInfo> instances = getActiveInstances(timeoutInSeconds);
+ if (instances != null) {
+ System.out.println("[Instance Id] [Process Name ]");
+ for (TInstanceInfo info : instances) {
+ if (info.getStatus() == TInstanceStatus.ACTIVE) {
+ StringBuilder line = new StringBuilder();
+ line.append("[");
+ line.append(getNameString(info.getIid(), 11));
+ line.append("] [");
+ line.append(getNameString(info.getProcessName()
+ .getLocalPart(), 20));
+ line.append("]");
+ System.out.println(line.toString());
+ }
+ }
+ }
+ } catch (TimeoutException e) {
+ __log.error("Timed out after " + timeoutInSeconds + "
seconds", e);
+ }
+
+ return null;
+ }
+
+ private String getNameString(String name, int colLength) {
+ String ret = name;
+ for (int i = 0; i < colLength - name.length(); i++) {
+ ret = ret + " ";
+ }
+ return ret;
+ }
+
+}
Added:
branches/ODE/ODE-1.x/jbi-karaf-commands/src/main/java/org/apache/ode/karaf/commands/OdeTerminateCommand.java
===================================================================
---
branches/ODE/ODE-1.x/jbi-karaf-commands/src/main/java/org/apache/ode/karaf/commands/OdeTerminateCommand.java
(rev 0)
+++
branches/ODE/ODE-1.x/jbi-karaf-commands/src/main/java/org/apache/ode/karaf/commands/OdeTerminateCommand.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,70 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.ode.karaf.commands;
+
+import java.util.List;
+import java.util.concurrent.TimeoutException;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+import org.apache.felix.gogo.commands.*;
+import org.apache.ode.bpel.pmapi.TInstanceInfo;
+
+@Command(scope = "ode", name = "terminate", description =
"Terminate an active ode process instances")
+public class OdeTerminateCommand extends OdeCommandsBase {
+
+ private static final Log __log = LogFactory.getLog(OdeListCommand.class);
+
+ @Argument(name = "iids", description = "Instance ID's to
terminate", multiValued = true)
+ private static Long[] iids;
+
+ @Option(name = "-a", aliases = "--all", description =
"Terminate all active instances")
+ private boolean terminateAll;
+
+ private long timeoutInSeconds = 30;
+
+ @Override
+ protected Object doExecute() throws Exception {
+ try {
+ if (terminateAll) {
+ List<TInstanceInfo> instances =
getActiveInstances(timeoutInSeconds);
+ if (instances != null) {
+ for (TInstanceInfo instance : instances) {
+ terminate(Long.parseLong(instance.getIid()),
+ timeoutInSeconds);
+ }
+ }
+ } else {
+ if (iids == null) {
+ System.out.println("No instance ids to terminate");
+ } else {
+ for (Long iid : iids) {
+ terminate(iid, timeoutInSeconds);
+ }
+ }
+ }
+ } catch (TimeoutException e) {
+ __log.error("Timed out after " + timeoutInSeconds + "
seconds", e);
+ }
+
+ return null;
+ }
+
+}
Added:
branches/ODE/ODE-1.x/jbi-karaf-commands/src/main/resources/OSGI-INF/blueprint/ode-commands.xml
===================================================================
---
branches/ODE/ODE-1.x/jbi-karaf-commands/src/main/resources/OSGI-INF/blueprint/ode-commands.xml
(rev 0)
+++
branches/ODE/ODE-1.x/jbi-karaf-commands/src/main/resources/OSGI-INF/blueprint/ode-commands.xml 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http///www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+<blueprint
xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
+
xmlns:shell="http://felix.apache.org/karaf/xmlns/shell/v1.0.0">
+
+ <shell:command-bundle>
+ <shell:command name="ode/list">
+ <shell:action
class="org.apache.ode.karaf.commands.OdeListCommand" />
+ </shell:command>
+ <shell:command name="ode/terminate">
+ <shell:action
class="org.apache.ode.karaf.commands.OdeTerminateCommand" />
+ </shell:command>
+ </shell:command-bundle>
+
+</blueprint>
\ No newline at end of file
Added: branches/ODE/ODE-1.x/jca-ra/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/jca-ra/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/jca-ra/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,44 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jca-ra</artifactId>
+ <name>ODE :: JCA Resource Archive</name>
+ <packaging>jar</packaging>
+ <modelVersion>4.0.0</modelVersion>
+
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-utils</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-j2ee-connector_1.5_spec</artifactId>
+ </dependency>
+ </dependencies>
+</project>
Added: branches/ODE/ODE-1.x/jca-server/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/jca-server/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/jca-server/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,44 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jca-server</artifactId>
+ <name>ODE :: JCA Server</name>
+ <packaging>jar</packaging>
+ <modelVersion>4.0.0</modelVersion>
+
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jca-ra</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-logging</groupId>
+ <artifactId>commons-logging</artifactId>
+ </dependency>
+ </dependencies>
+</project>
Added: branches/ODE/ODE-1.x/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,942 @@
+<?xml version="1.0"?>
+<project>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <name>ODE</name>
+
+ <packaging>pom</packaging>
+ <modelVersion>4.0.0</modelVersion>
+ <version>1.3.4-SNAPSHOT</version>
+ <url>http://ode.apache.org</url>
+ <issueManagement>
+ <system>jira</system>
+ <url>http://issues.apache.org</url>
+ </issueManagement>
+ <licenses>
+ <license>
+ <name>Apache Public License 2.0</name>
+ <
url>http://www.apache.org/licenses/LICENSE-2.0</url>
+ <distribution>repo</distribution>
+ </license>
+ </licenses>
+
+ <scm>
+
<
connection>scm:svn:http://svn.apache.org/repos/asf/ode/</connection...
+
<
developerConnection>scm:svn:https://svn.apache.org/repos/asf/ode/</...
+ <
url>http://svn.apache.org/repos/asf/ode/</url>
+ </scm>
+
+ <organization>
+ <name>Apache Software Foundation</name>
+ <url>http://www.apache.org</url>
+ </organization>
+
+ <prerequisites>
+ <maven>2.2.1</maven>
+ </prerequisites>
+
+ <properties>
+ <ode.version>1.3.4-SNAPSHOT</ode.version>
+ <activation.version>1.1</activation.version>
+ <annogen.version>0.1.0</annogen.version>
+ <antlr.version>2.7.7</antlr.version>
+ <axiom.version>1.2.7</axiom.version>
+ <axis2.version>1.4.1</axis2.version>
+ <commons.codec.version>1.3</commons.codec.version>
+ <backport.concurrent.version>3.1</backport.concurrent.version>
+ <commons.fileupload.version>1.2</commons.fileupload.version>
+ <commons.collections.version>3.1</commons.collections.version>
+ <commons.httpclient.version>3.1</commons.httpclient.version>
+ <commons.io.version>1.4</commons.io.version>
+ <commons.lang.version>2.4</commons.lang.version>
+ <commons.logging.version>1.1</commons.logging.version>
+ <commons.pool.version>1.4</commons.pool.version>
+ <commons.primitives.version>1.0</commons.primitives.version>
+ <commons.dbcp.version>1.2.1</commons.dbcp.version>
+ <httpcomponents.version>4.0-beta1</httpcomponents.version>
+ <jaxb-api.version>2.1</jaxb-api.version>
+ <jaxb.version>2.1.6</jaxb.version>
+ <jaxen.version>1.1.1</jaxen.version>
+ <jettison.version>1.0-RC2</jettison.version>
+ <jibx.version>1.1.5</jibx.version>
+ <neethi.version>2.0.4</neethi.version>
+ <woden.version>1.0M8</woden.version>
+ <wsdl4j.version>1.6.2</wsdl4j.version>
+ <woodstox.version>3.2.4</woodstox.version>
+ <javax.mail.version>1.4</javax.mail.version>
+ <hibernate.version>3.2.5.ga</hibernate.version>
+ <spring.version>2.5.6</spring.version>
+ <geronimo.specs.version>1.0</geronimo.specs.version>
+ <geronimo.version>2.0.1</geronimo.version>
+ <geronimo.activation.version>1.0.1</geronimo.activation.version>
+ <geronimo.annotation.version>1.1</geronimo.annotation.version>
+ <geronimo.javamail.version>1.2</geronimo.javamail.version>
+ <geronimo.stax-api.version>1.0.1</geronimo.stax-api.version>
+ <geronimo.specs.jta.version>1.1</geronimo.specs.jta.version>
+ <geronimo.specs.ejb.version>1.1</geronimo.specs.ejb.version>
+ <jetty.version>6.1.12rc1</jetty.version>
+ <jencks.version>2.1</jencks.version>
+ <jasper.version>4.2.20RC0</jasper.version>
+ <log4j.version>1.2.13</log4j.version>
+ <saxon.version>9.1.0.8</saxon.version>
+ <servicemix.version>3.3</servicemix.version>
+ <slf4j.version>1.4.3</slf4j.version>
+ <stax-api.version>1.0</stax-api.version>
+ <xerces.version>2.9.0</xerces.version>
+ <xmlresolver.version>1.2</xmlresolver.version>
+ <xmlbeans.version>2.3.0</xmlbeans.version>
+ <xstream.version>1.2</xstream.version>
+ <junit.version>4.4</junit.version>
+ <hsqldb.version>1.8.0.7</hsqldb.version>
+ <persistence-api.version>1.0</persistence-api.version>
+ <xalan.version>2.7.1</xalan.version>
+ <ant.version>1.6.5</ant.version>
+ <openjpa.version>1.2.1</openjpa.version>
+ <serp.version>1.13.1</serp.version>
+ <dom4j.version>1.6.1</dom4j.version>
+ <derby.version>10.5.3.0_1</derby.version>
+ <jmock.version>1.2.0</jmock.version>
+ <xml.parser.version>2.6.2</xml.parser.version>
+ <activemq.version>4.1.1</activemq.version>
+ <xml-apis.version>1.3.04</xml-apis.version>
+ <servicemix.nmr.version>1.1.0-SNAPSHOT</servicemix.nmr.version>
+ </properties>
+
+
+ <modules>
+ <module>agents</module>
+ <module>utils</module>
+ <module>jacob-ap</module>
+ <module>jacob</module>
+ <module>bpel-schemas</module>
+ <module>bpel-scripts</module>
+ <module>bpel-api</module>
+ <module>bpel-api-jca</module>
+ <module>bpel-dao</module>
+ <module>bpel-obj</module>
+ <module>dao-jpa</module>
+ <module>jca-ra</module>
+ <module>jca-server</module>
+ <module>scheduler-simple</module>
+ <module>bpel-compiler</module>
+ <module>bpel-epr</module>
+ <module>bpel-ql</module>
+ <module>dao-hibernate</module>
+ <module>tools</module>
+ <module>bpel-store</module>
+ <module>dao-jpa-ojpa-derby</module>
+ <module>dao-hibernate-db</module>
+ <module>bpel-runtime</module>
+ <module>bpel-connector</module>
+ <module>bpel-test</module>
+ <module>axis2</module>
+ <module>jbi</module>
+ <module>jbi-bundle</module>
+ <module>jbi-karaf</module>
+ <module>distro/src/examples-jbi/maven2/ping-pong-osgi</module>
+ <module>axis2-war</module>
+ <module>distro</module>
+ </modules>
+
+ <build>
+ <pluginManagement>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-assembly-plugin</artifactId>
+ <version>2.2-beta-5</version>
+ </plugin>
+
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <version>2.0.2</version>
+ <configuration>
+ <source>1.5</source>
+ <target>1.5</target>
+ </configuration>
+ </plugin>
+
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-surefire-plugin</artifactId>
+ <version>2.4.3</version>
+ </plugin>
+
+
+ <!--|
+ | This version uses xjavadoc-1.1-j5, which doesn't
+ | complain on Java 5.0 constructs.
+ |
+ -->
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>xdoclet-maven-plugin</artifactId>
+ <version>1.0</version>
+ <dependencies>
+ <dependency>
+ <groupId>xdoclet</groupId>
+ <artifactId>xjavadoc</artifactId>
+ <version>1.1-j5</version>
+ </dependency>
+ </dependencies>
+ </plugin>
+
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>xmlbeans-maven-plugin</artifactId>
+ <version>2.3.3</version>
+ </plugin>
+
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>sql-maven-plugin</artifactId>
+ <version>1.2</version>
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.derby</groupId>
+ <artifactId>derby</artifactId>
+ <version>${derby.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.derby</groupId>
+ <artifactId>derbytools</artifactId>
+ <version>${derby.version}</version>
+ </dependency>
+ </dependencies>
+ </plugin>
+
+ <!-- Allows direct usage of the javadoc:javadoc goal. -->
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-javadoc-plugin</artifactId>
+ <version>2.5</version>
+ <configuration>
+ <minmemory>128m</minmemory>
+ <maxmemory>512m</maxmemory>
+ </configuration>
+ </plugin>
+ </plugins>
+ </pluginManagement>
+ </build>
+
+
+
+ <!--|
+ | List of repositories for all the various dependencies,
+ | and Maven plugins.
+ |
+ -->
+ <repositories>
+ <repository>
+ <id>servicemix-repo</id>
+ <name>ServiceMix Repository</name>
+ <
url>https://repository.apache.org/content/groups/public</url>
+ <releases>
+ <enabled>true</enabled>
+ </releases>
+ <snapshots>
+ <enabled>false</enabled>
+ </snapshots>
+ </repository>
+ <!--
+ <repository>
+ <id>servicemix</id>
+ <name>Apache ServiceMix Repository</name>
+ <
url>http://svn.apache.org/repos/asf/servicemix/m2-repo</url>
+ <releases>
+ <enabled>true</enabled>
+ </releases>
+ <snapshots>
+ <enabled>false</enabled>
+ </snapshots>
+ </repository>
+ -->
+ <repository>
+ <id>saxon-repo</id>
+ <name>Saxon Repo</name>
+ <
url>http://people.apache.org/~rr/saxon-repo</url>
+ <releases>
+ <enabled>true</enabled>
+ </releases>
+ <snapshots>
+ <enabled>false</enabled>
+ </snapshots>
+ </repository>
+ </repositories>
+
+ <!--
+ <repositories>
+ <repository>
+ <id>central</id>
+ <name>Maven Repository Switchboard</name>
+ <
url>http://repo1.maven.org/maven2</url>
+ </repository>
+ <repository>
+ <id>ibiblio</id>
+ <name>ibiblio</name>
+ <
url>http://www.ibiblio.org/maven2</url>
+ </repository>
+ <repository>
+ <id>apache.snapshots</id>
+ <name>Apache snapshots</name>
+ <
url>http://repository.apache.org/snapshots/</url>
+ </repository>
+ <repository>
+ <id>intalio</id>
+ <name>ODE Maven2 repository</name>
+ <
url>http://pxe.intalio.org/public/maven2</url>
+ </repository>
+ <repository>
+ <id>JBoss</id>
+ <name>JBoss Repository</name>
+ <
url>http://repository.jboss.com/maven2/</url>
+ </repository>
+ </repositories>
+
+ <pluginRepositories>
+ <pluginRepository>
+ <id>central</id>
+ <name>Maven Repository Switchboard</name>
+ <
url>http://repo1.maven.org/maven2</url>
+ </pluginRepository>
+ <pluginRepository>
+ <id>ibiblio</id>
+ <name>ibiblio</name>
+ <
url>http://www.ibiblio.org/maven2</url>
+ </pluginRepository>
+ <pluginRepository>
+ <id>apache.snapshots</id>
+ <name>Apache snapshots</name>
+ <
url>http://repository.apache.org/snapshots/</url>
+ </pluginRepository>
+ <pluginRepository>
+ <id>intalio</id>
+ <name>Intalio Maven2 repository</name>
+ <
url>http://pxe.intalio.org/public/maven2</url>
+ </pluginRepository>
+ </pluginRepositories>
+
+-->
+ <!-- |
+ | Repository for distributing new releases.
+ |
+ -->
+ <distributionManagement>
+ <repository>
+ <id>apache.releases.https</id>
+ <name>Apache Release Distribution Repository</name>
+
<
url>https://repository.apache.org/service/local/staging/deploy/maven2&...
+ </repository>
+ <snapshotRepository>
+ <id>apache.snapshots.https</id>
+ <name>Apache Development Snapshot Repository</name>
+
<
url>https://repository.apache.org/content/repositories/snapshots</u...
+ <uniqueVersion>false</uniqueVersion>
+ </snapshotRepository>
+ </distributionManagement>
+
+ <dependencyManagement>
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-agents</artifactId>
+ <version>${ode.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-runtime</artifactId>
+ <version>${ode.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-ql</artifactId>
+ <version>${ode.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-schemas</artifactId>
+ <version>${ode.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-api</artifactId>
+ <version>${ode.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-dao</artifactId>
+ <version>${ode.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-api-jca</artifactId>
+ <version>${ode.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-compiler</artifactId>
+ <version>${ode.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-obj</artifactId>
+ <version>${ode.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-scripts</artifactId>
+ <version>${ode.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-store</artifactId>
+ <version>${ode.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-connector</artifactId>
+ <version>${ode.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-dao-hibernate</artifactId>
+ <version>${ode.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jacob-ap</artifactId>
+ <version>${ode.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jacob</artifactId>
+ <version>${ode.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jbi</artifactId>
+ <version>${ode.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-epr</artifactId>
+ <version>${ode.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-dao-jpa</artifactId>
+ <version>${ode.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jca-ra</artifactId>
+ <version>${ode.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-jca-server</artifactId>
+ <version>${ode.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-tools</artifactId>
+ <version>${ode.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-utils</artifactId>
+ <version>${ode.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-scheduler-simple</artifactId>
+ <version>${ode.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-test</artifactId>
+ <version>${ode.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-axis2</artifactId>
+ <version>${ode.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>xalan</groupId>
+ <artifactId>xalan</artifactId>
+ <version>${xalan.version}</version>
+ </dependency>
+ <!-- 3rd party libraries -->
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <version>${junit.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>ant</groupId>
+ <artifactId>ant</artifactId>
+ <version>${ant.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>javax.activation</groupId>
+ <artifactId>activation</artifactId>
+ <version>${activation.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>annogen</groupId>
+ <artifactId>annogen</artifactId>
+ <version>${annogen.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>antlr</groupId>
+ <artifactId>antlr</artifactId>
+ <version>${antlr.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ws.commons.axiom</groupId>
+ <artifactId>axiom-api</artifactId>
+ <version>${axiom.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ws.commons.axiom</groupId>
+ <artifactId>axiom-impl</artifactId>
+ <version>${axiom.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ws.commons.axiom</groupId>
+ <artifactId>axiom-dom</artifactId>
+ <version>${axiom.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>backport-util-concurrent</groupId>
+ <artifactId>backport-util-concurrent</artifactId>
+ <version>${backport.concurrent.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>commons-codec</groupId>
+ <artifactId>commons-codec</artifactId>
+ <version>${commons.codec.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>commons-fileupload</groupId>
+ <artifactId>commons-fileupload</artifactId>
+ <version>${commons.fileupload.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>commons-io</groupId>
+ <artifactId>commons-io</artifactId>
+ <version>${commons.io.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>commons-collections</groupId>
+ <artifactId>commons-collections</artifactId>
+ <version>${commons.collections.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>commons-httpclient</groupId>
+ <artifactId>commons-httpclient</artifactId>
+ <version>${commons.httpclient.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>commons-lang</groupId>
+ <artifactId>commons-lang</artifactId>
+ <version>${commons.lang.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>commons-logging</groupId>
+ <artifactId>commons-logging</artifactId>
+ <version>${commons.logging.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>commons-dbcp</groupId>
+ <artifactId>commons-dbcp</artifactId>
+ <version>${commons.dbcp.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>commons-primitives</groupId>
+ <artifactId>commons-primitives</artifactId>
+ <version>${commons.primitives.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-jta_1.1_spec</artifactId>
+ <version>${geronimo.specs.jta.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-j2ee-connector_1.5_spec</artifactId>
+ <version>${geronimo.specs.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-ejb_2.1_spec</artifactId>
+ <version>${geronimo.specs.ejb.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.components</groupId>
+ <artifactId>geronimo-connector</artifactId>
+ <version>${geronimo.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.components</groupId>
+ <artifactId>geronimo-transaction</artifactId>
+ <version>${geronimo.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.modules</groupId>
+ <artifactId>geronimo-kernel</artifactId>
+ <version>${geronimo.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-activation_1.1_spec</artifactId>
+ <version>${geronimo.activation.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-annotation_1.0_spec</artifactId>
+ <version>${geronimo.annotation.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-javamail_1.4_spec</artifactId>
+ <version>${geronimo.javamail.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-stax-api_1.0_spec</artifactId>
+ <version>${geronimo.stax-api.version}</version>
+ </dependency>
+
+ <dependency>
+ <groupId>org.apache.httpcomponents</groupId>
+ <artifactId>httpcore</artifactId>
+ <version>${httpcomponents.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.httpcomponents</groupId>
+ <artifactId>httpcore-nio</artifactId>
+ <version>${httpcomponents.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>javax.xml.bind</groupId>
+ <artifactId>jaxb-api</artifactId>
+ <version>${jaxb-api.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>com.sun.xml.bind</groupId>
+ <artifactId>jaxb-impl</artifactId>
+ <version>${jaxb.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>com.sun.xml.bind</groupId>
+ <artifactId>jaxb-xjc</artifactId>
+ <version>${jaxb.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>javax.persistence</groupId>
+ <artifactId>persistence-api</artifactId>
+ <version>${persistence-api.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>jaxen</groupId>
+ <artifactId>jaxen</artifactId>
+ <version>${jaxen.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.codehaus.jettison</groupId>
+ <artifactId>jettison</artifactId>
+ <version>${jettison.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.jibx</groupId>
+ <artifactId>jibx-run</artifactId>
+ <version>${jibx.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.jibx</groupId>
+ <artifactId>jibx-bind</artifactId>
+ <version>${jibx.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.neethi</groupId>
+ <artifactId>neethi</artifactId>
+ <version>${neethi.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.woden</groupId>
+ <artifactId>woden-api</artifactId>
+ <version>${woden.version}</version>
+ <exclusions>
+ <exclusion>
+ <artifactId>xerces</artifactId>
+ <groupId>xmlParserAPIs</groupId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.woden</groupId>
+ <artifactId>woden-impl-dom</artifactId>
+ <version>${woden.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>wsdl4j</groupId>
+ <artifactId>wsdl4j</artifactId>
+ <version>${wsdl4j.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>woodstox</groupId>
+ <artifactId>wstx-asl</artifactId>
+ <version>${woodstox.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>javax.mail</groupId>
+ <artifactId>mail</artifactId>
+ <version>${javax.mail.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.openjpa</groupId>
+ <artifactId>openjpa</artifactId>
+ <version>${openjpa.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>net.sourceforge.serp</groupId>
+ <artifactId>serp</artifactId>
+ <version>${serp.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>dom4j</groupId>
+ <artifactId>dom4j</artifactId>
+ <version>${dom4j.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>xml-apis</groupId>
+ <artifactId>xml-apis</artifactId>
+ <version>${xml-apis.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>commons-pool</groupId>
+ <artifactId>commons-pool</artifactId>
+ <version>${commons.pool.version}</version>
+ <exclusions>
+ <!-- These need to be excluded, we are on JDK5 -->
+ <exclusion>
+ <artifactId>xerces</artifactId>
+ <groupId>xerces</groupId>
+ </exclusion>
+
+ <exclusion>
+ <artifactId>xml-apis</artifactId>
+ <groupId>xml-apis</groupId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+
+ <dependency>
+ <groupId>org.hibernate</groupId>
+ <artifactId>hibernate</artifactId>
+ <version>${hibernate.version}</version>
+ <!--
+ <exclusions>
+ <exclusion>
+ <artifactId>jta</artifactId>
+ <groupId>javax.transaction</groupId>
+ </exclusion>
+ </exclusions>
+ -->
+ </dependency>
+
+ <dependency>
+ <groupId>log4j</groupId>
+ <artifactId>log4j</artifactId>
+ <version>${log4j.version}</version>
+ <exclusions>
+ <exclusion>
+ <groupId>javax.mail</groupId>
+ <artifactId>mail</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>javax.jms</groupId>
+ <artifactId>jms</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>com.sun.jdmk</groupId>
+ <artifactId>jmxtools</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>com.sun.jmx</groupId>
+ <artifactId>jmxri</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon</artifactId>
+ <version>${saxon.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon-dom</artifactId>
+ <version>${saxon.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon-xpath</artifactId>
+ <version>${saxon.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon-xqj</artifactId>
+ <version>${saxon.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>xerces</groupId>
+ <artifactId>xercesImpl</artifactId>
+ <version>${xerces.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>xerces</groupId>
+ <artifactId>xmlParserAPIs</artifactId>
+ <version>${xml.parser.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>xml-resolver</groupId>
+ <artifactId>xml-resolver</artifactId>
+ <version>${xmlresolver.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.xmlbeans</groupId>
+ <artifactId>xmlbeans</artifactId>
+ <version>${xmlbeans.version}</version>
+ </dependency>
+
+ <dependency>
+ <groupId>xstream</groupId>
+ <artifactId>xstream</artifactId>
+ <version>${xstream.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>jmock</groupId>
+ <artifactId>jmock</artifactId>
+ <version>${jmock.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.activemq</groupId>
+ <artifactId>apache-activemq</artifactId>
+ <version>${activemq.version}</version>
+ </dependency>
+
+ <dependency>
+ <groupId>org.apache.derby</groupId>
+ <artifactId>derby</artifactId>
+ <version>${derby.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.derby</groupId>
+ <artifactId>derbytools</artifactId>
+ <version>${derby.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>hsqldb</groupId>
+ <artifactId>hsqldb</artifactId>
+ <version>${hsqldb.version}</version>
+ </dependency>
+
+ <!-- AXIS2 dependencies -->
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-adb</artifactId>
+ <version>${axis2.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-codegen</artifactId>
+ <version>${axis2.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-corba</artifactId>
+ <version>${axis2.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-fastinfoset</artifactId>
+ <version>${axis2.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-jaxbri</artifactId>
+ <version>${axis2.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-jaxws</artifactId>
+ <version>${axis2.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-kernel</artifactId>
+ <version>${axis2.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-metadata</artifactId>
+ <version>${axis2.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-mtompolicy</artifactId>
+ <version>${axis2.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-saaj</artifactId>
+ <version>${axis2.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-saaj-api</artifactId>
+ <version>${axis2.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-java2wsdl</artifactId>
+ <version>${axis2.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-xmlbeans</artifactId>
+ <version>${axis2.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-jibx</artifactId>
+ <version>${axis2.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-api</artifactId>
+ <version>${slf4j.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-log4j12</artifactId>
+ <version>${slf4j.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>jcl104-over-slf4j</artifactId>
+ <version>${slf4j.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>tranql</groupId>
+ <artifactId>tranql-connector</artifactId>
+ <version>1.1</version>
+ </dependency>
+ </dependencies>
+ </dependencyManagement>
+
+</project>
Added: branches/ODE/ODE-1.x/repositories.rb
===================================================================
--- branches/ODE/ODE-1.x/repositories.rb (rev 0)
+++ branches/ODE/ODE-1.x/repositories.rb 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,22 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+#
http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+repositories.remote << "http://www.intalio.org/public/maven2"
+repositories.remote <<
"http://people.apache.org/repo/m2-incubating-repository"
+repositories.remote << "http://repo1.maven.org/maven2"
+repositories.remote <<
"http://people.apache.org/repo/m2-snapshot-repository"
+repositories.remote << "http://download.java.net/maven/2"
+repositories.remote << "http://www.aqute.biz/repo"
+repositories.release_to[:url] ||= "sftp://guest@localhost/home/guest"
\ No newline at end of file
Added: branches/ODE/ODE-1.x/scheduler-simple/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/scheduler-simple/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/scheduler-simple/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,103 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-scheduler-simple</artifactId>
+ <name>ODE :: BPEL Scheduler Simple</name>
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-utils</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-collections</groupId>
+ <artifactId>commons-collections</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-logging</groupId>
+ <artifactId>commons-logging</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-jta_1.1_spec</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>hsqldb</groupId>
+ <artifactId>hsqldb</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>backport-util-concurrent</groupId>
+ <artifactId>backport-util-concurrent</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.modules</groupId>
+ <artifactId>geronimo-kernel</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.components</groupId>
+ <artifactId>geronimo-transaction</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.components</groupId>
+ <artifactId>geronimo-connector</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>tranql</groupId>
+ <artifactId>tranql-connector</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-j2ee-connector_1.5_spec</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-ejb_2.1_spec</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>log4j</groupId>
+ <artifactId>log4j</artifactId>
+ </dependency>
+ </dependencies>
+</project>
Modified:
branches/ODE/ODE-1.x/scheduler-simple/src/main/java/org/apache/ode/scheduler/simple/DatabaseDelegate.java
===================================================================
---
branches/ODE/ODE-1.x/scheduler-simple/src/main/java/org/apache/ode/scheduler/simple/DatabaseDelegate.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/scheduler-simple/src/main/java/org/apache/ode/scheduler/simple/DatabaseDelegate.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -38,6 +38,14 @@
boolean insertJob(Job job, String nodeId, boolean loaded) throws DatabaseException ;
/**
+ * Update the job in the database (only updates timestamp and details)
+ *
+ * @param job the job
+ * @throws DatabaseException in case of error
+ */
+ boolean updateJob(Job job) throws DatabaseException;
+
+ /**
* Delete a job from the database.
* @param jobid job identifier
* @param nodeId node identifier
Modified:
branches/ODE/ODE-1.x/scheduler-simple/src/main/java/org/apache/ode/scheduler/simple/JdbcDelegate.java
===================================================================
---
branches/ODE/ODE-1.x/scheduler-simple/src/main/java/org/apache/ode/scheduler/simple/JdbcDelegate.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/scheduler-simple/src/main/java/org/apache/ode/scheduler/simple/JdbcDelegate.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -52,6 +52,8 @@
private static final String UPDATE_REASSIGN = "update ODE_JOB set nodeid = ?,
scheduled = 0 where nodeid = ?";
+ private static final String UPDATE_JOB = "update ODE_JOB set ts = ?, details = ?
where jobid = ?";
+
private static final String UPGRADE_JOB_DEFAULT = "update ODE_JOB set nodeid = ?
where nodeid is null "
+ "and mod(ts,?) = ? and ts < ?";
@@ -159,6 +161,34 @@
}
}
+ public boolean updateJob(Job job) throws DatabaseException {
+ if (__log.isDebugEnabled())
+ __log.debug("updateJob " + job.jobId + " details=" +
job);
+
+ Connection con = null;
+ PreparedStatement ps = null;
+ try {
+ con = getConnection();
+ ps = con.prepareStatement(UPDATE_JOB);
+ ps.setLong(1, job.schedDate);
+ ByteArrayOutputStream bos = new ByteArrayOutputStream();
+ try {
+ StreamUtils.write(bos, (Serializable) job.detail);
+ } catch (Exception ex) {
+ __log.error("Error serializing job detail: " + job.detail);
+ throw new DatabaseException(ex);
+ }
+ ps.setBytes(2, bos.toByteArray());
+ ps.setString(3, job.jobId);
+ return ps.executeUpdate() == 1;
+ } catch (SQLException se) {
+ throw new DatabaseException(se);
+ } finally {
+ close(ps);
+ close(con);
+ }
+ }
+
@SuppressWarnings("unchecked")
public List<Job> dequeueImmediate(String nodeId, long maxtime, int maxjobs)
throws DatabaseException {
ArrayList<Job> ret = new ArrayList<Job>(maxjobs);
Modified:
branches/ODE/ODE-1.x/scheduler-simple/src/main/java/org/apache/ode/scheduler/simple/Job.java
===================================================================
---
branches/ODE/ODE-1.x/scheduler-simple/src/main/java/org/apache/ode/scheduler/simple/Job.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/scheduler-simple/src/main/java/org/apache/ode/scheduler/simple/Job.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -21,6 +21,7 @@
import java.util.Map;
+import java.text.SimpleDateFormat;
import org.apache.ode.utils.GUID;
/**
@@ -29,6 +30,8 @@
* @author Maciej Szefler ( m s z e f l e r @ g m a i l . c o m )
*/
class Job extends Task {
+ private static final SimpleDateFormat DATE_FORMAT = new
SimpleDateFormat("yyyy-MM-dd HH:mm:ss z");
+
String jobId;
boolean transacted;
Map<String,Object> detail;
@@ -57,6 +60,7 @@
@Override
public String toString() {
- return "Job "+jobId+" transacted: "+transacted+"
persisted: "+persisted+" details: "+detail;
+ SimpleDateFormat f = (SimpleDateFormat) DATE_FORMAT.clone();
+ return "Job "+jobId+" time: "+f.format(schedDate)+"
transacted: "+transacted+" persisted: "+persisted+" details:
"+detail;
}
}
Modified:
branches/ODE/ODE-1.x/scheduler-simple/src/main/java/org/apache/ode/scheduler/simple/SimpleScheduler.java
===================================================================
---
branches/ODE/ODE-1.x/scheduler-simple/src/main/java/org/apache/ode/scheduler/simple/SimpleScheduler.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/scheduler-simple/src/main/java/org/apache/ode/scheduler/simple/SimpleScheduler.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -38,30 +38,33 @@
import org.apache.commons.logging.LogFactory;
import org.apache.ode.bpel.iapi.ContextException;
import org.apache.ode.bpel.iapi.Scheduler;
+import org.apache.log4j.helpers.AbsoluteTimeDateFormat;
/**
- * A reliable and relatively simple scheduler that uses a database to persist information
about
+ * A reliable and relatively simple scheduler that uses a database to persist information
about
* scheduled tasks.
- *
+ *
* The challenge is to achieve high performance in a small memory footprint without loss
of reliability
* while supporting distributed/clustered configurations.
- *
- * The design is based around three time horizons: "immediate", "near
future", and "everything else".
+ *
+ * The design is based around three time horizons: "immediate", "near
future", and "everything else".
* Immediate jobs (i.e. jobs that are about to be up) are written to the database and
kept in
* an in-memory priority queue. When they execute, they are removed from the database.
Near future
* jobs are placed in the database and assigned to the current node, however they are not
stored in
* memory. Periodically jobs are "upgraded" from near-future to immediate
status, at which point they
- * get loaded into memory. Jobs that are further out in time, are placed in the database
without a
+ * get loaded into memory. Jobs that are further out in time, are placed in the database
without a
* node identifer; when they are ready to be "upgraded" to near-future jobs
they are assigned to one
- * of the known live nodes. Recovery is rather straighforward, with stale node
identifiers being
- * reassigned to known good nodes.
- *
+ * of the known live nodes. Recovery is rather straighforward, with stale node
identifiers being
+ * reassigned to known good nodes.
+ *
* @author Maciej Szefler ( m s z e f l e r @ g m a i l . c o m )
*
*/
public class SimpleScheduler implements Scheduler, TaskRunner {
private static final Log __log = LogFactory.getLog(SimpleScheduler.class);
+ private static final int DEFAULT_TRANSACTION_TIMEOUT = 60 * 1000;
+
/**
* Jobs scheduled with a time that is between [now, now+immediateInterval] will be
assigned to the current node, and placed
* directly on the todo queue.
@@ -77,6 +80,9 @@
/** 10s of no communication and you are deemed dead. */
long _staleInterval = 10000;
+ /** Duration used to log a warning if a job scheduled at a date D is queued at
D'>D+_warningDelay */
+ long _warningDelay = 5*60*1000;
+
/**
* Estimated sustained transaction per second capacity of the system.
* e.g. 100 means the system can process 100 jobs per seconds, on average
@@ -97,7 +103,7 @@
volatile JobProcessor _jobProcessor;
volatile JobProcessor _polledRunnableProcessor;
-
+
private SchedulerThread _todo;
private DatabaseDelegate _db;
@@ -108,6 +114,16 @@
/** When we last heard from our nodes. */
private ConcurrentHashMap<String, Long> _lastHeartBeat = new
ConcurrentHashMap<String, Long>();
+ /** Set of outstanding jobs, i.e., jobs that have been enqueued but not dequeued or
dispatched yet.
+ Used to avoid cases where a job would be dispatched twice if the server is under
high load and
+ does not fully process a job before it is reloaded from the database. */
+ private ConcurrentHashMap<String, Long> _outstandingJobs = new
ConcurrentHashMap<String, Long>();
+ /** Set of Jobs processed since the last LoadImmediate task.
+ This prevents a race condition where a job is processed twice. This could happen
if a LoadImediate tasks loads a job
+ from the db before the job is processed but puts it in the _outstandingJobs map
after the job was processed .
+ In such a case the job is no longer in the _outstandingJobs map, and so it's
queued again. */
+ private ConcurrentHashMap<String, Long> _processedSinceLastLoadTask = new
ConcurrentHashMap<String, Long>();
+
private boolean _running;
/** Time for next upgrade. */
@@ -116,7 +132,13 @@
private Random _random = new Random();
private long _pollIntervalForPolledRunnable =
Long.getLong("org.apache.ode.polledRunnable.pollInterval", 10 * 60 * 1000);
-
+
+ /** Number of immediate retries when the transaction fails **/
+ private int _immediateTransactionRetryLimit = 3;
+
+ /** Interval between immediate retries when the transaction fails **/
+ private long _immediateTransactionRetryInterval = 1000;
+
public SimpleScheduler(String nodeId, DatabaseDelegate del, Properties conf) {
_nodeId = nodeId;
_db = del;
@@ -125,9 +147,14 @@
_nearFutureInterval = getLongProperty(conf,
"ode.scheduler.nearFutureInterval", _nearFutureInterval);
_staleInterval = getLongProperty(conf, "ode.scheduler.staleInterval",
_staleInterval);
_tps = getIntProperty(conf, "ode.scheduler.transactionsPerSecond",
_tps);
+ _warningDelay = getLongProperty(conf, "ode.scheduler.warningDelay",
_warningDelay);
+
+ _immediateTransactionRetryLimit = getIntProperty(conf,
"ode.scheduler.immediateTransactionRetryLimit",
_immediateTransactionRetryLimit);
+ _immediateTransactionRetryInterval = getLongProperty(conf,
"ode.scheduler.immediateTransactionRetryInterval",
_immediateTransactionRetryInterval);
+
_todo = new SchedulerThread(this);
}
-
+
public void setPollIntervalForPolledRunnable(long pollIntervalForPolledRunnable) {
_pollIntervalForPolledRunnable = pollIntervalForPolledRunnable;
}
@@ -143,7 +170,7 @@
if (s != null) return Long.parseLong(s);
else return defaultValue;
}
-
+
public void setNodeId(String nodeId) {
_nodeId = nodeId;
}
@@ -182,6 +209,7 @@
public void cancelJob(String jobId) throws ContextException {
_todo.dequeue(new Job(0, jobId, false, null));
+ _outstandingJobs.remove(jobId);
try {
_db.deleteJob(jobId, _nodeId);
} catch (DatabaseException e) {
@@ -205,39 +233,98 @@
}
public <T> T execTransaction(Callable<T> transaction) throws Exception,
ContextException {
+ return execTransaction(transaction, 0);
+ }
+
+ public <T> T execTransaction(Callable<T> transaction, int timeout) throws
Exception, ContextException {
+ TransactionManager txm = _txm;
+ if( txm == null ) {
+ throw new ContextException("Cannot locate the transaction manager; the
server might be shutting down.");
+ }
+
+ // The value of the timeout is in seconds. If the value is zero, the transaction
service restores the default value.
+ if (timeout < 0) {
+ throw new IllegalArgumentException("Timeout must be positive, received:
"+timeout);
+ }
+
+ boolean existingTransaction = false;
try {
- if (__log.isDebugEnabled()) __log.debug("Beginning a new
transaction");
- _txm.begin();
+ existingTransaction = txm.getTransaction() != null;
} catch (Exception ex) {
- String errmsg = "Internal Error, could not begin transaction.";
+ String errmsg = "Internal Error, could not get current
transaction.";
throw new ContextException(errmsg, ex);
}
+
+ // already in transaction, execute and return directly
+ if (existingTransaction) {
+ return transaction.call();
+ }
+
+ // run in new transaction
+ Exception ex = null;
+ int immediateRetryCount = _immediateTransactionRetryLimit;
- boolean success = false;
+ _txm.setTransactionTimeout(timeout);
+ if(__log.isDebugEnabled() && timeout!=0) __log.debug("Custom
transaction timeout: "+timeout);
try {
- T retval = transaction.call();
- success = true;
- return retval;
- } catch (Exception ex) {
- throw ex;
+ do {
+ try {
+ if (__log.isDebugEnabled()) __log.debug("Beginning a new
transaction");
+ txm.begin();
+ } catch (Exception e) {
+ String errmsg = "Internal Error, could not begin
transaction.";
+ throw new ContextException(errmsg, e);
+ }
+
+ try {
+ ex = null;
+ return transaction.call();
+ } catch (Exception e) {
+ ex = e;
+ } finally {
+ if (ex == null) {
+ if (__log.isDebugEnabled()) __log.debug("Commiting on "
+ txm + "...");
+ try {
+ txm.commit();
+ } catch( Exception e2 ) {
+ ex = e2;
+ }
+ } else {
+ if (__log.isDebugEnabled()) __log.debug("Rollbacking on
" + txm + "...");
+ txm.rollback();
+ }
+
+ if( ex != null && immediateRetryCount > 0 ) {
+ if (__log.isDebugEnabled()) __log.debug("Will retry the
transaction in " + _immediateTransactionRetryInterval + " msecs on " + _txm
+ " for error: ", ex);
+ Thread.sleep(_immediateTransactionRetryInterval);
+ }
+ }
+ } while( immediateRetryCount-- > 0 );
} finally {
- if (success) {
- if (__log.isDebugEnabled()) __log.debug("Commiting on " + _txm
+ "...");
- _txm.commit();
- } else {
- if (__log.isDebugEnabled()) __log.debug("Rollbacking on " +
_txm + "...");
- _txm.rollback();
- }
+ // 0 restores the default value
+ _txm.setTransactionTimeout(0);
}
+
+ throw ex;
}
public void setRollbackOnly() throws Exception {
- _txm.setRollbackOnly();
+ TransactionManager txm = _txm;
+ if( txm == null ) {
+ throw new ContextException("Cannot locate the transaction manager; the
server might be shutting down.");
+ }
+
+ txm.setRollbackOnly();
}
public void registerSynchronizer(final Synchronizer synch) throws ContextException {
+ TransactionManager txm = _txm;
+ if( txm == null ) {
+ throw new ContextException("Cannot locate the transaction manager; the
server might be shutting down.");
+ }
+
try {
- _txm.getTransaction().registerSynchronization(new Synchronization() {
+ txm.getTransaction().registerSynchronization(new Synchronization() {
public void beforeCompletion() {
synch.beforeCompletion();
@@ -272,7 +359,7 @@
Map<String, Object> jobDetails = new HashMap<String, Object>();
jobDetails.put("runnable", runnable);
runnable.storeToDetailsMap(jobDetails);
-
+
if (__log.isDebugEnabled())
__log.debug("scheduling " + jobDetails + " for " +
when);
@@ -286,9 +373,9 @@
if (immediate) {
// Immediate scheduling means we put it in the DB for safe keeping
_db.insertJob(job, _nodeId, true);
-
+
// And add it to our todo list .
- if (_todo.size() < _todoLimit) {
+ if (_outstandingJobs.size() < _todoLimit) {
addTodoOnCommit(job);
}
__log.debug("scheduled immediate job: " + job.jobId);
@@ -307,11 +394,17 @@
throw new ContextException("Database error.", dbe);
}
return job.jobId;
+ }
+ public String scheduleVolatileJob(boolean transacted, Map<String, Object>
jobDetail) throws ContextException {
+ return scheduleVolatileJob(transacted, jobDetail, null);
}
- public String scheduleVolatileJob(boolean transacted, Map<String, Object>
jobDetail) throws ContextException {
- Job job = new Job(System.currentTimeMillis(), transacted, jobDetail);
+ public String scheduleVolatileJob(boolean transacted, Map<String, Object>
jobDetail, Date when) throws ContextException {
+ long ctime = System.currentTimeMillis();
+ if (when == null)
+ when = new Date(ctime);
+ Job job = new Job(when.getTime(), transacted, jobDetail);
job.persisted = false;
addTodoOnCommit(job);
return job.toString();
@@ -338,6 +431,8 @@
_todo.clearTasks(UpgradeJobsTask.class);
_todo.clearTasks(LoadImmediateTask.class);
_todo.clearTasks(CheckStaleNodes.class);
+ _processedSinceLastLoadTask.clear();
+ _outstandingJobs.clear();
_knownNodes.clear();
@@ -356,7 +451,7 @@
}
long now = System.currentTimeMillis();
-
+
// Pretend we got a heartbeat...
for (String s : _knownNodes) _lastHeartBeat.put(s, now);
@@ -372,11 +467,11 @@
_todo.start();
_running = true;
}
-
+
private long randomMean(long mean) {
return (long) _random.nextDouble() * mean + (mean/2);
}
-
+
public synchronized void stop() {
if (!_running)
return;
@@ -385,42 +480,54 @@
_todo.clearTasks(UpgradeJobsTask.class);
_todo.clearTasks(LoadImmediateTask.class);
_todo.clearTasks(CheckStaleNodes.class);
+ _processedSinceLastLoadTask.clear();
+ _outstandingJobs.clear();
+
+ // disable because this is not the right way to do it
+ // will be fixed by ODE-595
+ // graceful shutdown; any new submits will throw RejectedExecutionExceptions
+// _exec.shutdown();
_running = false;
}
- /**
- * Run a job in the current thread.
- *
- * @param job job to run.
- */
- protected void runJob(final Job job) {
- final Scheduler.JobInfo jobInfo = new Scheduler.JobInfo(job.jobId, job.detail,
- (Integer)(job.detail.get("retry") != null ?
job.detail.get("retry") : 0));
+ class RunJob implements Callable<Void> {
+ final Job job;
+ final JobProcessor processor;
- _exec.submit(new Callable<Void>() {
- public Void call() throws Exception {
+ RunJob(Job job, JobProcessor processor) {
+ this.job = job;
+ this.processor = processor;
+ }
+
+ public Void call() throws Exception {
+ try {
+ final Scheduler.JobInfo jobInfo = new Scheduler.JobInfo(job.jobId,
job.detail,
+ (Integer) (job.detail.get("retry") != null ?
job.detail.get("retry") : 0));
if (job.transacted) {
+ final boolean[] needRetry = new boolean[]{true};
try {
execTransaction(new Callable<Void>() {
public Void call() throws Exception {
if (job.persisted)
if (!_db.deleteJob(job.jobId, _nodeId))
- throw new
JobNoLongerInDbException(job.jobId,_nodeId);
-
+ throw new JobNoLongerInDbException(job.jobId,
_nodeId);
try {
- _jobProcessor.onScheduledJob(jobInfo);
- } catch (JobProcessorException jpe) {
- if (jpe.retry) {
- int retry = job.detail.get("retry") !=
null ? (((Integer)job.detail.get("retry")) + 1) : 0;
- if (retry <= 10) {
- long delay = doRetry(job);
- __log.error("Error while processing
transaction, retrying in " + delay + "s");
- } else {
- __log.error("Error while processing
transaction after 10 retries, no more retries:"+job);
+ processor.onScheduledJob(jobInfo);
+ // If the job is a "runnable" job, schedule
the next job occurence
+ if (job.detail.get("runnable") != null
&&
!"COMPLETED".equals(String.valueOf(jobInfo.jobDetail.get("runnable_status"))))
{
+ // the runnable is still in progress, schedule
checker to 10 mins later
+ if (_pollIntervalForPolledRunnable < 0) {
+ if (__log.isWarnEnabled())
+ __log.warn("The poll interval for
polled runnables is negative; setting it to 1000ms");
+ _pollIntervalForPolledRunnable = 1000;
}
- } else {
- __log.error("Error while processing
transaction, no retry.", jpe);
+ job.schedDate = System.currentTimeMillis() +
_pollIntervalForPolledRunnable;
+ _db.insertJob(job, _nodeId, false);
}
+ } catch (JobProcessorException jpe) {
+ if (!jpe.retry) {
+ needRetry[0] = false;
+ }
// Let execTransaction know that shit happened.
throw jpe;
}
@@ -430,19 +537,57 @@
} catch (JobNoLongerInDbException jde) {
// This may happen if two node try to do the same job... we try
to avoid
// it the synchronization is a best-effort but not perfect.
- __log.debug("job no longer in db forced rollback.");
- } catch (Exception ex) {
- __log.error("Error while executing transaction", ex);
+ __log.debug("job no longer in db forced rollback:
"+job);
+ } catch (final Exception ex) {
+ __log.error("Error while processing a
"+(job.persisted?"":"non-")+"persisted
job"+(needRetry[0] && job.persisted?": ":", no retry:
")+job, ex);
+
+ // We only get here if the above execTransaction fails, so that
transaction got
+ // rollbacked already
+ if (job.persisted) {
+ execTransaction(new Callable<Void>() {
+ public Void call() throws Exception {
+ if (needRetry[0]) {
+ int retry = job.detail.get("retry") !=
null ? (((Integer) job.detail.get("retry")) + 1) : 0;
+ if (retry <= 10) {
+ job.detail.put("retry", retry);
+ long delay = (long)(Math.pow(5, retry));
+ job.schedDate = System.currentTimeMillis() +
delay*1000;
+ _db.updateJob(job);
+ __log.error("Error while processing job,
retrying in " + delay + "s");
+ } else {
+ _db.deleteJob(job.jobId, _nodeId);
+ __log.error("Error while processing job
after 10 retries, no more retries:" + job);
+ }
+ } else {
+ _db.deleteJob(job.jobId, _nodeId);
+ }
+ return null;
+ }
+ });
+ }
}
} else {
- _jobProcessor.onScheduledJob(jobInfo);
+ processor.onScheduledJob(jobInfo);
}
return null;
+ } finally {
+ // the order of these 2 actions is crucial to avoid a race condition.
+ _processedSinceLastLoadTask.put(job.jobId, job.schedDate);
+ _outstandingJobs.remove(job.jobId);
}
- });
+ }
}
+
+ /**
+ * Run a job in the current thread.
+ *
+ * @param job job to run.
+ */
+ protected void runJob(final Job job) {
+ _exec.submit(new RunJob(job, _jobProcessor));
+ }
- /**
+ /**
* Run a job from a polled runnable thread. The runnable is not persistent,
* however, the poller is persistent and wakes up every given interval to
* check the status of the runnable.
@@ -457,7 +602,7 @@
* <li>5. System powered off and restarts; the poller job does not know what
the status
* of the runnable. This is handled just like the case #1.</li>
* </ul>
- *
+ * <p/>
* There is at least one re-scheduling of the poller job. Since, the runnable's
state is
* not persisted, and the same runnable may be tried again after system failure,
* the runnable that's used with this polling should be repeatable.
@@ -465,63 +610,14 @@
* @param job job to run.
*/
protected void runPolledRunnable(final Job job) {
- final Scheduler.JobInfo jobInfo = new Scheduler.JobInfo(job.jobId, job.detail,
- (Integer)(job.detail.get("retry") != null ?
job.detail.get("retry") : 0));
+ _exec.submit(new RunJob(job, _polledRunnableProcessor));
+ }
- _exec.submit(new Callable<Void>() {
- public Void call() throws Exception {
- try {
- execTransaction(new Callable<Void>() {
- public Void call() throws Exception {
- if (!_db.deleteJob(job.jobId, _nodeId))
- throw new JobNoLongerInDbException(job.jobId,_nodeId);
-
- try {
- _polledRunnableProcessor.onScheduledJob(jobInfo);
- if(
!"COMPLETED".equals(String.valueOf(jobInfo.jobDetail.get("runnable_status")))
) {
- // the runnable is still in progress, schedule
checker to 10 mins later
- if( _pollIntervalForPolledRunnable < 0 ) {
- if(__log.isWarnEnabled()) __log.warn("The
poll interval for polled runnables is negative; setting it to 1000ms");
- _pollIntervalForPolledRunnable = 1000;
- }
- job.schedDate = System.currentTimeMillis() +
_pollIntervalForPolledRunnable;
- _db.insertJob(job, _nodeId, false);
- }
- } catch (JobProcessorException jpe) {
- if (jpe.retry) {
- int retry = job.detail.get("retry") != null
? (((Integer)job.detail.get("retry")) + 1) : 0;
- if (retry <= 10) {
- long delay = doRetry(job);
- __log.error("Error while processing
transaction, retrying in " + delay + "s");
- } else {
- __log.error("Error while processing
transaction after 10 retries, no more retries:"+job);
- }
- } else {
- __log.error("Error while processing transaction,
no retry.", jpe);
- }
- // Let execTransaction know that shit happened.
- throw jpe;
- }
- return null;
- }
- });
- } catch (JobNoLongerInDbException jde) {
- // This may happen if two node try to do the same job... we try to
avoid
- // it the synchronization is a best-effort but not perfect.
- __log.debug("job no longer in db forced rollback.");
- } catch (Exception ex) {
- __log.error("Error while executing transaction", ex);
- }
- return null;
- }
- });
- }
-
private void addTodoOnCommit(final Job job) {
registerSynchronizer(new Synchronizer() {
public void afterCompletion(boolean success) {
if (success) {
- _todo.enqueue(job);
+ enqueue(job);
}
}
@@ -531,24 +627,39 @@
}
public boolean isTransacted() {
+ TransactionManager txm = _txm;
+ if( txm == null ) {
+ throw new ContextException("Cannot locate the transaction manager; the
server might be shutting down.");
+ }
+
try {
- Transaction tx = _txm.getTransaction();
+ Transaction tx = txm.getTransaction();
return (tx != null && tx.getStatus() !=
Status.STATUS_NO_TRANSACTION);
} catch (SystemException e) {
throw new ContextException("Internal Error: Could not obtain transaction
status.");
}
}
- public void runTask(Task task) {
+ public void runTask(final Task task) {
if (task instanceof Job) {
Job job = (Job)task;
if( job.detail.get("runnable") != null ) {
runPolledRunnable(job);
} else {
- runJob((Job) task);
+ runJob(job);
}
- } else if (task instanceof SchedulerTask)
- ((SchedulerTask) task).run();
+ } else if (task instanceof SchedulerTask) {
+ _exec.submit(new Callable<Void>() {
+ public Void call() throws Exception {
+ try {
+ ((SchedulerTask) task).run();
+ } catch (Exception ex) {
+ __log.error("Error during SchedulerTask execution",
ex);
+ }
+ return null;
+ }
+ });
+ }
}
public void updateHeartBeat(String nodeId) {
@@ -564,25 +675,53 @@
boolean doLoadImmediate() {
__log.debug("LOAD IMMEDIATE started");
-
+
// don't load anything if we're already half-full; we've got plenty
to do already
- if (_todo.size() > _todoLimit/2) return true;
-
+ if (_outstandingJobs.size() > _todoLimit/2) return true;
+
List<Job> jobs;
try {
- final int batch = (int) (_immediateInterval * _tps / 1000);
+ // don't load more than we can chew
+ final int batch = Math.min((int) (_immediateInterval * _tps / 1000),
_todoLimit-_outstandingJobs.size());
+
+ // jobs might have been enqueued by #addTodoOnCommit meanwhile
+ if (batch<=0) {
+ if (__log.isDebugEnabled()) __log.debug("Max capacity reached:
"+_outstandingJobs.size()+" jobs dispacthed i.e. queued or being
executed");
+ return true;
+ }
+
+ if (__log.isDebugEnabled()) __log.debug("loading "+batch+"
jobs from db");
jobs = execTransaction(new Callable<List<Job>>() {
public List<Job> call() throws Exception {
return _db.dequeueImmediate(_nodeId, System.currentTimeMillis() +
_immediateInterval, batch);
}
});
+ if (__log.isDebugEnabled()) __log.debug("loaded
"+jobs.size()+" jobs from db");
+
+ long delayedTime = System.currentTimeMillis() - _warningDelay;
+ int delayedCount = 0;
+ boolean runningLate;
+ AbsoluteTimeDateFormat f = new AbsoluteTimeDateFormat();
for (Job j : jobs) {
+ // jobs might have been enqueued by #addTodoOnCommit meanwhile
+ if (_outstandingJobs.size() >= _todoLimit){
+ if (__log.isDebugEnabled()) __log.debug("Max capacity reached:
"+_outstandingJobs.size()+" jobs dispacthed i.e. queued or being
executed");
+ break;
+ }
+ runningLate = j.schedDate <= delayedTime;
+ if (runningLate) {
+ delayedCount++;
+ }
if (__log.isDebugEnabled())
- __log.debug("todo.enqueue job from db: " + j.jobId + "
for " + j.schedDate);
+ __log.debug("todo.enqueue job from db: " + j.jobId.trim() +
" for " + j.schedDate + "(" + f.format(j.schedDate)+")
"+(runningLate?" delayed=true":""));
+ enqueue(j);
+ }
+ if (delayedCount > 0) {
+ __log.warn("Dispatching jobs with more than
"+(_warningDelay/60000)+" minutes delay. Either the server was down for some
time or the job load is greater than available capacity");
+ }
- if (_todo.size() < _todoLimit)
- _todo.enqueue(j);
- }
+ // clear only if the batch succeeded
+ _processedSinceLastLoadTask.clear();
return true;
} catch (Exception ex) {
__log.error("Error loading immediate jobs from database.", ex);
@@ -592,6 +731,22 @@
}
}
+ void enqueue(Job job) {
+ if (_processedSinceLastLoadTask.get(job.jobId) == null) {
+ if (_outstandingJobs.putIfAbsent(job.jobId, job.schedDate) == null) {
+ if (job.schedDate <= System.currentTimeMillis()) {
+ runJob(job);
+ } else {
+ _todo.enqueue(job);
+ }
+ } else {
+ if (__log.isDebugEnabled()) __log.debug("Job "+job.jobId+"
is being processed (outstanding job)");
+ }
+ } else {
+ if (__log.isDebugEnabled()) __log.debug("Job "+job.jobId+" is
being processed (processed since last load)");
+ }
+ }
+
boolean doUpgrade() {
__log.debug("UPGRADE started");
final ArrayList<String> knownNodes = new
ArrayList<String>(_knownNodes);
@@ -659,15 +814,6 @@
}
- private long doRetry(Job job) throws DatabaseException {
- int retry = job.detail.get("retry") != null ?
(((Integer)job.detail.get("retry")) + 1) : 0;
- job.detail.put("retry", retry);
- long delay = (long)(Math.pow(5, retry));
- Job jobRetry = new Job(System.currentTimeMillis() + delay*1000, true,
job.detail);
- _db.insertJob(jobRetry, _nodeId, false);
- return delay;
- }
-
private abstract class SchedulerTask extends Task implements Runnable {
SchedulerTask(long schedDate) {
super(schedDate);
Modified:
branches/ODE/ODE-1.x/scheduler-simple/src/test/java/org/apache/ode/scheduler/simple/DelegateSupport.java
===================================================================
---
branches/ODE/ODE-1.x/scheduler-simple/src/test/java/org/apache/ode/scheduler/simple/DelegateSupport.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/scheduler-simple/src/test/java/org/apache/ode/scheduler/simple/DelegateSupport.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -21,6 +21,9 @@
import java.sql.Connection;
+import javax.sql.DataSource;
+import javax.transaction.TransactionManager;
+
import org.apache.ode.utils.GUID;
import org.hsqldb.jdbc.jdbcDataSource;
@@ -32,19 +35,28 @@
*/
public class DelegateSupport {
- private jdbcDataSource _ds;
- private JdbcDelegate _del;
+ protected DataSource _ds;
+ protected JdbcDelegate _del;
public DelegateSupport() throws Exception {
- _ds = new jdbcDataSource();
- _ds.setDatabase("jdbc:hsqldb:mem:" + new GUID().toString());
- _ds.setUser("sa");
- _ds.setPassword("");
+ this(null);
+ }
+
+ public DelegateSupport(TransactionManager txm) throws Exception {
+ initialize(txm);
+ }
+
+ protected void initialize(TransactionManager txm) throws Exception {
+ jdbcDataSource ds = new jdbcDataSource();
+ ds.setDatabase("jdbc:hsqldb:mem:" + new GUID().toString());
+ ds.setUser("sa");
+ ds.setPassword("");
+ _ds = ds;
setup();
_del = new JdbcDelegate(_ds);
}
-
+
public DatabaseDelegate delegate() {
return _del;
}
Added:
branches/ODE/ODE-1.x/scheduler-simple/src/test/java/org/apache/ode/scheduler/simple/GeronimoDelegateSupport.java
===================================================================
---
branches/ODE/ODE-1.x/scheduler-simple/src/test/java/org/apache/ode/scheduler/simple/GeronimoDelegateSupport.java
(rev 0)
+++
branches/ODE/ODE-1.x/scheduler-simple/src/test/java/org/apache/ode/scheduler/simple/GeronimoDelegateSupport.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -0,0 +1,71 @@
+package org.apache.ode.scheduler.simple;
+
+import javax.sql.DataSource;
+import javax.transaction.TransactionManager;
+
+import org.apache.geronimo.connector.outbound.GenericConnectionManager;
+import org.apache.geronimo.connector.outbound.connectionmanagerconfig.LocalTransactions;
+import org.apache.geronimo.connector.outbound.connectionmanagerconfig.PoolingSupport;
+import org.apache.geronimo.connector.outbound.connectionmanagerconfig.SinglePool;
+import
org.apache.geronimo.connector.outbound.connectionmanagerconfig.TransactionSupport;
+import org.apache.geronimo.connector.outbound.connectiontracking.ConnectionTracker;
+import
org.apache.geronimo.connector.outbound.connectiontracking.ConnectionTrackingCoordinator;
+import org.apache.geronimo.transaction.manager.RecoverableTransactionManager;
+import org.apache.ode.utils.GUID;
+import org.tranql.connector.jdbc.JDBCDriverMCF;
+
+public class GeronimoDelegateSupport extends DelegateSupport {
+ private static final int CONNECTION_MAX_WAIT_MILLIS = 30000;
+
+ private static final int CONNECTION_MAX_IDLE_MINUTES = 5;
+
+ private GenericConnectionManager _connectionManager;
+
+ public GeronimoDelegateSupport(TransactionManager txm) throws Exception {
+ super(txm);
+ }
+
+ @Override
+ protected void initialize(TransactionManager txm) throws Exception {
+ _ds = createGeronimoDataSource(txm, "jdbc:hsqldb:mem:" + new
GUID().toString(), "org.hsqldb.jdbcDriver", "sa", "");
+ setup();
+ _del = new JdbcDelegate(_ds);
+ }
+
+ private DataSource createGeronimoDataSource(TransactionManager txm, String url,
String driverClass, String username,String password) {
+ TransactionSupport transactionSupport = LocalTransactions.INSTANCE;
+ ConnectionTracker connectionTracker = new ConnectionTrackingCoordinator();
+
+ PoolingSupport poolingSupport = new SinglePool(1, 1,
+ CONNECTION_MAX_WAIT_MILLIS,
+ CONNECTION_MAX_IDLE_MINUTES,
+ true, // match one
+ false, // match all
+ false); // select one assume match
+
+ _connectionManager = new GenericConnectionManager(
+ transactionSupport,
+ poolingSupport,
+ null,
+ connectionTracker,
+ (RecoverableTransactionManager) txm,
+ getClass().getName(),
+ getClass().getClassLoader());
+
+ JDBCDriverMCF mcf = new JDBCDriverMCF();
+ try {
+ mcf.setDriver(driverClass);
+ mcf.setConnectionURL(url);
+ if (username != null) {
+ mcf.setUserName(username);
+ }
+ if (password != null) {
+ mcf.setPassword(password);
+ }
+ _connectionManager.doStart();
+ return (DataSource) mcf.createConnectionFactory(_connectionManager);
+ } catch (Exception ex) {
+ throw new RuntimeException(ex);
+ }
+ }
+}
Modified:
branches/ODE/ODE-1.x/scheduler-simple/src/test/java/org/apache/ode/scheduler/simple/RetriesTest.java
===================================================================
---
branches/ODE/ODE-1.x/scheduler-simple/src/test/java/org/apache/ode/scheduler/simple/RetriesTest.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/scheduler-simple/src/test/java/org/apache/ode/scheduler/simple/RetriesTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -24,6 +24,7 @@
import javax.transaction.TransactionManager;
import java.util.*;
+import java.util.concurrent.Callable;
import junit.framework.TestCase;
@@ -37,10 +38,11 @@
ArrayList<Scheduler.JobInfo> _commit;
TransactionManager _txm;
int _tried = 0;
-
+ Scheduler.JobInfo _jobInfo = null;
+
public void setUp() throws Exception {
_txm = new GeronimoTransactionManager();
- _ds = new DelegateSupport();
+ _ds = new GeronimoDelegateSupport(_txm);
_scheduler = newScheduler("n1");
_jobs = new ArrayList<Scheduler.JobInfo>(100);
@@ -64,13 +66,33 @@
}
Thread.sleep(10000);
- assertEquals(3, _tried);
+ assertEquals(8, _tried);
}
+ public void testExecTransaction() throws Exception {
+ final int[] tryCount = new int[1];
+ tryCount[0] = 0;
+
+ Callable<Void> transaction = new Callable<Void>() {
+ public Void call() throws Exception {
+ tryCount[0]++;
+ if( tryCount[0] < 3 ) {
+ throw new Exception("any");
+ } else {
+ return null;
+ }
+ }
+ };
+ _scheduler.execTransaction(transaction);
+ assertEquals(3, tryCount[0]);
+ }
+
public void onScheduledJob(Scheduler.JobInfo jobInfo) throws
Scheduler.JobProcessorException {
+ _jobInfo = jobInfo;
+
_tried++;
- throw new Scheduler.JobProcessorException(jobInfo.retryCount < 3);
+ throw new Scheduler.JobProcessorException(jobInfo.retryCount < 1);
}
Map<String, Object> newDetail(String x) {
@@ -85,5 +107,4 @@
scheduler.setTransactionManager(_txm);
return scheduler;
}
-
}
Added: branches/ODE/ODE-1.x/tasks/bnd.rake
===================================================================
--- branches/ODE/ODE-1.x/tasks/bnd.rake (rev 0)
+++ branches/ODE/ODE-1.x/tasks/bnd.rake 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,85 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+#
http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+# This task creates an OSGi bundle package using the bnd tool.
+#
+# The classpath and path to a bnd configuration file are required.
+# Additional properties can be specified using the bnd.properties
+# hash. Refer to the bnd documentation (
http://www.aqute.biz/Code/Bnd)
+# for details on the supported properties.
+#
+# The easiest way to use this task is through the Project#package method.
+# For example:
+# package(:bundle).tap do |bnd|
+# bnd.bnd_file = 'conf/foo.bnd'
+# bnd.classpath = artifacts(...)
+# bnd.properties['foo'] = 'bar'
+# end
+class BndTask < Rake::FileTask
+
+ BND = "biz.aQute:bnd:jar:0.0.379"
+
+ # Classpath string for building the bundle
+ attr_accessor :classpath
+
+ # Sourcepath
+ attr_accessor :sourcepath
+
+ # Path to bnd file
+ attr_accessor :bnd_file
+
+ # Hash of properties passed to bnd
+ attr_accessor :properties
+
+ def initialize(*args)
+ super
+ @properties = {}
+
+ # Make sure bnd tool is available
+ Buildr.artifact(BND).invoke
+
+ enhance do
+ Buildr.ant('bnd') do |project|
+
+ # pass properties to bnd as ant properties
+ properties.each do |key, value|
+ project.property(:name=>key, :value=>value)
+ end
+
+ project.taskdef :name=>'bnd',
:classname=>'aQute.bnd.ant.BndTask', :classpath=>Buildr.artifact(BND)
+ project.bnd(:classpath=>classpath, :sourcepath=>(sourcepath == nil) ?
"" : File.expand_path(sourcepath),
+ :files=>File.expand_path(bnd_file), :output=>name,
+ :eclipse=>false, :failok=>false, :exceptions=>true)
+ end
+ end
+ end
+
+
+end
+
+
+class Project
+
+ def package_as_bundle(file_name) #:nodoc
+ BndTask.define_task(file_name)
+ end
+
+ def package_as_bundle_spec(spec) #:nodoc
+ spec.merge({ :type=>:jar, :classifier=>'bundle' })
+ end
+
+end
Modified: branches/ODE/ODE-1.x/tasks/derby.rake
===================================================================
--- branches/ODE/ODE-1.x/tasks/derby.rake 2010-04-14 15:43:12 UTC (rev 619)
+++ branches/ODE/ODE-1.x/tasks/derby.rake 2010-04-14 18:25:55 UTC (rev 620)
@@ -19,7 +19,7 @@
REQUIRES = Buildr.group("derby", "derbytools",
:under=>"org.apache.derby", :version=>"10.1.2.1")
- Java.rjb.onload { Java.rjb.classpath << REQUIRES }
+ Java.classpath << REQUIRES
class << self
@@ -29,7 +29,7 @@
# For example:
# Derby.create "mydb"=>derby.sql
def create(args)
- db, prereqs = Rake.application.resolve_args(args)
+ db, prereqs = args.keys.first, args.values.first
file(File.expand_path(db)=>prereqs) do |task|
rm_rf task.name if File.exist?(task.name)
Buildr.ant("derby") do |ant|
@@ -45,11 +45,6 @@
end
end
- protected
-
- # This will download all the required artifacts before returning a classpath, and we
want to do this only once.
- def requires()
- @requires ||=
Buildr.artifacts(REQUIRES).each(&:invoke).map(&:to_s).join(File::PATH_SEPARATOR)
- end
end
+
end
Modified: branches/ODE/ODE-1.x/tasks/jbi.rake
===================================================================
--- branches/ODE/ODE-1.x/tasks/jbi.rake 2010-04-14 15:43:12 UTC (rev 619)
+++ branches/ODE/ODE-1.x/tasks/jbi.rake 2010-04-14 18:25:55 UTC (rev 620)
@@ -145,14 +145,13 @@
class Project
- def package_as_jbi(file_name, options)
- # The file name extension is zip, not jbi. And we also need to reset
- # the type on the artifact specification.
- # The file type is ZIP, not JBI, so update the file name/spec accordingly.
- options[:type] = :zip
- file_name = path_to(:target, Artifact.hash_to_file_name(options))
- JBITask.define_task(file_name) unless Rake::Task.task_defined?(file_name)
- file(file_name)
+
+ def package_as_jbi(file_name) #:nodoc
+ JBITask.define_task(file_name)
end
+ def package_as_jbi_spec(spec) #:nodoc
+ spec.merge({ :type=>:zip })
+ end
+
end
Modified: branches/ODE/ODE-1.x/tasks/nativedb.rake
===================================================================
--- branches/ODE/ODE-1.x/tasks/nativedb.rake 2010-04-14 15:43:12 UTC (rev 619)
+++ branches/ODE/ODE-1.x/tasks/nativedb.rake 2010-04-14 18:25:55 UTC (rev 620)
@@ -42,7 +42,7 @@
def create_hib_db(name, args)
if File.exist? SETTINGS
require SETTINGS
- db, dbprops = Rake.application.resolve_args(args)
+ db, dbprops = args.keys.first, args.values.first
file(File.expand_path(db)) do |task|
puts "Creating(preparing) database: #{db}."
rm_rf task.name if File.exist?(task.name)
@@ -67,7 +67,7 @@
def create_jpa_db(base, name, args)
if File.exist? SETTINGS
require SETTINGS
- db, dbprops = Rake.application.resolve_args(args)
+ db, dbprops = args.keys.first, args.values.first
file(File.expand_path(db)) do |task|
puts "Creating(preparing) database: #{db}."
rm_rf task.name if File.exist?(task.name)
Added: branches/ODE/ODE-1.x/tools/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/tools/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/tools/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,56 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-tools</artifactId>
+ <name>ODE :: Command Line Tools</name>
+
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-bpel-compiler</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-utils</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>ant</groupId>
+ <artifactId>ant</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-httpclient</groupId>
+ <artifactId>commons-httpclient</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-logging</groupId>
+ <artifactId>commons-logging</artifactId>
+ </dependency>
+
+ </dependencies>
+</project>
Modified:
branches/ODE/ODE-1.x/tools/src/main/java/org/apache/ode/tools/bpelc/BpelCompileCommand.java
===================================================================
---
branches/ODE/ODE-1.x/tools/src/main/java/org/apache/ode/tools/bpelc/BpelCompileCommand.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/tools/src/main/java/org/apache/ode/tools/bpelc/BpelCompileCommand.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -20,6 +20,7 @@
package org.apache.ode.tools.bpelc;
import org.apache.ode.bpel.compiler.BpelC;
+import org.apache.ode.bpel.compiler.BpelCompiler;
import org.apache.ode.bpel.compiler.api.CompilationException;
import org.apache.ode.bpel.compiler.api.CompilationMessage;
import org.apache.ode.bpel.compiler.api.CompileListener;
@@ -118,7 +119,7 @@
try {
long start = System.currentTimeMillis();
- compiler.compile(bpelFile);
+ compiler.compile(bpelFile,
BpelCompiler.getVersion(_outputDir.getAbsolutePath()));
long t = System.currentTimeMillis() - start;
_cc.info("Compilation completed in " + t + "ms");
}
Added: branches/ODE/ODE-1.x/utils/pom.xml
===================================================================
--- branches/ODE/ODE-1.x/utils/pom.xml (rev 0)
+++ branches/ODE/ODE-1.x/utils/pom.xml 2010-04-14 18:25:55 UTC (rev 620)
@@ -0,0 +1,142 @@
+<?xml version="1.0"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~
http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+
+<project>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode-utils</artifactId>
+ <name>ODE :: Utilities</name>
+ <packaging>jar</packaging>
+ <modelVersion>4.0.0</modelVersion>
+
+ <parent>
+ <groupId>org.apache.ode</groupId>
+ <artifactId>ode</artifactId>
+ <version>1.3.4-SNAPSHOT</version>
+ </parent>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.ws.commons.axiom</groupId>
+ <artifactId>axiom-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ws.commons.axiom</groupId>
+ <artifactId>axiom-impl</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ws.commons.axiom</groupId>
+ <artifactId>axiom-dom</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>wsdl4j</groupId>
+ <artifactId>wsdl4j</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-collections</groupId>
+ <artifactId>commons-collections</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-httpclient</groupId>
+ <artifactId>commons-httpclient</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-codec</groupId>
+ <artifactId>commons-codec</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>log4j</groupId>
+ <artifactId>log4j</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>xstream</groupId>
+ <artifactId>xstream</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-stax-api_1.0_spec</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-adb</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-codegen</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-kernel</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-java2wsdl</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-jibx</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-saaj</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.axis2</groupId>
+ <artifactId>axis2-xmlbeans</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon-dom</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon-xqj</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>net.sf.saxon</groupId>
+ <artifactId>saxon-xpath</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-lang</groupId>
+ <artifactId>commons-lang</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <artifactId>maven-surefire-plugin</artifactId>
+ <configuration>
+ <excludes>
+ <exclude>**/*TestResources.java</exclude>
+ <exclude>**/*HierarchicalPropertiesTest.java</exclude>
+ </excludes>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+</project>
Modified: branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/DOMUtils.java
===================================================================
--- branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/DOMUtils.java 2010-04-14
15:43:12 UTC (rev 619)
+++ branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/DOMUtils.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -422,7 +422,7 @@
String value = null;
short nodeType = node.getNodeType();
- if (nodeType == Node.ELEMENT_NODE || nodeType == Node.DOCUMENT_NODE) {
+ if (nodeType == Node.ELEMENT_NODE || nodeType == Node.DOCUMENT_NODE || nodeType
== Node.DOCUMENT_FRAGMENT_NODE) {
// serializer doesn't handle Node type well, only Element
DOMSerializerImpl ser = new DOMSerializerImpl();
ser.setParameter(Constants.DOM_NAMESPACES, Boolean.TRUE);
@@ -1242,4 +1242,13 @@
}
}
}
+
+ public static Element stringToDOM(byte[] bytes) throws SAXException, IOException {
+ return stringToDOM(new String(bytes));
+ }
+
+ public static byte[] domToBytes(Element element) {
+ String stringifiedElement = domToString(element);
+ return (stringifiedElement != null) ? stringifiedElement.getBytes() : null;
+ }
}
Modified: branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/GUID.java
===================================================================
--- branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/GUID.java 2010-04-14
15:43:12 UTC (rev 619)
+++ branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/GUID.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -251,4 +251,18 @@
super("Malformed guid: " + guid);
}
}
+
+ public static String makeGUID(String digest) {
+ String val = "0";
+ int maxlen = 32;
+ int base = 34;
+ int prime = 31;
+ for (int i = 0; i < digest.length(); i++) {
+ char c = digest.charAt(i);
+ val = new BigInteger(val, base).add(BigInteger.valueOf((long)
c)).multiply(BigInteger.valueOf(prime)).toString(base);
+ if (val.length() > maxlen) val = val.substring(0, maxlen);
+ }
+
+ return val;
+ }
}
Modified: branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/Properties.java
===================================================================
---
branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/Properties.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/Properties.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -48,14 +48,18 @@
public class Properties {
/**
- * Property used to define how long (in miiliseconds) the message will wait for a
response. Default value is {@link #DEFAULT_MEX_TIMEOUT}
+ * Property used to define how long (in milliseconds) the message will wait for a
response. Default value is {@link #DEFAULT_MEX_TIMEOUT}
*/
public static final String PROP_MEX_TIMEOUT = "mex.timeout";
+
+ /**
+ * Property used to define how long (in milliseconds) the message will wait for a
response for process-to-process invocations.
+ */
+ public static final String PROP_P2P_MEX_TIMEOUT = "p2p.mex.timeout";
+
// its default value
public static final int DEFAULT_MEX_TIMEOUT = 2 * 60 * 1000;
- public static final String PROP_MEX_FAILURE_VERBOSE =
"mex.failure.verbose";
-
public static final String PROP_HTTP_CONNECTION_TIMEOUT =
HttpConnectionParams.CONNECTION_TIMEOUT;
public static final String PROP_HTTP_SOCKET_TIMEOUT = HttpMethodParams.SO_TIMEOUT;
public static final String PROP_HTTP_PROTOCOL_VERSION =
HttpMethodParams.PROTOCOL_VERSION;
@@ -191,12 +195,14 @@
}
if (properties.containsKey(PROP_JMS_REPLY_TIMEOUT)) {
String value = properties.get(PROP_JMS_REPLY_TIMEOUT);
- try {
- options.setProperty(JMSConstants.JMS_WAIT_REPLY,
Long.valueOf(value));
- } catch (NumberFormatException e) {
- if (log.isWarnEnabled())
- log.warn("Mal-formatted Property: [" +
Properties.PROP_JMS_REPLY_TIMEOUT + "=" + value + "]. Long expected.
Property will be skipped.");
- }
+ options.setProperty(JMSConstants.JMS_WAIT_REPLY, value);
+ // The value of this property must be a string object, not a long object.
+// try {
+// options.setProperty(JMSConstants.JMS_WAIT_REPLY,
Long.valueOf(value));
+// } catch (NumberFormatException e) {
+// if (log.isWarnEnabled())
+// log.warn("Mal-formatted Property: [" +
Properties.PROP_JMS_REPLY_TIMEOUT + "=" + value + "]. Long expected.
Property will be skipped.");
+// }
}
if (properties.containsKey(PROP_JMS_DESTINATION_TYPE)) {
String value = properties.get(PROP_JMS_DESTINATION_TYPE);
Modified: branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/WatchDog.java
===================================================================
--- branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/WatchDog.java 2010-04-14
15:43:12 UTC (rev 619)
+++ branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/WatchDog.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -151,6 +151,16 @@
if (log.isInfoEnabled()) log.info("[" + mutable +
"]" + " does not exist.");
}
}
+ }catch(Exception e){
+ if (log.isDebugEnabled()) log.debug("[" + mutable +
"]" + " exception occurred during check.", e);
+ // reset so that the next check retries right away
+ expire = 0;
+ lastModif = null;
+ existedBefore = false;
+ warnedAlready = false;
+ observer.reset();
+ if (log.isInfoEnabled()) log.info("[" + mutable + "]
resetted.");
+ throw new RuntimeException(e);
} finally {
observer.getLock().unlock();
}
@@ -244,6 +254,8 @@
*/
void init();
+ void reset();
+
/**
* Called only if the resource previously existed and now does not exist.
* <br/>The default implementation invokes {@link #init()} .
@@ -288,6 +300,10 @@
public void init() {
}
+ public void reset() {
+ object = null;
+ }
+
/**
* delegate to #init
*/
Modified:
branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/xsd/SchemaModelImpl.java
===================================================================
---
branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/xsd/SchemaModelImpl.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/xsd/SchemaModelImpl.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -191,8 +191,14 @@
location = resourceIdentifier.getNamespace();
else if (resourceIdentifier.getLiteralSystemId() != null &&
_schemas.get(resourceIdentifier.getLiteralSystemId()) != null)
location = resourceIdentifier.getLiteralSystemId();
- else if (resourceIdentifier.getBaseSystemId() != null &&
_schemas.get(resourceIdentifier.getBaseSystemId()) != null)
- location = resourceIdentifier.getBaseSystemId();
+ else if (resourceIdentifier.getExpandedSystemId() != null &&
_schemas.get(resourceIdentifier.getExpandedSystemId()) != null)
+ location = resourceIdentifier.getExpandedSystemId();
+ else {
+ if (__log.isDebugEnabled()) {
+ __log.debug("Available schemas " + _schemas.keySet());
+ }
+ throw new IllegalStateException("Schema " + resourceIdentifier
+ " not captured");
+ }
src.setByteStream(new ByteArrayInputStream(_schemas.get(location)));
return src;
Modified: branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/xsd/XSUtils.java
===================================================================
---
branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/xsd/XSUtils.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/xsd/XSUtils.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -30,6 +30,7 @@
import org.apache.xerces.xs.XSModel;
import org.w3c.dom.ls.LSInput;
+import java.io.InputStream;
import java.io.UnsupportedEncodingException;
import java.net.URI;
import java.util.ArrayList;
@@ -47,26 +48,6 @@
private static final XsdMessages __msgs =
MessageBundle.getMessages(XsdMessages.class);
/**
- * Recursively "capture" XSD documents starting at the given URI and
- * using an {@link XMLEntityResolver} to obtain document streams. The
- * result is a mapping from the XSD URI to a byte array containing the
- * "captured" document stream.
- *
- * @param initialUri URI of the schema
- * @param resolver {@link XMLEntityResolver} used to obtain XSD document streams
- *
- * @return mapping between schema URI and the "captured" schema text (in
byte form)
- */
- public static Map<URI, byte[]> captureSchema(String initialUri,
XMLEntityResolver resolver)
- throws XsdException {
- DOMInputImpl input = new DOMInputImpl();
- input.setSystemId(initialUri);
- Map<URI, byte[]> ret = captureSchema(input, resolver);
-
- return ret;
- }
-
- /**
* Capture the schemas supplied by the reader. <code>systemURI</code>
is
* required to resolve any relative uris encountered during the parse.
*
@@ -76,25 +57,17 @@
*
* @return
*/
- public static Map<URI, byte[]> captureSchema(URI systemURI, String schemaData,
+ public static Map<URI, byte[]> captureSchema(URI systemURI, byte[] schemaData,
XMLEntityResolver resolver) throws
XsdException {
if (__log.isDebugEnabled())
__log.debug("captureSchema(URI,Text,...): systemURI=" +
systemURI);
DOMInputImpl input = new DOMInputImpl();
input.setSystemId(systemURI.toString());
- input.setStringData(schemaData);
+ input.setStringData(new String(schemaData));
Map<URI, byte[]> ret = captureSchema(input, resolver);
- // Let's not forget the root schema.
- try {
- // TODO don't assume UTF-8 - but which encoding is required?
- // either we need another parameter or the entire idea of
- // passing in a String needs to be revised.
- ret.put(systemURI, schemaData.getBytes("UTF-8"));
- } catch (UnsupportedEncodingException uenc) {
- throw new RuntimeException(uenc);
- }
+ ret.put(systemURI, schemaData);
return ret;
}
@@ -106,7 +79,7 @@
Map<URI, byte[]> captured = new HashMap<URI, byte[]>();
if (resolver == null) {
- resolver = new DefaultXMLEntityResolver();
+ throw new IllegalStateException("no resolver set");
}
CapturingXMLEntityResolver cr = new CapturingXMLEntityResolver(captured,
resolver);
Modified:
branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/xsl/XslTransformHandler.java
===================================================================
---
branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/xsl/XslTransformHandler.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/utils/src/main/java/org/apache/ode/utils/xsl/XslTransformHandler.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -38,6 +38,9 @@
import javax.xml.transform.stream.StreamSource;
import org.apache.commons.collections.map.MultiKeyMap;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+import org.apache.ode.utils.DOMUtils;
import org.w3c.dom.Document;
import org.w3c.dom.Node;
@@ -52,6 +55,8 @@
*/
public class XslTransformHandler {
+ private static final Log __log = LogFactory.getLog(XslTransformHandler.class);
+
private static XslTransformHandler __singleton;
private TransformerFactory _transformerFactory = null;
@@ -138,19 +143,23 @@
}
}
String method = tf.getOutputProperties().getProperty("method");
- if (method == null || method.equals("xml") ||
method.equals("html")) {
+ if (method == null || "xml".equals(method)) {
DOMResult result = new DOMResult();
tf.transform(source, result);
Node node = result.getNode();
if(node.getNodeType() == Node.DOCUMENT_NODE)
node = ((Document)node).getDocumentElement();
+ if(__log.isDebugEnabled()) __log.debug("Returned node:
type="+node.getNodeType()+", "+ DOMUtils.domToString(node));
return node;
} else {
+ // text and html outputs are handled the same way
StringWriter writerResult = new StringWriter();
StreamResult result = new StreamResult(writerResult);
tf.transform(source, result);
writerResult.flush();
- return writerResult.toString();
+ String output = writerResult.toString();
+ if(__log.isDebugEnabled()) __log.debug("Returned string: "+output);
+ return output;
}
} catch (TransformerConfigurationException e) {
throw new XslTransformException(e);
Modified:
branches/ODE/ODE-1.x/utils/src/test/java/org/apache/ode/utils/xsd/SchemaCaptureTest.java
===================================================================
---
branches/ODE/ODE-1.x/utils/src/test/java/org/apache/ode/utils/xsd/SchemaCaptureTest.java 2010-04-14
15:43:12 UTC (rev 619)
+++
branches/ODE/ODE-1.x/utils/src/test/java/org/apache/ode/utils/xsd/SchemaCaptureTest.java 2010-04-14
18:25:55 UTC (rev 620)
@@ -18,8 +18,18 @@
*/
package org.apache.ode.utils.xsd;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+import org.apache.ode.utils.StreamUtils;
import org.apache.ode.utils.TestResources;
+import org.apache.xerces.xni.XMLResourceIdentifier;
+import org.apache.xerces.xni.XNIException;
+import org.apache.xerces.xni.parser.XMLEntityResolver;
+import org.apache.xerces.xni.parser.XMLInputSource;
+import java.io.FileInputStream;
+import java.io.IOException;
+import java.io.InputStream;
import java.net.URI;
import java.util.Map;
@@ -29,13 +39,33 @@
* Test schema capture functionality.
*/
public class SchemaCaptureTest extends TestCase {
+ private static Log __log = LogFactory.getLog(SchemaCaptureTest.class);
public void testSchemaCapture() throws Exception {
- System.out.println("GETTING RESOURCE " +
TestResources.getRetailerSchema());
- String initialURI = TestResources.getRetailerSchema().toExternalForm();
- Map<URI, byte[]> s = XSUtils.captureSchema(initialURI, new
DefaultXMLEntityResolver());
+ __log.debug("GETTING RESOURCE " + TestResources.getRetailerSchema());
+ InputStream xsdStream = new
FileInputStream(TestResources.getRetailerSchema().getFile());
+ byte[] data;
+ try {
+ data = StreamUtils.read(xsdStream);
+ } finally {
+ xsdStream.close();
+ }
+
+ Map<URI, byte[]> s = XSUtils.captureSchema(URI.create("schema.xsd"),
data, new XMLEntityResolver() {
+ public XMLInputSource resolveEntity(XMLResourceIdentifier resourceIdentifier)
throws XNIException, IOException {
+ XMLInputSource src = new XMLInputSource(resourceIdentifier);
+ String literalUri = resourceIdentifier.getLiteralSystemId();
+
+ if (literalUri != null) {
+
src.setByteStream(getClass().getClassLoader().getResourceAsStream(literalUri));
+ }
+
+ return src;
+ }
+ });
// we expect the root schema and three includes
- assertEquals(4, s.size());
+ __log.debug("loaded " + s.keySet());
+ assertEquals(5, s.size());
}
}
Added: branches/ODE/ODE-1.x/utils/src/test/resources/log4j.properties
===================================================================
--- branches/ODE/ODE-1.x/utils/src/test/resources/log4j.properties
(rev 0)
+++ branches/ODE/ODE-1.x/utils/src/test/resources/log4j.properties 2010-04-14 18:25:55 UTC
(rev 620)
@@ -0,0 +1,34 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+#
http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+# Set root logger level to WARN and its only appender to CONSOLE
+log4j.rootLogger=WARN, FILE
+
+# log4j properties to work with commandline tools.
+log4j.category.org.apache.ode=DEBUG
+
+# Console appender
+#log4j.appender.CONSOLE=org.apache.log4j.ConsoleAppender
+#log4j.appender.CONSOLE.layout=org.apache.log4j.PatternLayout
+#log4j.appender.CONSOLE.layout.ConversionPattern=%p - %C{1}.%M(%L) | %m%n
+
+log4j.appender.FILE=org.apache.log4j.FileAppender
+log4j.appender.FILE.File=target/test.log
+log4j.appender.FILE.layout=org.apache.log4j.PatternLayout
+log4j.appender.FILE.layout.ConversionPattern=%d{MM-dd@HH:mm:ss} %-5p (%13F:%L) %3x -
%m%n
+log4j.appender.FILE.append=false
+