From c791fd804344b8719fb69be84b8174c84cc4f4dc Mon Sep 17 00:00:00 2001 From: jsdelfino Date: Mon, 10 Jan 2011 19:51:07 +0000 Subject: Sandbox to experiment with Databinding automatic wrapper transformations. git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@1057335 13f79535-47bb-0310-9956-ffa450edef68 --- .../helloworld-bpel-contribution/README | 31 ++++ .../helloworld-bpel-contribution/build.xml | 95 +++++++++++ .../helloworld-bpel.png | Bin 0 -> 8897 bytes .../helloworld-bpel.svg | 179 +++++++++++++++++++++ .../helloworld-bpel-contribution/pom.xml | 76 +++++++++ .../src/main/java/helloworld/Hello.java | 29 ++++ .../main/resources/META-INF/sca-contribution.xml | 23 +++ .../src/main/resources/helloworld.bpel | 80 +++++++++ .../src/main/resources/helloworld.composite | 29 ++++ .../src/main/resources/helloworld.wsdl | 94 +++++++++++ .../src/main/resources/log4j.properties | 35 ++++ 11 files changed, 671 insertions(+) create mode 100644 sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/README create mode 100644 sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/build.xml create mode 100644 sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/helloworld-bpel.png create mode 100644 sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/helloworld-bpel.svg create mode 100644 sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/pom.xml create mode 100644 sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/src/main/java/helloworld/Hello.java create mode 100644 sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/src/main/resources/META-INF/sca-contribution.xml create mode 100644 sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/src/main/resources/helloworld.bpel create mode 100644 sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/src/main/resources/helloworld.composite create mode 100644 sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/src/main/resources/helloworld.wsdl create mode 100644 sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/src/main/resources/log4j.properties (limited to 'sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution') diff --git a/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/README b/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/README new file mode 100644 index 0000000000..c84dba22f4 --- /dev/null +++ b/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/README @@ -0,0 +1,31 @@ +Hello World BPEL Sample +====================================== +This sample demonstrates an SCA service implemented by a BPEL process. + +See http://tuscany.apache.org/documentation-2x/20-beta-samples-documentation.html +for more information + +=============== OLD INFO ====================== + +mkdir target\classes +mkdir target\wsdl2java-source +java -cp ..\..\lib\tuscany-sca-manifest.jar org.apache.tuscany.sdo.generate.XSD2JavaGenerator -targetDirectory target/wsdl2java-source -prefix HelloWorld -noContainment -noUnsettable src/main/resources/helloworld.wsdl +java -cp ..\..\lib\tuscany-sca-manifest.jar org.apache.tuscany.tools.wsdl2java.generate.WSDL2JavaGenerator -targetDirectory target/wsdl2java-source src/main/resources/helloworld.wsdl +unzip ..\..\lib\ode-dao-jpa-ojpa-derby-1.1.zip -d target\database +javac -d target\classes -cp target\classes;..\..\lib\tuscany-sca-manifest.jar -sourcepath src\main\java;target\wsdl2java-source -target 1.5 -g -source 1.5 src\main\java\helloworld\BPELClient.java +copy src\main\resources\* target\classes +java -cp ..\..\lib\tuscany-sca-manifest.jar;target\classes;target\database helloworld.BPELClient + +and on *nix do + +mkdir target/classes +mkdir target/wsdl2java-source +java -cp ../../lib/tuscany-sca-manifest.jar org.apache.tuscany.sdo.generate.XSD2JavaGenerator -targetDirectory target/wsdl2java-source -prefix HelloWorld -noContainment -noUnsettable src/main/resources/helloworld.wsdl +java -cp ../../lib/tuscany-sca-manifest.jar org.apache.tuscany.tools.wsdl2java.generate.WSDL2JavaGenerator -targetDirectory target/wsdl2java-source src/main/resources/helloworld.wsdl +unzip ../../lib/ode-dao-jpa-ojpa-derby-1.1.zip -d target/database +javac -d target/classes -cp target/classes;../../lib/tuscany-sca-manifest.jar -sourcepath src/main/java;target/wsdl2java-source -target 1.5 -g -source 1.5 src/main/java/helloworld/BPELClient.java +cp src/main/resources/* target/classes +java -cp ../../lib/tuscany-sca-manifest.jar:target/classes:target/database helloworld.BPELClient + +The sample will start an embedded BPEL engine, deploy a process and invoke it. + diff --git a/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/build.xml b/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/build.xml new file mode 100644 index 0000000000..d94388f466 --- /dev/null +++ b/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/build.xml @@ -0,0 +1,95 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/helloworld-bpel.png b/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/helloworld-bpel.png new file mode 100644 index 0000000000..5f53a3c5d1 Binary files /dev/null and b/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/helloworld-bpel.png differ diff --git a/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/helloworld-bpel.svg b/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/helloworld-bpel.svg new file mode 100644 index 0000000000..5a98f1a07c --- /dev/null +++ b/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/helloworld-bpel.svg @@ -0,0 +1,179 @@ + + + + + + + + + + image/svg+xml + + + + + + + + helloworldws + + HelloWorldServiceComponent + + HelloWorldWebService + + implementation.bpel helloworld.bpel + + diff --git a/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/pom.xml b/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/pom.xml new file mode 100644 index 0000000000..f847ff9322 --- /dev/null +++ b/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/pom.xml @@ -0,0 +1,76 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + tuscany-sample-implementation-bpel + 2.0-SNAPSHOT + ../pom.xml + + + zip + sample-implementation-bpel-helloworld-contribution + Apache Tuscany SCA Sample implementation.bpel HelloWorld Contribution + + + + org.apache.tuscany.sca + tuscany-sca-api + 2.0-SNAPSHOT + provided + + + junit + junit + 4.8.1 + test + + + + + ${artifactId} + + + + + org.apache.tuscany.maven.plugins + maven-zip-plugin + alpha2 + true + + + + + org.apache.tuscany.maven.plugins + maven-tuscany-plugin + 2.0-SNAPSHOT + + + org.apache.tuscany.sca + tuscany-implementation-bpel-runtime + 2.0-SNAPSHOT + + + + + + + diff --git a/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/src/main/java/helloworld/Hello.java b/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/src/main/java/helloworld/Hello.java new file mode 100644 index 0000000000..dbd3854d7c --- /dev/null +++ b/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/src/main/java/helloworld/Hello.java @@ -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. + */ + +package helloworld; + +import org.oasisopen.sca.annotation.Remotable; + +@Remotable +public interface Hello { + + String hello(String name); + +} diff --git a/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/src/main/resources/META-INF/sca-contribution.xml b/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/src/main/resources/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..4a56523adb --- /dev/null +++ b/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/src/main/resources/META-INF/sca-contribution.xml @@ -0,0 +1,23 @@ + + + + + \ No newline at end of file diff --git a/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/src/main/resources/helloworld.bpel b/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/src/main/resources/helloworld.bpel new file mode 100644 index 0000000000..d58768adfa --- /dev/null +++ b/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/src/main/resources/helloworld.bpel @@ -0,0 +1,80 @@ + + + + + + + + + + + + + + + + + + + + + + concat($helloMessage.TestPart/test:arg0/text(), ' World') + + + + + + + + + Dummy + + + + + + + + $helloMessageResponse.TestResponse/test:messageResponse + + + + + diff --git a/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/src/main/resources/helloworld.composite b/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/src/main/resources/helloworld.composite new file mode 100644 index 0000000000..08350e8417 --- /dev/null +++ b/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/src/main/resources/helloworld.composite @@ -0,0 +1,29 @@ + + + + + + + + + diff --git a/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/src/main/resources/helloworld.wsdl b/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/src/main/resources/helloworld.wsdl new file mode 100644 index 0000000000..cf966264ef --- /dev/null +++ b/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/src/main/resources/helloworld.wsdl @@ -0,0 +1,94 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/src/main/resources/log4j.properties b/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/src/main/resources/log4j.properties new file mode 100644 index 0000000000..8649a71550 --- /dev/null +++ b/sandbox/sebastien/java/wrapped/samples/learning-more/implementation-bpel/helloworld-bpel-contribution/src/main/resources/log4j.properties @@ -0,0 +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. +# + +# Set root logger level to WARN and its only appender to CONSOLE +log4j.rootLogger=OFF, CONSOLE + +# log4j properties to work with commandline tools. +log4j.category.org.mortbay=OFF +log4j.category.org.hibernate.type=OFF +log4j.category.org.objectweb=OFF +log4j.category.org.apache.ode.sql=OFF +log4j.category.org.apache.ode.axis2=OFF +log4j.category.org.apache.ode.bpel.engine=OFF +log4j.category.org.apache.ode.daohib.bpel.CorrelatorDaoImpl=OFF +log4j.category.org.apache.ode.bpel.epr=OFF +log4j.category.org.apache.openjpa.kernel=OFF + +# 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 \ No newline at end of file -- cgit v1.2.3