From e5c07cc6de9743faec0e6819c5cc24c1055e24b4 Mon Sep 17 00:00:00 2001 From: fmoga Date: Mon, 20 Sep 2010 13:05:28 +0000 Subject: Moved more samples. git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@998914 13f79535-47bb-0310-9956-ffa450edef68 --- .../implementation-web/helloworld-stripes/pom.xml | 112 +++++++++++++ .../main/java/mystripes/action/BaseActionBean.java | 33 ++++ .../main/java/mystripes/action/HomeActionBean.java | 45 ++++++ .../src/main/java/sample/HelloworldService.java | 25 +++ .../main/java/sample/HelloworldServiceImpl.java | 28 ++++ .../src/main/resources/StripesResources.properties | 73 +++++++++ .../src/main/resources/log4j.properties | 48 ++++++ .../src/main/webapp/WEB-INF/jsp/home.jsp | 26 +++ .../src/main/webapp/WEB-INF/jsp/layout.jsp | 39 +++++ .../src/main/webapp/WEB-INF/jsp/taglibs.jsp | 29 ++++ .../src/main/webapp/WEB-INF/web.composite | 34 ++++ .../src/main/webapp/WEB-INF/web.xml | 61 +++++++ .../helloworld-stripes/src/main/webapp/index.html | 24 +++ .../helloworld-stripes/src/test/java/README | 7 + .../src/test/java/itest/HelloworldTestCase.java | 53 ++++++ .../sca-features/binding-jms/helloworld-jms/README | 131 +++++++++++++++ .../binding-jms/helloworld-jms/pom.xml | 96 +++++++++++ .../src/main/java/sample/HelloWorldClient.java | 37 +++++ .../src/main/java/sample/HelloWorldService.java | 29 ++++ .../main/java/sample/HelloWorldServiceImpl.java | 31 ++++ .../src/main/webapp/META-INF/context.xml | 34 ++++ .../src/main/webapp/WEB-INF/jetty-env.xml | 48 ++++++ .../src/main/webapp/WEB-INF/web.composite | 44 +++++ .../helloworld-jms/src/main/webapp/WEB-INF/web.xml | 66 ++++++++ .../helloworld-jms/src/main/webapp/hello.jsp | 41 +++++ .../helloworld-bpel-contribution/README | 153 ++++++++++++++++++ .../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 ++++ .../helloworld-bpel-webapp/README | 7 + .../helloworld-bpel-webapp/pom.xml | 160 ++++++++++++++++++ .../src/main/java/sample/HelloworldService.java | 28 ++++ .../src/main/resources/helloworld.bpel | 66 ++++++++ .../src/main/resources/helloworld.wsdl | 82 ++++++++++ .../src/main/webapp/WEB-INF/web.composite | 37 +++++ .../src/main/webapp/WEB-INF/web.xml | 41 +++++ .../src/main/webapp/hello.jsp | 36 +++++ .../temp/helloworld-bpel-contribution/README | 153 ------------------ .../temp/helloworld-bpel-contribution/build.xml | 95 ----------- .../helloworld-bpel.png | Bin 8897 -> 0 bytes .../helloworld-bpel.svg | 179 --------------------- .../temp/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 ---- sandbox/samples/temp/helloworld-bpel-webapp/README | 7 - .../samples/temp/helloworld-bpel-webapp/pom.xml | 160 ------------------ .../src/main/java/sample/HelloworldService.java | 28 ---- .../src/main/resources/helloworld.bpel | 66 -------- .../src/main/resources/helloworld.wsdl | 82 ---------- .../src/main/webapp/WEB-INF/web.composite | 37 ----- .../src/main/webapp/WEB-INF/web.xml | 41 ----- .../src/main/webapp/hello.jsp | 36 ----- sandbox/samples/temp/helloworld-jms/README | 131 --------------- sandbox/samples/temp/helloworld-jms/pom.xml | 96 ----------- .../src/main/java/sample/HelloWorldClient.java | 37 ----- .../src/main/java/sample/HelloWorldService.java | 29 ---- .../main/java/sample/HelloWorldServiceImpl.java | 31 ---- .../src/main/webapp/META-INF/context.xml | 34 ---- .../src/main/webapp/WEB-INF/jetty-env.xml | 48 ------ .../src/main/webapp/WEB-INF/web.composite | 44 ----- .../helloworld-jms/src/main/webapp/WEB-INF/web.xml | 66 -------- .../temp/helloworld-jms/src/main/webapp/hello.jsp | 41 ----- sandbox/samples/temp/helloworld-stripes/pom.xml | 112 ------------- .../main/java/mystripes/action/BaseActionBean.java | 33 ---- .../main/java/mystripes/action/HomeActionBean.java | 45 ------ .../src/main/java/sample/HelloworldService.java | 25 --- .../main/java/sample/HelloworldServiceImpl.java | 28 ---- .../src/main/resources/StripesResources.properties | 73 --------- .../src/main/resources/log4j.properties | 48 ------ .../src/main/webapp/WEB-INF/jsp/home.jsp | 26 --- .../src/main/webapp/WEB-INF/jsp/layout.jsp | 39 ----- .../src/main/webapp/WEB-INF/jsp/taglibs.jsp | 29 ---- .../src/main/webapp/WEB-INF/web.composite | 34 ---- .../src/main/webapp/WEB-INF/web.xml | 61 ------- .../helloworld-stripes/src/main/webapp/index.html | 24 --- .../temp/helloworld-stripes/src/test/java/README | 7 - .../src/test/java/itest/HelloworldTestCase.java | 53 ------ 88 files changed, 2444 insertions(+), 2444 deletions(-) create mode 100644 sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/pom.xml create mode 100644 sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/java/mystripes/action/BaseActionBean.java create mode 100644 sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/java/mystripes/action/HomeActionBean.java create mode 100644 sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/java/sample/HelloworldService.java create mode 100644 sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/java/sample/HelloworldServiceImpl.java create mode 100644 sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/resources/StripesResources.properties create mode 100644 sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/resources/log4j.properties create mode 100644 sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/webapp/WEB-INF/jsp/home.jsp create mode 100644 sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/webapp/WEB-INF/jsp/layout.jsp create mode 100644 sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/webapp/WEB-INF/jsp/taglibs.jsp create mode 100644 sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/webapp/WEB-INF/web.composite create mode 100644 sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/webapp/WEB-INF/web.xml create mode 100644 sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/webapp/index.html create mode 100644 sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/test/java/README create mode 100644 sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/test/java/itest/HelloworldTestCase.java create mode 100644 sandbox/samples/sca-features/binding-jms/helloworld-jms/README create mode 100644 sandbox/samples/sca-features/binding-jms/helloworld-jms/pom.xml create mode 100644 sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/java/sample/HelloWorldClient.java create mode 100644 sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/java/sample/HelloWorldService.java create mode 100644 sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/java/sample/HelloWorldServiceImpl.java create mode 100644 sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/webapp/META-INF/context.xml create mode 100644 sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/webapp/WEB-INF/jetty-env.xml create mode 100644 sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/webapp/WEB-INF/web.composite create mode 100644 sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/webapp/WEB-INF/web.xml create mode 100644 sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/webapp/hello.jsp create mode 100644 sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/README create mode 100644 sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/build.xml create mode 100644 sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/helloworld-bpel.png create mode 100644 sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/helloworld-bpel.svg create mode 100644 sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/pom.xml create mode 100644 sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/src/main/java/helloworld/Hello.java create mode 100644 sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/src/main/resources/META-INF/sca-contribution.xml create mode 100644 sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/src/main/resources/helloworld.bpel create mode 100644 sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/src/main/resources/helloworld.composite create mode 100644 sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/src/main/resources/helloworld.wsdl create mode 100644 sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/src/main/resources/log4j.properties create mode 100644 sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/README create mode 100644 sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/pom.xml create mode 100644 sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/src/main/java/sample/HelloworldService.java create mode 100644 sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/src/main/resources/helloworld.bpel create mode 100644 sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/src/main/resources/helloworld.wsdl create mode 100644 sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/src/main/webapp/WEB-INF/web.composite create mode 100644 sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/src/main/webapp/WEB-INF/web.xml create mode 100644 sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/src/main/webapp/hello.jsp delete mode 100644 sandbox/samples/temp/helloworld-bpel-contribution/README delete mode 100644 sandbox/samples/temp/helloworld-bpel-contribution/build.xml delete mode 100644 sandbox/samples/temp/helloworld-bpel-contribution/helloworld-bpel.png delete mode 100644 sandbox/samples/temp/helloworld-bpel-contribution/helloworld-bpel.svg delete mode 100644 sandbox/samples/temp/helloworld-bpel-contribution/pom.xml delete mode 100644 sandbox/samples/temp/helloworld-bpel-contribution/src/main/java/helloworld/Hello.java delete mode 100644 sandbox/samples/temp/helloworld-bpel-contribution/src/main/resources/META-INF/sca-contribution.xml delete mode 100644 sandbox/samples/temp/helloworld-bpel-contribution/src/main/resources/helloworld.bpel delete mode 100644 sandbox/samples/temp/helloworld-bpel-contribution/src/main/resources/helloworld.composite delete mode 100644 sandbox/samples/temp/helloworld-bpel-contribution/src/main/resources/helloworld.wsdl delete mode 100644 sandbox/samples/temp/helloworld-bpel-contribution/src/main/resources/log4j.properties delete mode 100644 sandbox/samples/temp/helloworld-bpel-webapp/README delete mode 100644 sandbox/samples/temp/helloworld-bpel-webapp/pom.xml delete mode 100644 sandbox/samples/temp/helloworld-bpel-webapp/src/main/java/sample/HelloworldService.java delete mode 100644 sandbox/samples/temp/helloworld-bpel-webapp/src/main/resources/helloworld.bpel delete mode 100644 sandbox/samples/temp/helloworld-bpel-webapp/src/main/resources/helloworld.wsdl delete mode 100644 sandbox/samples/temp/helloworld-bpel-webapp/src/main/webapp/WEB-INF/web.composite delete mode 100644 sandbox/samples/temp/helloworld-bpel-webapp/src/main/webapp/WEB-INF/web.xml delete mode 100644 sandbox/samples/temp/helloworld-bpel-webapp/src/main/webapp/hello.jsp delete mode 100644 sandbox/samples/temp/helloworld-jms/README delete mode 100644 sandbox/samples/temp/helloworld-jms/pom.xml delete mode 100644 sandbox/samples/temp/helloworld-jms/src/main/java/sample/HelloWorldClient.java delete mode 100644 sandbox/samples/temp/helloworld-jms/src/main/java/sample/HelloWorldService.java delete mode 100644 sandbox/samples/temp/helloworld-jms/src/main/java/sample/HelloWorldServiceImpl.java delete mode 100644 sandbox/samples/temp/helloworld-jms/src/main/webapp/META-INF/context.xml delete mode 100644 sandbox/samples/temp/helloworld-jms/src/main/webapp/WEB-INF/jetty-env.xml delete mode 100644 sandbox/samples/temp/helloworld-jms/src/main/webapp/WEB-INF/web.composite delete mode 100644 sandbox/samples/temp/helloworld-jms/src/main/webapp/WEB-INF/web.xml delete mode 100644 sandbox/samples/temp/helloworld-jms/src/main/webapp/hello.jsp delete mode 100644 sandbox/samples/temp/helloworld-stripes/pom.xml delete mode 100644 sandbox/samples/temp/helloworld-stripes/src/main/java/mystripes/action/BaseActionBean.java delete mode 100644 sandbox/samples/temp/helloworld-stripes/src/main/java/mystripes/action/HomeActionBean.java delete mode 100644 sandbox/samples/temp/helloworld-stripes/src/main/java/sample/HelloworldService.java delete mode 100644 sandbox/samples/temp/helloworld-stripes/src/main/java/sample/HelloworldServiceImpl.java delete mode 100644 sandbox/samples/temp/helloworld-stripes/src/main/resources/StripesResources.properties delete mode 100644 sandbox/samples/temp/helloworld-stripes/src/main/resources/log4j.properties delete mode 100644 sandbox/samples/temp/helloworld-stripes/src/main/webapp/WEB-INF/jsp/home.jsp delete mode 100644 sandbox/samples/temp/helloworld-stripes/src/main/webapp/WEB-INF/jsp/layout.jsp delete mode 100644 sandbox/samples/temp/helloworld-stripes/src/main/webapp/WEB-INF/jsp/taglibs.jsp delete mode 100644 sandbox/samples/temp/helloworld-stripes/src/main/webapp/WEB-INF/web.composite delete mode 100644 sandbox/samples/temp/helloworld-stripes/src/main/webapp/WEB-INF/web.xml delete mode 100644 sandbox/samples/temp/helloworld-stripes/src/main/webapp/index.html delete mode 100644 sandbox/samples/temp/helloworld-stripes/src/test/java/README delete mode 100644 sandbox/samples/temp/helloworld-stripes/src/test/java/itest/HelloworldTestCase.java (limited to 'sandbox/samples') diff --git a/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/pom.xml b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/pom.xml new file mode 100644 index 0000000000..16259aba62 --- /dev/null +++ b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/pom.xml @@ -0,0 +1,112 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + tuscany-samples + 2.0-SNAPSHOT + ../../pom.xml + + + sample-helloworld-stripes-webapp + war + Apache Tuscany SCA Sample Helloworld using Stripes + + + + + + org.apache.tuscany.sca.shades + tuscany-base + 2.0-SNAPSHOT + + + + + net.sourceforge.stripes + stripes + 1.5.2 + + + + taglibs + standard + 1.1.2 + + + + junit + junit + 4.8.1 + test + + + + net.sourceforge.htmlunit + htmlunit + 2.6 + test + + + + + + helloworld-stripes + + + org.mortbay.jetty + maven-jetty-plugin + 6.1.18 + + helloworld-stripes + foo + 9999 + + + + start-jetty + process-test-classes + + run + + + 0 + true + + + 8085 + + + + + + stop-jetty + prepare-package + + stop + + + + + + + + diff --git a/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/java/mystripes/action/BaseActionBean.java b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/java/mystripes/action/BaseActionBean.java new file mode 100644 index 0000000000..0ab02682ac --- /dev/null +++ b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/java/mystripes/action/BaseActionBean.java @@ -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. + */ +package mystripes.action; + +import net.sourceforge.stripes.action.ActionBean; +import net.sourceforge.stripes.action.ActionBeanContext; + +public class BaseActionBean implements ActionBean { + private ActionBeanContext context; + + public ActionBeanContext getContext() { + return context; + } + public void setContext(ActionBeanContext context) { + this.context = context; + } +} diff --git a/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/java/mystripes/action/HomeActionBean.java b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/java/mystripes/action/HomeActionBean.java new file mode 100644 index 0000000000..0385c92369 --- /dev/null +++ b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/java/mystripes/action/HomeActionBean.java @@ -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 mystripes.action; + +import net.sourceforge.stripes.action.DefaultHandler; +import net.sourceforge.stripes.action.ForwardResolution; +import net.sourceforge.stripes.action.Resolution; +import net.sourceforge.stripes.action.UrlBinding; + +import org.oasisopen.sca.annotation.Reference; + +import sample.HelloworldService; + +@UrlBinding("/Home.htm") +public class HomeActionBean extends BaseActionBean { + + @Reference + HelloworldService service; + + @DefaultHandler + public Resolution view() { + return new ForwardResolution("/WEB-INF/jsp/home.jsp"); + } + + public String getHello() { + return service.sayHello("world"); + } + +} diff --git a/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/java/sample/HelloworldService.java b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/java/sample/HelloworldService.java new file mode 100644 index 0000000000..53ff7a5ca1 --- /dev/null +++ b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/java/sample/HelloworldService.java @@ -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 sample; + +public interface HelloworldService { + + String sayHello(String name); + +} diff --git a/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/java/sample/HelloworldServiceImpl.java b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/java/sample/HelloworldServiceImpl.java new file mode 100644 index 0000000000..a22c095f29 --- /dev/null +++ b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/java/sample/HelloworldServiceImpl.java @@ -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 sample; + + +public class HelloworldServiceImpl implements HelloworldService { + + public String sayHello(String name) { + return "Hello " + name; + } + +} diff --git a/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/resources/StripesResources.properties b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/resources/StripesResources.properties new file mode 100644 index 0000000000..902842a19e --- /dev/null +++ b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/resources/StripesResources.properties @@ -0,0 +1,73 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +# Resource strings used by the tag when there are no nested tags +stripes.errors.header=
Please fix the following errors:
    +stripes.errors.beforeError=
  1. +stripes.errors.afterError=
  2. +stripes.errors.footer=
+ +# Resource strings used by the tag when displaying errors for a +# specific field (e.g. ). If not supplied the +# values above will be used instead. +stripes.fieldErrors.header= +stripes.fieldErrors.beforeError= +stripes.fieldErrors.afterError=
+stripes.fieldErrors.footer= + +# Resource strings used by the stripes:messages tag +stripes.messages.header=
    +stripes.messages.beforeMessage=
  • +stripes.messages.afterMessage=
  • +stripes.messages.footer=
+ +# Validation error messages produced by Stripes' built-in converter classes. These +# are default error messages and can be overridden on per-field and per-form levels. +# Using the 'invalidNumber' error for a field 'age' of a form posting to +# '/user/Profile.action', the keys looked for (in order) would be: +# 1: /user/Profile.action.age.invalidNumber +# 2: /user/Profile.action.age.errorMessage +# 3: age.errorMessage +# 4: /user/Profile.action.invalidNumber +# 5: converter.number.invalidNumber +converter.number.invalidNumber=The value ({1}) entered in field {0} must be a valid number +converter.byte.outOfRange=The value ({1}) entered in field {0} was out of the range {2} to {3} +converter.short.outOfRange=The value ({1}) entered in field {0} was out of the range {2} to {3} +converter.integer.outOfRange=The value ({1}) entered in field {0} was out of the range {2} to {3} +converter.float.outOfRange=The value ({1}) entered in field {0} was out of the range {2} to {3} +converter.enum.notAnEnumeratedValue=The value "{1}" is not a valid value for field {0} +converter.date.invalidDate=The value ({1}) entered in field {0} must be a valid date +converter.email.invalidEmail=The value ({1}) entered is not a valid email address +converter.creditCard.invalidCreditCard=The value ({1}) entered is not a valid credit card number + +# Validation error messages produced by Stripes' annotation based validations. These +# are default error messages and can be overridden on per-field and per-form levels. +# Using the 'valueNotPresent' required field error for a field 'username' of a form +# posting to '/user/Register.action', the keys looked for (in order) would be: +# 1: /user/Register.action.username.valueNotPresent +# 2: /user/Register.action.username.errorMessage +# 3: username.errorMessage +# 4: /user/Register.action.valueNotPresent +# 5: validation.required.valueNotPresent +validation.required.valueNotPresent={0} is a required field +validation.minlength.valueTooShort={0} must be at least {2} characters long +validation.maxlength.valueTooLong={0} must be no more than {2} characters long +validation.minvalue.valueBelowMinimum=The minimum allowed value for {0} is {2} +validation.maxvalue.valueAboveMaximum=The maximum allowed value for {0} is {2} +validation.mask.valueDoesNotMatch={1} is not a valid {0} +validation.expression.valueFailedExpression=The value supplied ({1}) for field {0} is invalid +validation.file.postBodyTooBig=Total upload size of {3} KB exceeds the maximum size of {2} KB diff --git a/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/resources/log4j.properties b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/resources/log4j.properties new file mode 100644 index 0000000000..2741999098 --- /dev/null +++ b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/resources/log4j.properties @@ -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. +# + +# log4j.properties + +# Set up a logger to the console +log4j.appender.stdout=org.apache.log4j.ConsoleAppender +log4j.appender.stdout.layout=org.apache.log4j.PatternLayout +log4j.appender.stdout.layout.ConversionPattern=[%d{HH:mm:ss}] %-5p %c %x - %m%n + +# Use this to only see log messages beyond a certain threshold in the console +#log4j.appender.stdout.Threshold=WARN + +# Set up a logger to a log file +log4j.appender.logfile=org.apache.log4j.DailyRollingFileAppender +log4j.appender.logfile.layout=org.apache.log4j.PatternLayout +log4j.appender.logfile.layout.ConversionPattern=[%d{HH:mm:ss}] %-5p %c %x - %m%n +log4j.appender.logfile.File=${user.home}/stripesquick.log +log4j.appender.logfile.DatePattern='.'yyyy-MM-dd + +# Use this to only see log messages beyond a certain threshold in the log file +#log4j.appender.logfile.Threshold=WARN + +# Logger settings +log4j.rootLogger=INFO, stdout, logfile + +# Valid levels are TRACE, DEBUG, INFO, WARN, ERROR, FATAL +# Change to TRACE or DEBUG to see more log messages +log4j.logger.net.sourceforge.stripes=WARN +log4j.logger.org.stripesbook.quickstart=INFO +log4j.logger.org.mortbay.log=INFO +log4j.logger.org=WARN +log4j.logger.com=WARN +log4j.logger.net=WARN diff --git a/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/webapp/WEB-INF/jsp/home.jsp b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/webapp/WEB-INF/jsp/home.jsp new file mode 100644 index 0000000000..0681c1f2bf --- /dev/null +++ b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/webapp/WEB-INF/jsp/home.jsp @@ -0,0 +1,26 @@ + +<%@ include file="/WEB-INF/jsp/taglibs.jsp" %> + + + +

sayHello returns: ${actionBean.hello}

+

Congratulations, you've set up a Stripes SCA project!

+
+
diff --git a/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/webapp/WEB-INF/jsp/layout.jsp b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/webapp/WEB-INF/jsp/layout.jsp new file mode 100644 index 0000000000..d0fb716b80 --- /dev/null +++ b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/webapp/WEB-INF/jsp/layout.jsp @@ -0,0 +1,39 @@ + +<%@ include file="/WEB-INF/jsp/taglibs.jsp" %> + + + + + + + ${title} + + + + + +
+ + +
+ + + +
\ No newline at end of file diff --git a/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/webapp/WEB-INF/jsp/taglibs.jsp b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/webapp/WEB-INF/jsp/taglibs.jsp new file mode 100644 index 0000000000..f85602fcfa --- /dev/null +++ b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/webapp/WEB-INF/jsp/taglibs.jsp @@ -0,0 +1,29 @@ + +<%-- Stripes TLD --%> +<%@ taglib prefix="s" uri="http://stripes.sourceforge.net/stripes.tld" %> +<%@ taglib prefix="sdyn" uri="http://stripes.sourceforge.net/stripes-dynattr.tld" %> + +<%-- JSTL TLDs --%> +<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> +<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %> +<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %> + +<%-- This is so that you can conveniently refer to the context path with ${contextPath} --%> + diff --git a/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/webapp/WEB-INF/web.composite b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/webapp/WEB-INF/web.composite new file mode 100644 index 0000000000..8976adde3c --- /dev/null +++ b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/webapp/WEB-INF/web.composite @@ -0,0 +1,34 @@ + + + + + + + + + + + + + + diff --git a/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/webapp/WEB-INF/web.xml b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/webapp/WEB-INF/web.xml new file mode 100644 index 0000000000..f01584cc2f --- /dev/null +++ b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/webapp/WEB-INF/web.xml @@ -0,0 +1,61 @@ + + + + + Apache Tuscany Helloworld Stripes Sample + + + org.apache.tuscany.sca.host.webapp.TuscanyContextListener + + + + StripesFilter + net.sourceforge.stripes.controller.StripesFilter + + ActionResolver.Packages + mystripes.action + + + Extension.Packages + org.apache.tuscany.sca.stripes + + + + + DispatcherServlet + net.sourceforge.stripes.controller.DispatcherServlet + 1 + + + + StripesFilter + DispatcherServlet + REQUEST + FORWARD + + + + DispatcherServlet + *.htm + + + + index.html + + + diff --git a/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/webapp/index.html b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/webapp/index.html new file mode 100644 index 0000000000..c79d29e6a5 --- /dev/null +++ b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/main/webapp/index.html @@ -0,0 +1,24 @@ + + + + + + + diff --git a/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/test/java/README b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/test/java/README new file mode 100644 index 0000000000..828aadb0f1 --- /dev/null +++ b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/test/java/README @@ -0,0 +1,7 @@ +The README in the /samples directory provides +general instructions about building and running samples. (where +distribution-unpack-dir is the directory in which you unpacked the tuscany +binary distribution archive). Take a look there first (noting at you read it that this sample +is not a new style sample). + +TODO - finish \ No newline at end of file diff --git a/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/test/java/itest/HelloworldTestCase.java b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/test/java/itest/HelloworldTestCase.java new file mode 100644 index 0000000000..7f4359fa43 --- /dev/null +++ b/sandbox/samples/sca-extensions/implementation-web/helloworld-stripes/src/test/java/itest/HelloworldTestCase.java @@ -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 itest; + +import static org.junit.Assert.assertEquals; + +import java.io.IOException; +import java.net.MalformedURLException; +import java.util.Iterator; + +import org.junit.Test; + +import com.gargoylesoftware.htmlunit.FailingHttpStatusCodeException; +import com.gargoylesoftware.htmlunit.WebClient; +import com.gargoylesoftware.htmlunit.html.HtmlElement; +import com.gargoylesoftware.htmlunit.html.HtmlPage; +import com.gargoylesoftware.htmlunit.html.HtmlParagraph; + +/** + */ +public class HelloworldTestCase { + + @Test + public void testA() throws FailingHttpStatusCodeException, MalformedURLException, IOException { + HtmlPage page = (HtmlPage)new WebClient().getPage("http://localhost:8085/helloworld-stripes"); + Iterator ss = page.getAllHtmlChildElements().iterator(); + while(ss.hasNext()) { + HtmlElement htmlElement = (HtmlElement) ss.next(); + if( htmlElement instanceof HtmlParagraph) { + assertEquals("sayHello returns: Hello world", htmlElement.asText()); + break; + } + } + } + +} diff --git a/sandbox/samples/sca-features/binding-jms/helloworld-jms/README b/sandbox/samples/sca-features/binding-jms/helloworld-jms/README new file mode 100644 index 0000000000..88bbe9adcb --- /dev/null +++ b/sandbox/samples/sca-features/binding-jms/helloworld-jms/README @@ -0,0 +1,131 @@ +JMS HelloWorld Sample +===================== +This sample demonstrates a simple webapp containing a hello world style client +and service using the JMS binding for request-response style messaging. + +The README in the samples directory (the directory above this) provides +general instructions about building and running samples. Take a look there +first. + +As this sample provides a web app there is a manual step where the WAR file +that contains the sample is copied to your web app container. If you just want +to give this sample a go deploy the WAR file (target/helloworld-jms.war ) +to you web application server. Alternatevly, the sample pom.xml is configured +with the Jetty plugin so you can run the it with Jetty by simply doing "mvn jetty:run". + +Once the web app is deployed use your browser to visit the following URL; + +http://localhost:8080/helloworld-jms + +The port and hostname will of course vary depending on your local installation. + +Configuring the JMS resources +----------------------------- + +The sample requires JMS resources be manually configured in the server environment, these are: + +- a JMS connection factory named "ConnectionFactory" +- a JMS queue named "HelloWorldService" + +See the following for how to define these resources depending on the application server being used: + +Tuscany with embedded ActiveMQ broker +------------------------------------- + + +Apache Tomcat +------------- + +No configuration is necessary for Tomcat as the sample WAR includes everything pre-configured to run +an ActiveMQ embedded JMS broker and to configure the JMS resources in JNDI. + +The JNDI resources are configured in the META-INF/comtext.xml file, for more information on running +ActiveMQ in Tomcat see: http://activemq.apache.org/tomcat.html + + +Apache Geronimo +--------------- + +For Apache Geronimo 2.0.1 (2.0.2 fails to define JMS resources for me) + +Logon to the Geronimo Server Console (http://localhost:8080/console, uid system, pswd manager) + +In the Console Navigation on the left under Services click JMS Resources + +At the bottom of the JMS Resources panel click under Create a new JMS Resource Group click For ActiveMQ + +In Resource Group Name enter "MyRGN" and click next + +At JMS Resource Group click Add Connection Factory + +For JMS Factory Type choose javax.jms.ConnectionFactory and click Next + +In Connection Factory Name enter "ConnectionFactory" and click Next + +Click Add destination + +For JMS Destination Type choose javax.jms.Queue and click Next + +Enter "HelloWorldService" for both Message Destination Name and PhysicalName and click Next + +Click Deploy Now + +Thats it, you're done. + + +WebSphere +--------- + +To define the JMS resources in a new WebSphere Application Server 6.1 installation: + +1) First define a Service integration bus: + +Logon to the WebSphere Integrated Solutions Console (http://localhost:9060/ibm/console) + +On the Left hand menu expand Service integration, and click on Buses. + +In the Buses panel click on New + +Enter a name for the bus, eg MyBus, and click Next, and then click Finish and Save the changes. + +In the Buses panel click on MyBus + +Find the Topology secion and click on Bus members + +Click on Add, leave the defaults and click Next, Next, Next, Finish, and Save the changes. + +Restart WebSphere and when back up logon back on to the Integrated Solutions Console + +2) Now define the JMS rescources + +On the Left hand menu expand Resources, and JMS and click on Connection Facotories. + +In the Connection factories panel click New. + +Leave the Default messaging provider and click OK + +Enter "ConnectionFactory" in the Name and JNDI name and in the Bus name in the Connection pane choose MyBus and click OK + +On the Left hand menu in JMS click on Queues + +In the Queues panel click New, accept the defaults and click OK + +Enter "HelloWorldService" for the Name and JNDI name and in the Bus name in the Connection pane choose MyBus, +and then in the Queue name drop down list choose "Create SIB destination" + +In the Set queue attributes panel enter "HelloWorldService" for the Identifier and click Next, Next, and Finish + +That should take you back to the Queues panel where you can click OK to create the new JMS queue. + +Save the changes + +Restart WebSphere and you're done. + + + +Others... +--------- + + + + \ No newline at end of file diff --git a/sandbox/samples/sca-features/binding-jms/helloworld-jms/pom.xml b/sandbox/samples/sca-features/binding-jms/helloworld-jms/pom.xml new file mode 100644 index 0000000000..326422ed7b --- /dev/null +++ b/sandbox/samples/sca-features/binding-jms/helloworld-jms/pom.xml @@ -0,0 +1,96 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + tuscany-samples + 2.0-SNAPSHOT + ../../pom.xml + + + sample-helloworld-jms-webapp + war + Apache Tuscany SCA Sample JMS HelloWorld in a WebApp + + + + + org.apache.tuscany.sca.shades + tuscany-base + 2.0-SNAPSHOT + + + org.apache.tuscany.sca.shades + tuscany-jms + 2.0-SNAPSHOT + + + + org.apache.activemq + activemq-core + 5.3.0 + runtime + + + + + + helloworld-jms + + + org.mortbay.jetty + maven-jetty-plugin + 6.1.18 + + helloworld-jms + foo + 9999 + + + + start-jetty + process-test-classes + + run + + + 0 + true + + + 8085 + + + + + + stop-jetty + prepare-package + + stop + + + + + + + + diff --git a/sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/java/sample/HelloWorldClient.java b/sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/java/sample/HelloWorldClient.java new file mode 100644 index 0000000000..f209f11605 --- /dev/null +++ b/sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/java/sample/HelloWorldClient.java @@ -0,0 +1,37 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT 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 sample; + +/** + * The HelloWorld client implementation + */ +public class HelloWorldClient implements HelloWorldService { + + HelloWorldService helloWorldRef; + + public String sayHello(String name) { + System.out.println("HelloWorldClient.sayHello " + name); + return helloWorldRef.sayHello(name); + } + + public void setHelloWorldRef(HelloWorldService helloWorldRef) { + System.out.println("HelloWorldClient.setHelloWorldService " + helloWorldRef); + this.helloWorldRef = helloWorldRef; + } +} \ No newline at end of file diff --git a/sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/java/sample/HelloWorldService.java b/sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/java/sample/HelloWorldService.java new file mode 100644 index 0000000000..df2a852161 --- /dev/null +++ b/sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/java/sample/HelloWorldService.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 sample; + +import org.oasisopen.sca.annotation.Remotable; + +/** + * The interface for the helloworld service + */ +@Remotable +public interface HelloWorldService { + public String sayHello(String name); +} diff --git a/sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/java/sample/HelloWorldServiceImpl.java b/sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/java/sample/HelloWorldServiceImpl.java new file mode 100644 index 0000000000..c09af51e23 --- /dev/null +++ b/sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/java/sample/HelloWorldServiceImpl.java @@ -0,0 +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. + */ +package sample; + +/** + * This class implements the HelloWorld service. + */ +public class HelloWorldServiceImpl implements HelloWorldService { + + public String sayHello(String name) { + System.out.println("HelloWorldServiceImpl.sayHello " + name); + return "Hello " + name; + } + +} diff --git a/sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/webapp/META-INF/context.xml b/sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/webapp/META-INF/context.xml new file mode 100644 index 0000000000..7575edfc29 --- /dev/null +++ b/sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/webapp/META-INF/context.xml @@ -0,0 +1,34 @@ + + + + + + + + + + + + \ No newline at end of file diff --git a/sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/webapp/WEB-INF/jetty-env.xml b/sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/webapp/WEB-INF/jetty-env.xml new file mode 100644 index 0000000000..a8cd27f6c6 --- /dev/null +++ b/sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/webapp/WEB-INF/jetty-env.xml @@ -0,0 +1,48 @@ + + + + + + + + + + + ConnectionFactory + + + vm://localhost?broker.persistent=false + + + + + + HelloWorldService + + + DEMO + + + + + diff --git a/sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/webapp/WEB-INF/web.composite b/sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/webapp/WEB-INF/web.composite new file mode 100644 index 0000000000..c51985bc30 --- /dev/null +++ b/sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/webapp/WEB-INF/web.composite @@ -0,0 +1,44 @@ + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/webapp/WEB-INF/web.xml b/sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/webapp/WEB-INF/web.xml new file mode 100644 index 0000000000..86710435ae --- /dev/null +++ b/sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/webapp/WEB-INF/web.xml @@ -0,0 +1,66 @@ + + + + + + + Apache Tuscany JMS Web Service Sample + + + tuscany + org.apache.tuscany.sca.host.webapp.TuscanyServletFilter + + + + tuscany + /* + + + + hello.jsp + + + + + + + diff --git a/sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/webapp/hello.jsp b/sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/webapp/hello.jsp new file mode 100644 index 0000000000..9ae037f2c2 --- /dev/null +++ b/sandbox/samples/sca-features/binding-jms/helloworld-jms/src/main/webapp/hello.jsp @@ -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. +--%> + +<%@ page contentType="text/html;charset=UTF-8" language="java" %> +<%@ taglib uri="http://www.osoa.org/sca/sca_jsp.tld" prefix="sca" %> + + + + +HelloWorld JMS sample + + + +If this sample is working correctly you should see "Hello World" on the next line... +

+<%= service.sayHello("world") %> +

+If you do not see "Hello World" on the line above then there has been a problem. +

+The sample requires JMS resources be manually configured in the server environment, these are: +a JMS connection factory named "ConnectionFactory", and a destination queues named "HelloWorldService". +See the sample README file for more information. + + + diff --git a/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/README b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/README new file mode 100644 index 0000000000..533743ebf6 --- /dev/null +++ b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/README @@ -0,0 +1,153 @@ +Hello World BPEL Sample +====================================== +This sample demonstrates an SCA service implemented by a BPEL process. + +The README in the /samples directory provides +general instructions about building and running samples. (where +distribution-unpack-dir is the directory in which you unpacked the tuscany +binary distribution archive). Take a look there first (noting at you read it that this sample +is not a new style sample). + +If you just want to run it to see what happens open a command prompt, navigate +to this sample directory, and do + +ant compile run + +OR if you don't have ant, on Windows 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 +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. + +Sample Overview +--------------- +The sample provides a single component that is wired to a service with a +web service binding. + +helloworld-bpel/ + src/ + main/ + java/ + helloworld/ + BPELClient.java - client application for + BEPELHelloWorldComponent + + resources/ + deploy.xml - ODE deployment descriptor + helloworld.bpel - helloworld bpel process + helloworld.componentType - helloworld bpel service description + helloworld.composite - the SCA assembly for this sample + helloworld.wsdl - the service description that describes + the bpel process + log4j.properties - logging configuration + + test/ + java/ + helloworld/ + BPELHelloWorldTestCase.java - JUnit test case + helloworld-bpel.png - a pictorial representation of the + sample .composite file + build.xml - the Ant build file + pom.xml - the Maven build file + +Building And Running The Sample Using Ant +----------------------------------------- + +With the binary distribution the sample can be built and run using Ant as +follows + +cd helloworld-bpel +ant compile +ant run + + +You should see the following output from the run target. + +run: + [java] Starting BPELHelloWorldComponent + [java] >>> Deploying : D:\temp\SCA1.1-RC1\tuscany-sca-1.1-incubating\samples\helloworld-bpel\target\classes + [java] ::arg:::::: + [java] Hello + [java] ::message:: + [java] Hello + [java] Status: RESPONSE + [java] Response: + [java] Hello World + [java] Hello World + [java] Stopping BPELHelloWorldComponent + [java] Stopped !!! + +BUILD SUCCESSFUL +Total time: 36 seconds + +Building And Running The Sample Using Maven +------------------------------------------- +With either the binary or source distributions the sample can be built and run +using Maven as follows. When using Maven, a simple test is present that exercise +the same logic as the client to invoke the BPEl process. + +cd helloworld-bpel +mvn + +You should see the following output from the test phase. + +- + +------------------------------------------------------- + T E S T S +------------------------------------------------------- +Running helloworld.BPELHelloWorldTestCase +Starting BPELHelloWorldComponent +>>> Deploying : D:\dev\Opensource\Apache\Tuscany\source\java-sca-1.1\samples\helloworld-bpel\target\classes +::arg:::::: +Hello +::message:: +Hello +Status: RESPONSE +Response: +Hello World +Stopping BPELHelloWorldComponent +Stopped !!! +Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 18.656 sec + +Results : + +Tests run: 1, Failures: 0, Errors: 0, Skipped: 0 + +[INFO] [jar:jar] +[INFO] Building jar: D:\dev\Opensource\Apache\Tuscany\source\java-sca-1.1\samples\helloworld-bpel\target\sample-helloworld-bpel.jar +[INFO] [install:install] +[INFO] Installing D:\dev\Opensource\Apache\Tuscany\source\java-sca-1.1\samples\helloworld-bpel\target\sample-helloworld-bpel.jar to C:\Documents and Settings\lresend +e\.m2\repository\org\apache\tuscany\sca\sample-helloworld-bpel\1.1-incubating-SNAPSHOT\sample-helloworld-bpel-1.1-incubating-SNAPSHOT.jar +[INFO] ------------------------------------------------------------------------ +[INFO] BUILD SUCCESSFUL +[INFO] ------------------------------------------------------------------------ +[INFO] Total time: 53 seconds +[INFO] Finished at: Sun Jan 13 09:54:39 PST 2008 +[INFO] Final Memory: 24M/43M +[INFO] ------------------------------------------------------------------------ + + +This shows that the Junit test cases have run successfully. diff --git a/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/build.xml b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/build.xml new file mode 100644 index 0000000000..008953e63b --- /dev/null +++ b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/build.xml @@ -0,0 +1,95 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/helloworld-bpel.png b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/helloworld-bpel.png new file mode 100644 index 0000000000..5f53a3c5d1 Binary files /dev/null and b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/helloworld-bpel.png differ diff --git a/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/helloworld-bpel.svg b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/helloworld-bpel.svg new file mode 100644 index 0000000000..5a98f1a07c --- /dev/null +++ b/sandbox/samples/sca-features/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/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/pom.xml b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/pom.xml new file mode 100644 index 0000000000..3f4be82f71 --- /dev/null +++ b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/pom.xml @@ -0,0 +1,76 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + tuscany-samples + 2.0-SNAPSHOT + ../pom.xml + + + zip + sample-helloworld-bpel + Apache Tuscany SCA Sample HelloWorld BPEL + + + + 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.shades + tuscany-bpel + 2.0-SNAPSHOT + + + + + + + diff --git a/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/src/main/java/helloworld/Hello.java b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/src/main/java/helloworld/Hello.java new file mode 100644 index 0000000000..dbd3854d7c --- /dev/null +++ b/sandbox/samples/sca-features/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/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/src/main/resources/META-INF/sca-contribution.xml b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/src/main/resources/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..4a56523adb --- /dev/null +++ b/sandbox/samples/sca-features/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/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/src/main/resources/helloworld.bpel b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/src/main/resources/helloworld.bpel new file mode 100644 index 0000000000..d58768adfa --- /dev/null +++ b/sandbox/samples/sca-features/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/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/src/main/resources/helloworld.composite b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/src/main/resources/helloworld.composite new file mode 100644 index 0000000000..08350e8417 --- /dev/null +++ b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/src/main/resources/helloworld.composite @@ -0,0 +1,29 @@ + + + + + + + + + diff --git a/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/src/main/resources/helloworld.wsdl b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/src/main/resources/helloworld.wsdl new file mode 100644 index 0000000000..cf966264ef --- /dev/null +++ b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/src/main/resources/helloworld.wsdl @@ -0,0 +1,94 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/src/main/resources/log4j.properties b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-contribution/src/main/resources/log4j.properties new file mode 100644 index 0000000000..8649a71550 --- /dev/null +++ b/sandbox/samples/sca-features/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 diff --git a/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/README b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/README new file mode 100644 index 0000000000..828aadb0f1 --- /dev/null +++ b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/README @@ -0,0 +1,7 @@ +The README in the /samples directory provides +general instructions about building and running samples. (where +distribution-unpack-dir is the directory in which you unpacked the tuscany +binary distribution archive). Take a look there first (noting at you read it that this sample +is not a new style sample). + +TODO - finish \ No newline at end of file diff --git a/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/pom.xml b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/pom.xml new file mode 100644 index 0000000000..1ca3770b74 --- /dev/null +++ b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/pom.xml @@ -0,0 +1,160 @@ + + + + + 4.0.0 + + org.apache.tuscany.sca + tuscany-samples + 2.0-SNAPSHOT + ../../pom.xml + + + sample-helloworld-bpel-webapp + war + Apache Tuscany SCA Sample Helloworld BPEL + + + 2.0-SNAPSHOT + 6.1.18 + + + + + + org.apache.tuscany.sca + tuscany-sca-api + ${tuscany.version} + + + + org.apache.tuscany.sca + tuscany-implementation-web-runtime + ${tuscany.version} + runtime + + + + org.apache.tuscany.sca + tuscany-implementation-bpel-runtime + ${tuscany.version} + runtime + + + + + junit + junit + 4.8.1 + test + + + + + org.mortbay.jetty + jetty + ${jetty.version} + provided + + + org.mortbay.jetty + jetty-util + ${jetty.version} + provided + + + org.mortbay.jetty + jetty-management + ${jetty.version} + provided + + + + + helloworld-bpel + + + + org.apache.maven.plugins + maven-dependency-plugin + + + unpack + compile + + unpack + + + + + org.apache.ode + ode-dao-jpa-ojpa-derby + 1.1.1 + zip + false + ${project.build.directory}/classes + **/* + + + + + + + + + org.mortbay.jetty + maven-jetty-plugin + 6.1.18 + + helloworld-bpel + foo + 9999 + + + + start-jetty + process-test-classes + + run + + + 0 + true + + + 8085 + + + + + + stop-jetty + prepare-package + + stop + + + + + + + + diff --git a/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/src/main/java/sample/HelloworldService.java b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/src/main/java/sample/HelloworldService.java new file mode 100644 index 0000000000..c1a50d9be5 --- /dev/null +++ b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/src/main/java/sample/HelloworldService.java @@ -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 sample; + +import org.oasisopen.sca.annotation.Remotable; + +@Remotable +public interface HelloworldService { + + String hello(String name); + +} diff --git a/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/src/main/resources/helloworld.bpel b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/src/main/resources/helloworld.bpel new file mode 100644 index 0000000000..f1e8895f76 --- /dev/null +++ b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/src/main/resources/helloworld.bpel @@ -0,0 +1,66 @@ + + + + + + + + + + + + + + + + + + + + concat('Hello ', $myVar.TestPart/test:message/text()) + + + + $tmpVar + $myVar.TestPart/test:message + + + + + diff --git a/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/src/main/resources/helloworld.wsdl b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/src/main/resources/helloworld.wsdl new file mode 100644 index 0000000000..46cf381577 --- /dev/null +++ b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/src/main/resources/helloworld.wsdl @@ -0,0 +1,82 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/src/main/webapp/WEB-INF/web.composite b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/src/main/webapp/WEB-INF/web.composite new file mode 100644 index 0000000000..3d36adadeb --- /dev/null +++ b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/src/main/webapp/WEB-INF/web.composite @@ -0,0 +1,37 @@ + + + + + + + + + + + + + + + + diff --git a/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/src/main/webapp/WEB-INF/web.xml b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/src/main/webapp/WEB-INF/web.xml new file mode 100644 index 0000000000..bf01a7b759 --- /dev/null +++ b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/src/main/webapp/WEB-INF/web.xml @@ -0,0 +1,41 @@ + + + + + helloworld-bpel + + + tuscany.helloworld-bpel + org.apache.tuscany.sca.host.webapp.TuscanyServletFilter + + + + tuscany.helloworld-bpel + /* + + + + hello.jsp + + + diff --git a/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/src/main/webapp/hello.jsp b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/src/main/webapp/hello.jsp new file mode 100644 index 0000000000..c52d7b1cb2 --- /dev/null +++ b/sandbox/samples/sca-features/implementation-bpel/helloworld-bpel-webapp/src/main/webapp/hello.jsp @@ -0,0 +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. +--%> +<%@ page contentType="text/html;charset=UTF-8" language="java" %> +<%@ taglib uri="http://www.osoa.org/sca/sca_jsp.tld" prefix="sca" %> + + + + + + +

helloworld-bpel

+ + Calling HelloworldService sayHello("world") returns: + +

+ + <%= service.hello("world") %> + + + diff --git a/sandbox/samples/temp/helloworld-bpel-contribution/README b/sandbox/samples/temp/helloworld-bpel-contribution/README deleted file mode 100644 index 533743ebf6..0000000000 --- a/sandbox/samples/temp/helloworld-bpel-contribution/README +++ /dev/null @@ -1,153 +0,0 @@ -Hello World BPEL Sample -====================================== -This sample demonstrates an SCA service implemented by a BPEL process. - -The README in the /samples directory provides -general instructions about building and running samples. (where -distribution-unpack-dir is the directory in which you unpacked the tuscany -binary distribution archive). Take a look there first (noting at you read it that this sample -is not a new style sample). - -If you just want to run it to see what happens open a command prompt, navigate -to this sample directory, and do - -ant compile run - -OR if you don't have ant, on Windows 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 -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. - -Sample Overview ---------------- -The sample provides a single component that is wired to a service with a -web service binding. - -helloworld-bpel/ - src/ - main/ - java/ - helloworld/ - BPELClient.java - client application for - BEPELHelloWorldComponent - - resources/ - deploy.xml - ODE deployment descriptor - helloworld.bpel - helloworld bpel process - helloworld.componentType - helloworld bpel service description - helloworld.composite - the SCA assembly for this sample - helloworld.wsdl - the service description that describes - the bpel process - log4j.properties - logging configuration - - test/ - java/ - helloworld/ - BPELHelloWorldTestCase.java - JUnit test case - helloworld-bpel.png - a pictorial representation of the - sample .composite file - build.xml - the Ant build file - pom.xml - the Maven build file - -Building And Running The Sample Using Ant ------------------------------------------ - -With the binary distribution the sample can be built and run using Ant as -follows - -cd helloworld-bpel -ant compile -ant run - - -You should see the following output from the run target. - -run: - [java] Starting BPELHelloWorldComponent - [java] >>> Deploying : D:\temp\SCA1.1-RC1\tuscany-sca-1.1-incubating\samples\helloworld-bpel\target\classes - [java] ::arg:::::: - [java] Hello - [java] ::message:: - [java] Hello - [java] Status: RESPONSE - [java] Response: - [java] Hello World - [java] Hello World - [java] Stopping BPELHelloWorldComponent - [java] Stopped !!! - -BUILD SUCCESSFUL -Total time: 36 seconds - -Building And Running The Sample Using Maven -------------------------------------------- -With either the binary or source distributions the sample can be built and run -using Maven as follows. When using Maven, a simple test is present that exercise -the same logic as the client to invoke the BPEl process. - -cd helloworld-bpel -mvn - -You should see the following output from the test phase. - -- - -------------------------------------------------------- - T E S T S -------------------------------------------------------- -Running helloworld.BPELHelloWorldTestCase -Starting BPELHelloWorldComponent ->>> Deploying : D:\dev\Opensource\Apache\Tuscany\source\java-sca-1.1\samples\helloworld-bpel\target\classes -::arg:::::: -Hello -::message:: -Hello -Status: RESPONSE -Response: -Hello World -Stopping BPELHelloWorldComponent -Stopped !!! -Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 18.656 sec - -Results : - -Tests run: 1, Failures: 0, Errors: 0, Skipped: 0 - -[INFO] [jar:jar] -[INFO] Building jar: D:\dev\Opensource\Apache\Tuscany\source\java-sca-1.1\samples\helloworld-bpel\target\sample-helloworld-bpel.jar -[INFO] [install:install] -[INFO] Installing D:\dev\Opensource\Apache\Tuscany\source\java-sca-1.1\samples\helloworld-bpel\target\sample-helloworld-bpel.jar to C:\Documents and Settings\lresend -e\.m2\repository\org\apache\tuscany\sca\sample-helloworld-bpel\1.1-incubating-SNAPSHOT\sample-helloworld-bpel-1.1-incubating-SNAPSHOT.jar -[INFO] ------------------------------------------------------------------------ -[INFO] BUILD SUCCESSFUL -[INFO] ------------------------------------------------------------------------ -[INFO] Total time: 53 seconds -[INFO] Finished at: Sun Jan 13 09:54:39 PST 2008 -[INFO] Final Memory: 24M/43M -[INFO] ------------------------------------------------------------------------ - - -This shows that the Junit test cases have run successfully. diff --git a/sandbox/samples/temp/helloworld-bpel-contribution/build.xml b/sandbox/samples/temp/helloworld-bpel-contribution/build.xml deleted file mode 100644 index 008953e63b..0000000000 --- a/sandbox/samples/temp/helloworld-bpel-contribution/build.xml +++ /dev/null @@ -1,95 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/sandbox/samples/temp/helloworld-bpel-contribution/helloworld-bpel.png b/sandbox/samples/temp/helloworld-bpel-contribution/helloworld-bpel.png deleted file mode 100644 index 5f53a3c5d1..0000000000 Binary files a/sandbox/samples/temp/helloworld-bpel-contribution/helloworld-bpel.png and /dev/null differ diff --git a/sandbox/samples/temp/helloworld-bpel-contribution/helloworld-bpel.svg b/sandbox/samples/temp/helloworld-bpel-contribution/helloworld-bpel.svg deleted file mode 100644 index 5a98f1a07c..0000000000 --- a/sandbox/samples/temp/helloworld-bpel-contribution/helloworld-bpel.svg +++ /dev/null @@ -1,179 +0,0 @@ - - - - - - - - - - image/svg+xml - - - - - - - - helloworldws - - HelloWorldServiceComponent - - HelloWorldWebService - - implementation.bpel helloworld.bpel - - diff --git a/sandbox/samples/temp/helloworld-bpel-contribution/pom.xml b/sandbox/samples/temp/helloworld-bpel-contribution/pom.xml deleted file mode 100644 index 3f4be82f71..0000000000 --- a/sandbox/samples/temp/helloworld-bpel-contribution/pom.xml +++ /dev/null @@ -1,76 +0,0 @@ - - - - 4.0.0 - - org.apache.tuscany.sca - tuscany-samples - 2.0-SNAPSHOT - ../pom.xml - - - zip - sample-helloworld-bpel - Apache Tuscany SCA Sample HelloWorld BPEL - - - - 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.shades - tuscany-bpel - 2.0-SNAPSHOT - - - - - - - diff --git a/sandbox/samples/temp/helloworld-bpel-contribution/src/main/java/helloworld/Hello.java b/sandbox/samples/temp/helloworld-bpel-contribution/src/main/java/helloworld/Hello.java deleted file mode 100644 index dbd3854d7c..0000000000 --- a/sandbox/samples/temp/helloworld-bpel-contribution/src/main/java/helloworld/Hello.java +++ /dev/null @@ -1,29 +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 helloworld; - -import org.oasisopen.sca.annotation.Remotable; - -@Remotable -public interface Hello { - - String hello(String name); - -} diff --git a/sandbox/samples/temp/helloworld-bpel-contribution/src/main/resources/META-INF/sca-contribution.xml b/sandbox/samples/temp/helloworld-bpel-contribution/src/main/resources/META-INF/sca-contribution.xml deleted file mode 100644 index 4a56523adb..0000000000 --- a/sandbox/samples/temp/helloworld-bpel-contribution/src/main/resources/META-INF/sca-contribution.xml +++ /dev/null @@ -1,23 +0,0 @@ - - - - - \ No newline at end of file diff --git a/sandbox/samples/temp/helloworld-bpel-contribution/src/main/resources/helloworld.bpel b/sandbox/samples/temp/helloworld-bpel-contribution/src/main/resources/helloworld.bpel deleted file mode 100644 index d58768adfa..0000000000 --- a/sandbox/samples/temp/helloworld-bpel-contribution/src/main/resources/helloworld.bpel +++ /dev/null @@ -1,80 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - concat($helloMessage.TestPart/test:arg0/text(), ' World') - - - - - - - - - Dummy - - - - - - - - $helloMessageResponse.TestResponse/test:messageResponse - - - - - diff --git a/sandbox/samples/temp/helloworld-bpel-contribution/src/main/resources/helloworld.composite b/sandbox/samples/temp/helloworld-bpel-contribution/src/main/resources/helloworld.composite deleted file mode 100644 index 08350e8417..0000000000 --- a/sandbox/samples/temp/helloworld-bpel-contribution/src/main/resources/helloworld.composite +++ /dev/null @@ -1,29 +0,0 @@ - - - - - - - - - diff --git a/sandbox/samples/temp/helloworld-bpel-contribution/src/main/resources/helloworld.wsdl b/sandbox/samples/temp/helloworld-bpel-contribution/src/main/resources/helloworld.wsdl deleted file mode 100644 index cf966264ef..0000000000 --- a/sandbox/samples/temp/helloworld-bpel-contribution/src/main/resources/helloworld.wsdl +++ /dev/null @@ -1,94 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/sandbox/samples/temp/helloworld-bpel-contribution/src/main/resources/log4j.properties b/sandbox/samples/temp/helloworld-bpel-contribution/src/main/resources/log4j.properties deleted file mode 100644 index 8649a71550..0000000000 --- a/sandbox/samples/temp/helloworld-bpel-contribution/src/main/resources/log4j.properties +++ /dev/null @@ -1,35 +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. -# - -# 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 diff --git a/sandbox/samples/temp/helloworld-bpel-webapp/README b/sandbox/samples/temp/helloworld-bpel-webapp/README deleted file mode 100644 index 828aadb0f1..0000000000 --- a/sandbox/samples/temp/helloworld-bpel-webapp/README +++ /dev/null @@ -1,7 +0,0 @@ -The README in the /samples directory provides -general instructions about building and running samples. (where -distribution-unpack-dir is the directory in which you unpacked the tuscany -binary distribution archive). Take a look there first (noting at you read it that this sample -is not a new style sample). - -TODO - finish \ No newline at end of file diff --git a/sandbox/samples/temp/helloworld-bpel-webapp/pom.xml b/sandbox/samples/temp/helloworld-bpel-webapp/pom.xml deleted file mode 100644 index 1ca3770b74..0000000000 --- a/sandbox/samples/temp/helloworld-bpel-webapp/pom.xml +++ /dev/null @@ -1,160 +0,0 @@ - - - - - 4.0.0 - - org.apache.tuscany.sca - tuscany-samples - 2.0-SNAPSHOT - ../../pom.xml - - - sample-helloworld-bpel-webapp - war - Apache Tuscany SCA Sample Helloworld BPEL - - - 2.0-SNAPSHOT - 6.1.18 - - - - - - org.apache.tuscany.sca - tuscany-sca-api - ${tuscany.version} - - - - org.apache.tuscany.sca - tuscany-implementation-web-runtime - ${tuscany.version} - runtime - - - - org.apache.tuscany.sca - tuscany-implementation-bpel-runtime - ${tuscany.version} - runtime - - - - - junit - junit - 4.8.1 - test - - - - - org.mortbay.jetty - jetty - ${jetty.version} - provided - - - org.mortbay.jetty - jetty-util - ${jetty.version} - provided - - - org.mortbay.jetty - jetty-management - ${jetty.version} - provided - - - - - helloworld-bpel - - - - org.apache.maven.plugins - maven-dependency-plugin - - - unpack - compile - - unpack - - - - - org.apache.ode - ode-dao-jpa-ojpa-derby - 1.1.1 - zip - false - ${project.build.directory}/classes - **/* - - - - - - - - - org.mortbay.jetty - maven-jetty-plugin - 6.1.18 - - helloworld-bpel - foo - 9999 - - - - start-jetty - process-test-classes - - run - - - 0 - true - - - 8085 - - - - - - stop-jetty - prepare-package - - stop - - - - - - - - diff --git a/sandbox/samples/temp/helloworld-bpel-webapp/src/main/java/sample/HelloworldService.java b/sandbox/samples/temp/helloworld-bpel-webapp/src/main/java/sample/HelloworldService.java deleted file mode 100644 index c1a50d9be5..0000000000 --- a/sandbox/samples/temp/helloworld-bpel-webapp/src/main/java/sample/HelloworldService.java +++ /dev/null @@ -1,28 +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 sample; - -import org.oasisopen.sca.annotation.Remotable; - -@Remotable -public interface HelloworldService { - - String hello(String name); - -} diff --git a/sandbox/samples/temp/helloworld-bpel-webapp/src/main/resources/helloworld.bpel b/sandbox/samples/temp/helloworld-bpel-webapp/src/main/resources/helloworld.bpel deleted file mode 100644 index f1e8895f76..0000000000 --- a/sandbox/samples/temp/helloworld-bpel-webapp/src/main/resources/helloworld.bpel +++ /dev/null @@ -1,66 +0,0 @@ - - - - - - - - - - - - - - - - - - - - concat('Hello ', $myVar.TestPart/test:message/text()) - - - - $tmpVar - $myVar.TestPart/test:message - - - - - diff --git a/sandbox/samples/temp/helloworld-bpel-webapp/src/main/resources/helloworld.wsdl b/sandbox/samples/temp/helloworld-bpel-webapp/src/main/resources/helloworld.wsdl deleted file mode 100644 index 46cf381577..0000000000 --- a/sandbox/samples/temp/helloworld-bpel-webapp/src/main/resources/helloworld.wsdl +++ /dev/null @@ -1,82 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/sandbox/samples/temp/helloworld-bpel-webapp/src/main/webapp/WEB-INF/web.composite b/sandbox/samples/temp/helloworld-bpel-webapp/src/main/webapp/WEB-INF/web.composite deleted file mode 100644 index 3d36adadeb..0000000000 --- a/sandbox/samples/temp/helloworld-bpel-webapp/src/main/webapp/WEB-INF/web.composite +++ /dev/null @@ -1,37 +0,0 @@ - - - - - - - - - - - - - - - - diff --git a/sandbox/samples/temp/helloworld-bpel-webapp/src/main/webapp/WEB-INF/web.xml b/sandbox/samples/temp/helloworld-bpel-webapp/src/main/webapp/WEB-INF/web.xml deleted file mode 100644 index bf01a7b759..0000000000 --- a/sandbox/samples/temp/helloworld-bpel-webapp/src/main/webapp/WEB-INF/web.xml +++ /dev/null @@ -1,41 +0,0 @@ - - - - - helloworld-bpel - - - tuscany.helloworld-bpel - org.apache.tuscany.sca.host.webapp.TuscanyServletFilter - - - - tuscany.helloworld-bpel - /* - - - - hello.jsp - - - diff --git a/sandbox/samples/temp/helloworld-bpel-webapp/src/main/webapp/hello.jsp b/sandbox/samples/temp/helloworld-bpel-webapp/src/main/webapp/hello.jsp deleted file mode 100644 index c52d7b1cb2..0000000000 --- a/sandbox/samples/temp/helloworld-bpel-webapp/src/main/webapp/hello.jsp +++ /dev/null @@ -1,36 +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. ---%> -<%@ page contentType="text/html;charset=UTF-8" language="java" %> -<%@ taglib uri="http://www.osoa.org/sca/sca_jsp.tld" prefix="sca" %> - - - - - - -

helloworld-bpel

- - Calling HelloworldService sayHello("world") returns: - -

- - <%= service.hello("world") %> - - - diff --git a/sandbox/samples/temp/helloworld-jms/README b/sandbox/samples/temp/helloworld-jms/README deleted file mode 100644 index 88bbe9adcb..0000000000 --- a/sandbox/samples/temp/helloworld-jms/README +++ /dev/null @@ -1,131 +0,0 @@ -JMS HelloWorld Sample -===================== -This sample demonstrates a simple webapp containing a hello world style client -and service using the JMS binding for request-response style messaging. - -The README in the samples directory (the directory above this) provides -general instructions about building and running samples. Take a look there -first. - -As this sample provides a web app there is a manual step where the WAR file -that contains the sample is copied to your web app container. If you just want -to give this sample a go deploy the WAR file (target/helloworld-jms.war ) -to you web application server. Alternatevly, the sample pom.xml is configured -with the Jetty plugin so you can run the it with Jetty by simply doing "mvn jetty:run". - -Once the web app is deployed use your browser to visit the following URL; - -http://localhost:8080/helloworld-jms - -The port and hostname will of course vary depending on your local installation. - -Configuring the JMS resources ------------------------------ - -The sample requires JMS resources be manually configured in the server environment, these are: - -- a JMS connection factory named "ConnectionFactory" -- a JMS queue named "HelloWorldService" - -See the following for how to define these resources depending on the application server being used: - -Tuscany with embedded ActiveMQ broker -------------------------------------- - - -Apache Tomcat -------------- - -No configuration is necessary for Tomcat as the sample WAR includes everything pre-configured to run -an ActiveMQ embedded JMS broker and to configure the JMS resources in JNDI. - -The JNDI resources are configured in the META-INF/comtext.xml file, for more information on running -ActiveMQ in Tomcat see: http://activemq.apache.org/tomcat.html - - -Apache Geronimo ---------------- - -For Apache Geronimo 2.0.1 (2.0.2 fails to define JMS resources for me) - -Logon to the Geronimo Server Console (http://localhost:8080/console, uid system, pswd manager) - -In the Console Navigation on the left under Services click JMS Resources - -At the bottom of the JMS Resources panel click under Create a new JMS Resource Group click For ActiveMQ - -In Resource Group Name enter "MyRGN" and click next - -At JMS Resource Group click Add Connection Factory - -For JMS Factory Type choose javax.jms.ConnectionFactory and click Next - -In Connection Factory Name enter "ConnectionFactory" and click Next - -Click Add destination - -For JMS Destination Type choose javax.jms.Queue and click Next - -Enter "HelloWorldService" for both Message Destination Name and PhysicalName and click Next - -Click Deploy Now - -Thats it, you're done. - - -WebSphere ---------- - -To define the JMS resources in a new WebSphere Application Server 6.1 installation: - -1) First define a Service integration bus: - -Logon to the WebSphere Integrated Solutions Console (http://localhost:9060/ibm/console) - -On the Left hand menu expand Service integration, and click on Buses. - -In the Buses panel click on New - -Enter a name for the bus, eg MyBus, and click Next, and then click Finish and Save the changes. - -In the Buses panel click on MyBus - -Find the Topology secion and click on Bus members - -Click on Add, leave the defaults and click Next, Next, Next, Finish, and Save the changes. - -Restart WebSphere and when back up logon back on to the Integrated Solutions Console - -2) Now define the JMS rescources - -On the Left hand menu expand Resources, and JMS and click on Connection Facotories. - -In the Connection factories panel click New. - -Leave the Default messaging provider and click OK - -Enter "ConnectionFactory" in the Name and JNDI name and in the Bus name in the Connection pane choose MyBus and click OK - -On the Left hand menu in JMS click on Queues - -In the Queues panel click New, accept the defaults and click OK - -Enter "HelloWorldService" for the Name and JNDI name and in the Bus name in the Connection pane choose MyBus, -and then in the Queue name drop down list choose "Create SIB destination" - -In the Set queue attributes panel enter "HelloWorldService" for the Identifier and click Next, Next, and Finish - -That should take you back to the Queues panel where you can click OK to create the new JMS queue. - -Save the changes - -Restart WebSphere and you're done. - - - -Others... ---------- - - - - \ No newline at end of file diff --git a/sandbox/samples/temp/helloworld-jms/pom.xml b/sandbox/samples/temp/helloworld-jms/pom.xml deleted file mode 100644 index 326422ed7b..0000000000 --- a/sandbox/samples/temp/helloworld-jms/pom.xml +++ /dev/null @@ -1,96 +0,0 @@ - - - - 4.0.0 - - org.apache.tuscany.sca - tuscany-samples - 2.0-SNAPSHOT - ../../pom.xml - - - sample-helloworld-jms-webapp - war - Apache Tuscany SCA Sample JMS HelloWorld in a WebApp - - - - - org.apache.tuscany.sca.shades - tuscany-base - 2.0-SNAPSHOT - - - org.apache.tuscany.sca.shades - tuscany-jms - 2.0-SNAPSHOT - - - - org.apache.activemq - activemq-core - 5.3.0 - runtime - - - - - - helloworld-jms - - - org.mortbay.jetty - maven-jetty-plugin - 6.1.18 - - helloworld-jms - foo - 9999 - - - - start-jetty - process-test-classes - - run - - - 0 - true - - - 8085 - - - - - - stop-jetty - prepare-package - - stop - - - - - - - - diff --git a/sandbox/samples/temp/helloworld-jms/src/main/java/sample/HelloWorldClient.java b/sandbox/samples/temp/helloworld-jms/src/main/java/sample/HelloWorldClient.java deleted file mode 100644 index f209f11605..0000000000 --- a/sandbox/samples/temp/helloworld-jms/src/main/java/sample/HelloWorldClient.java +++ /dev/null @@ -1,37 +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 sample; - -/** - * The HelloWorld client implementation - */ -public class HelloWorldClient implements HelloWorldService { - - HelloWorldService helloWorldRef; - - public String sayHello(String name) { - System.out.println("HelloWorldClient.sayHello " + name); - return helloWorldRef.sayHello(name); - } - - public void setHelloWorldRef(HelloWorldService helloWorldRef) { - System.out.println("HelloWorldClient.setHelloWorldService " + helloWorldRef); - this.helloWorldRef = helloWorldRef; - } -} \ No newline at end of file diff --git a/sandbox/samples/temp/helloworld-jms/src/main/java/sample/HelloWorldService.java b/sandbox/samples/temp/helloworld-jms/src/main/java/sample/HelloWorldService.java deleted file mode 100644 index df2a852161..0000000000 --- a/sandbox/samples/temp/helloworld-jms/src/main/java/sample/HelloWorldService.java +++ /dev/null @@ -1,29 +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 sample; - -import org.oasisopen.sca.annotation.Remotable; - -/** - * The interface for the helloworld service - */ -@Remotable -public interface HelloWorldService { - public String sayHello(String name); -} diff --git a/sandbox/samples/temp/helloworld-jms/src/main/java/sample/HelloWorldServiceImpl.java b/sandbox/samples/temp/helloworld-jms/src/main/java/sample/HelloWorldServiceImpl.java deleted file mode 100644 index c09af51e23..0000000000 --- a/sandbox/samples/temp/helloworld-jms/src/main/java/sample/HelloWorldServiceImpl.java +++ /dev/null @@ -1,31 +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 sample; - -/** - * This class implements the HelloWorld service. - */ -public class HelloWorldServiceImpl implements HelloWorldService { - - public String sayHello(String name) { - System.out.println("HelloWorldServiceImpl.sayHello " + name); - return "Hello " + name; - } - -} diff --git a/sandbox/samples/temp/helloworld-jms/src/main/webapp/META-INF/context.xml b/sandbox/samples/temp/helloworld-jms/src/main/webapp/META-INF/context.xml deleted file mode 100644 index 7575edfc29..0000000000 --- a/sandbox/samples/temp/helloworld-jms/src/main/webapp/META-INF/context.xml +++ /dev/null @@ -1,34 +0,0 @@ - - - - - - - - - - - - \ No newline at end of file diff --git a/sandbox/samples/temp/helloworld-jms/src/main/webapp/WEB-INF/jetty-env.xml b/sandbox/samples/temp/helloworld-jms/src/main/webapp/WEB-INF/jetty-env.xml deleted file mode 100644 index a8cd27f6c6..0000000000 --- a/sandbox/samples/temp/helloworld-jms/src/main/webapp/WEB-INF/jetty-env.xml +++ /dev/null @@ -1,48 +0,0 @@ - - - - - - - - - - - ConnectionFactory - - - vm://localhost?broker.persistent=false - - - - - - HelloWorldService - - - DEMO - - - - - diff --git a/sandbox/samples/temp/helloworld-jms/src/main/webapp/WEB-INF/web.composite b/sandbox/samples/temp/helloworld-jms/src/main/webapp/WEB-INF/web.composite deleted file mode 100644 index c51985bc30..0000000000 --- a/sandbox/samples/temp/helloworld-jms/src/main/webapp/WEB-INF/web.composite +++ /dev/null @@ -1,44 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/sandbox/samples/temp/helloworld-jms/src/main/webapp/WEB-INF/web.xml b/sandbox/samples/temp/helloworld-jms/src/main/webapp/WEB-INF/web.xml deleted file mode 100644 index 86710435ae..0000000000 --- a/sandbox/samples/temp/helloworld-jms/src/main/webapp/WEB-INF/web.xml +++ /dev/null @@ -1,66 +0,0 @@ - - - - - - - Apache Tuscany JMS Web Service Sample - - - tuscany - org.apache.tuscany.sca.host.webapp.TuscanyServletFilter - - - - tuscany - /* - - - - hello.jsp - - - - - - - diff --git a/sandbox/samples/temp/helloworld-jms/src/main/webapp/hello.jsp b/sandbox/samples/temp/helloworld-jms/src/main/webapp/hello.jsp deleted file mode 100644 index 9ae037f2c2..0000000000 --- a/sandbox/samples/temp/helloworld-jms/src/main/webapp/hello.jsp +++ /dev/null @@ -1,41 +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. ---%> - -<%@ page contentType="text/html;charset=UTF-8" language="java" %> -<%@ taglib uri="http://www.osoa.org/sca/sca_jsp.tld" prefix="sca" %> - - - - -HelloWorld JMS sample - - - -If this sample is working correctly you should see "Hello World" on the next line... -

-<%= service.sayHello("world") %> -

-If you do not see "Hello World" on the line above then there has been a problem. -

-The sample requires JMS resources be manually configured in the server environment, these are: -a JMS connection factory named "ConnectionFactory", and a destination queues named "HelloWorldService". -See the sample README file for more information. - - - diff --git a/sandbox/samples/temp/helloworld-stripes/pom.xml b/sandbox/samples/temp/helloworld-stripes/pom.xml deleted file mode 100644 index 16259aba62..0000000000 --- a/sandbox/samples/temp/helloworld-stripes/pom.xml +++ /dev/null @@ -1,112 +0,0 @@ - - - - 4.0.0 - - org.apache.tuscany.sca - tuscany-samples - 2.0-SNAPSHOT - ../../pom.xml - - - sample-helloworld-stripes-webapp - war - Apache Tuscany SCA Sample Helloworld using Stripes - - - - - - org.apache.tuscany.sca.shades - tuscany-base - 2.0-SNAPSHOT - - - - - net.sourceforge.stripes - stripes - 1.5.2 - - - - taglibs - standard - 1.1.2 - - - - junit - junit - 4.8.1 - test - - - - net.sourceforge.htmlunit - htmlunit - 2.6 - test - - - - - - helloworld-stripes - - - org.mortbay.jetty - maven-jetty-plugin - 6.1.18 - - helloworld-stripes - foo - 9999 - - - - start-jetty - process-test-classes - - run - - - 0 - true - - - 8085 - - - - - - stop-jetty - prepare-package - - stop - - - - - - - - diff --git a/sandbox/samples/temp/helloworld-stripes/src/main/java/mystripes/action/BaseActionBean.java b/sandbox/samples/temp/helloworld-stripes/src/main/java/mystripes/action/BaseActionBean.java deleted file mode 100644 index 0ab02682ac..0000000000 --- a/sandbox/samples/temp/helloworld-stripes/src/main/java/mystripes/action/BaseActionBean.java +++ /dev/null @@ -1,33 +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 mystripes.action; - -import net.sourceforge.stripes.action.ActionBean; -import net.sourceforge.stripes.action.ActionBeanContext; - -public class BaseActionBean implements ActionBean { - private ActionBeanContext context; - - public ActionBeanContext getContext() { - return context; - } - public void setContext(ActionBeanContext context) { - this.context = context; - } -} diff --git a/sandbox/samples/temp/helloworld-stripes/src/main/java/mystripes/action/HomeActionBean.java b/sandbox/samples/temp/helloworld-stripes/src/main/java/mystripes/action/HomeActionBean.java deleted file mode 100644 index 0385c92369..0000000000 --- a/sandbox/samples/temp/helloworld-stripes/src/main/java/mystripes/action/HomeActionBean.java +++ /dev/null @@ -1,45 +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 mystripes.action; - -import net.sourceforge.stripes.action.DefaultHandler; -import net.sourceforge.stripes.action.ForwardResolution; -import net.sourceforge.stripes.action.Resolution; -import net.sourceforge.stripes.action.UrlBinding; - -import org.oasisopen.sca.annotation.Reference; - -import sample.HelloworldService; - -@UrlBinding("/Home.htm") -public class HomeActionBean extends BaseActionBean { - - @Reference - HelloworldService service; - - @DefaultHandler - public Resolution view() { - return new ForwardResolution("/WEB-INF/jsp/home.jsp"); - } - - public String getHello() { - return service.sayHello("world"); - } - -} diff --git a/sandbox/samples/temp/helloworld-stripes/src/main/java/sample/HelloworldService.java b/sandbox/samples/temp/helloworld-stripes/src/main/java/sample/HelloworldService.java deleted file mode 100644 index 53ff7a5ca1..0000000000 --- a/sandbox/samples/temp/helloworld-stripes/src/main/java/sample/HelloworldService.java +++ /dev/null @@ -1,25 +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 sample; - -public interface HelloworldService { - - String sayHello(String name); - -} diff --git a/sandbox/samples/temp/helloworld-stripes/src/main/java/sample/HelloworldServiceImpl.java b/sandbox/samples/temp/helloworld-stripes/src/main/java/sample/HelloworldServiceImpl.java deleted file mode 100644 index a22c095f29..0000000000 --- a/sandbox/samples/temp/helloworld-stripes/src/main/java/sample/HelloworldServiceImpl.java +++ /dev/null @@ -1,28 +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 sample; - - -public class HelloworldServiceImpl implements HelloworldService { - - public String sayHello(String name) { - return "Hello " + name; - } - -} diff --git a/sandbox/samples/temp/helloworld-stripes/src/main/resources/StripesResources.properties b/sandbox/samples/temp/helloworld-stripes/src/main/resources/StripesResources.properties deleted file mode 100644 index 902842a19e..0000000000 --- a/sandbox/samples/temp/helloworld-stripes/src/main/resources/StripesResources.properties +++ /dev/null @@ -1,73 +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. -# - -# Resource strings used by the tag when there are no nested tags -stripes.errors.header=

Please fix the following errors:
    -stripes.errors.beforeError=
  1. -stripes.errors.afterError=
  2. -stripes.errors.footer=
- -# Resource strings used by the tag when displaying errors for a -# specific field (e.g. ). If not supplied the -# values above will be used instead. -stripes.fieldErrors.header= -stripes.fieldErrors.beforeError= -stripes.fieldErrors.afterError=
-stripes.fieldErrors.footer= - -# Resource strings used by the stripes:messages tag -stripes.messages.header=
    -stripes.messages.beforeMessage=
  • -stripes.messages.afterMessage=
  • -stripes.messages.footer=
- -# Validation error messages produced by Stripes' built-in converter classes. These -# are default error messages and can be overridden on per-field and per-form levels. -# Using the 'invalidNumber' error for a field 'age' of a form posting to -# '/user/Profile.action', the keys looked for (in order) would be: -# 1: /user/Profile.action.age.invalidNumber -# 2: /user/Profile.action.age.errorMessage -# 3: age.errorMessage -# 4: /user/Profile.action.invalidNumber -# 5: converter.number.invalidNumber -converter.number.invalidNumber=The value ({1}) entered in field {0} must be a valid number -converter.byte.outOfRange=The value ({1}) entered in field {0} was out of the range {2} to {3} -converter.short.outOfRange=The value ({1}) entered in field {0} was out of the range {2} to {3} -converter.integer.outOfRange=The value ({1}) entered in field {0} was out of the range {2} to {3} -converter.float.outOfRange=The value ({1}) entered in field {0} was out of the range {2} to {3} -converter.enum.notAnEnumeratedValue=The value "{1}" is not a valid value for field {0} -converter.date.invalidDate=The value ({1}) entered in field {0} must be a valid date -converter.email.invalidEmail=The value ({1}) entered is not a valid email address -converter.creditCard.invalidCreditCard=The value ({1}) entered is not a valid credit card number - -# Validation error messages produced by Stripes' annotation based validations. These -# are default error messages and can be overridden on per-field and per-form levels. -# Using the 'valueNotPresent' required field error for a field 'username' of a form -# posting to '/user/Register.action', the keys looked for (in order) would be: -# 1: /user/Register.action.username.valueNotPresent -# 2: /user/Register.action.username.errorMessage -# 3: username.errorMessage -# 4: /user/Register.action.valueNotPresent -# 5: validation.required.valueNotPresent -validation.required.valueNotPresent={0} is a required field -validation.minlength.valueTooShort={0} must be at least {2} characters long -validation.maxlength.valueTooLong={0} must be no more than {2} characters long -validation.minvalue.valueBelowMinimum=The minimum allowed value for {0} is {2} -validation.maxvalue.valueAboveMaximum=The maximum allowed value for {0} is {2} -validation.mask.valueDoesNotMatch={1} is not a valid {0} -validation.expression.valueFailedExpression=The value supplied ({1}) for field {0} is invalid -validation.file.postBodyTooBig=Total upload size of {3} KB exceeds the maximum size of {2} KB diff --git a/sandbox/samples/temp/helloworld-stripes/src/main/resources/log4j.properties b/sandbox/samples/temp/helloworld-stripes/src/main/resources/log4j.properties deleted file mode 100644 index 2741999098..0000000000 --- a/sandbox/samples/temp/helloworld-stripes/src/main/resources/log4j.properties +++ /dev/null @@ -1,48 +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. -# - -# log4j.properties - -# Set up a logger to the console -log4j.appender.stdout=org.apache.log4j.ConsoleAppender -log4j.appender.stdout.layout=org.apache.log4j.PatternLayout -log4j.appender.stdout.layout.ConversionPattern=[%d{HH:mm:ss}] %-5p %c %x - %m%n - -# Use this to only see log messages beyond a certain threshold in the console -#log4j.appender.stdout.Threshold=WARN - -# Set up a logger to a log file -log4j.appender.logfile=org.apache.log4j.DailyRollingFileAppender -log4j.appender.logfile.layout=org.apache.log4j.PatternLayout -log4j.appender.logfile.layout.ConversionPattern=[%d{HH:mm:ss}] %-5p %c %x - %m%n -log4j.appender.logfile.File=${user.home}/stripesquick.log -log4j.appender.logfile.DatePattern='.'yyyy-MM-dd - -# Use this to only see log messages beyond a certain threshold in the log file -#log4j.appender.logfile.Threshold=WARN - -# Logger settings -log4j.rootLogger=INFO, stdout, logfile - -# Valid levels are TRACE, DEBUG, INFO, WARN, ERROR, FATAL -# Change to TRACE or DEBUG to see more log messages -log4j.logger.net.sourceforge.stripes=WARN -log4j.logger.org.stripesbook.quickstart=INFO -log4j.logger.org.mortbay.log=INFO -log4j.logger.org=WARN -log4j.logger.com=WARN -log4j.logger.net=WARN diff --git a/sandbox/samples/temp/helloworld-stripes/src/main/webapp/WEB-INF/jsp/home.jsp b/sandbox/samples/temp/helloworld-stripes/src/main/webapp/WEB-INF/jsp/home.jsp deleted file mode 100644 index 0681c1f2bf..0000000000 --- a/sandbox/samples/temp/helloworld-stripes/src/main/webapp/WEB-INF/jsp/home.jsp +++ /dev/null @@ -1,26 +0,0 @@ - -<%@ include file="/WEB-INF/jsp/taglibs.jsp" %> - - - -

sayHello returns: ${actionBean.hello}

-

Congratulations, you've set up a Stripes SCA project!

-
-
diff --git a/sandbox/samples/temp/helloworld-stripes/src/main/webapp/WEB-INF/jsp/layout.jsp b/sandbox/samples/temp/helloworld-stripes/src/main/webapp/WEB-INF/jsp/layout.jsp deleted file mode 100644 index d0fb716b80..0000000000 --- a/sandbox/samples/temp/helloworld-stripes/src/main/webapp/WEB-INF/jsp/layout.jsp +++ /dev/null @@ -1,39 +0,0 @@ - -<%@ include file="/WEB-INF/jsp/taglibs.jsp" %> - - - - - - - ${title} - - - - - -
- - -
- - - -
\ No newline at end of file diff --git a/sandbox/samples/temp/helloworld-stripes/src/main/webapp/WEB-INF/jsp/taglibs.jsp b/sandbox/samples/temp/helloworld-stripes/src/main/webapp/WEB-INF/jsp/taglibs.jsp deleted file mode 100644 index f85602fcfa..0000000000 --- a/sandbox/samples/temp/helloworld-stripes/src/main/webapp/WEB-INF/jsp/taglibs.jsp +++ /dev/null @@ -1,29 +0,0 @@ - -<%-- Stripes TLD --%> -<%@ taglib prefix="s" uri="http://stripes.sourceforge.net/stripes.tld" %> -<%@ taglib prefix="sdyn" uri="http://stripes.sourceforge.net/stripes-dynattr.tld" %> - -<%-- JSTL TLDs --%> -<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> -<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %> -<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %> - -<%-- This is so that you can conveniently refer to the context path with ${contextPath} --%> - diff --git a/sandbox/samples/temp/helloworld-stripes/src/main/webapp/WEB-INF/web.composite b/sandbox/samples/temp/helloworld-stripes/src/main/webapp/WEB-INF/web.composite deleted file mode 100644 index 8976adde3c..0000000000 --- a/sandbox/samples/temp/helloworld-stripes/src/main/webapp/WEB-INF/web.composite +++ /dev/null @@ -1,34 +0,0 @@ - - - - - - - - - - - - - - diff --git a/sandbox/samples/temp/helloworld-stripes/src/main/webapp/WEB-INF/web.xml b/sandbox/samples/temp/helloworld-stripes/src/main/webapp/WEB-INF/web.xml deleted file mode 100644 index f01584cc2f..0000000000 --- a/sandbox/samples/temp/helloworld-stripes/src/main/webapp/WEB-INF/web.xml +++ /dev/null @@ -1,61 +0,0 @@ - - - - - Apache Tuscany Helloworld Stripes Sample - - - org.apache.tuscany.sca.host.webapp.TuscanyContextListener - - - - StripesFilter - net.sourceforge.stripes.controller.StripesFilter - - ActionResolver.Packages - mystripes.action - - - Extension.Packages - org.apache.tuscany.sca.stripes - - - - - DispatcherServlet - net.sourceforge.stripes.controller.DispatcherServlet - 1 - - - - StripesFilter - DispatcherServlet - REQUEST - FORWARD - - - - DispatcherServlet - *.htm - - - - index.html - - - diff --git a/sandbox/samples/temp/helloworld-stripes/src/main/webapp/index.html b/sandbox/samples/temp/helloworld-stripes/src/main/webapp/index.html deleted file mode 100644 index c79d29e6a5..0000000000 --- a/sandbox/samples/temp/helloworld-stripes/src/main/webapp/index.html +++ /dev/null @@ -1,24 +0,0 @@ - - - - - - - diff --git a/sandbox/samples/temp/helloworld-stripes/src/test/java/README b/sandbox/samples/temp/helloworld-stripes/src/test/java/README deleted file mode 100644 index 828aadb0f1..0000000000 --- a/sandbox/samples/temp/helloworld-stripes/src/test/java/README +++ /dev/null @@ -1,7 +0,0 @@ -The README in the /samples directory provides -general instructions about building and running samples. (where -distribution-unpack-dir is the directory in which you unpacked the tuscany -binary distribution archive). Take a look there first (noting at you read it that this sample -is not a new style sample). - -TODO - finish \ No newline at end of file diff --git a/sandbox/samples/temp/helloworld-stripes/src/test/java/itest/HelloworldTestCase.java b/sandbox/samples/temp/helloworld-stripes/src/test/java/itest/HelloworldTestCase.java deleted file mode 100644 index 7f4359fa43..0000000000 --- a/sandbox/samples/temp/helloworld-stripes/src/test/java/itest/HelloworldTestCase.java +++ /dev/null @@ -1,53 +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 itest; - -import static org.junit.Assert.assertEquals; - -import java.io.IOException; -import java.net.MalformedURLException; -import java.util.Iterator; - -import org.junit.Test; - -import com.gargoylesoftware.htmlunit.FailingHttpStatusCodeException; -import com.gargoylesoftware.htmlunit.WebClient; -import com.gargoylesoftware.htmlunit.html.HtmlElement; -import com.gargoylesoftware.htmlunit.html.HtmlPage; -import com.gargoylesoftware.htmlunit.html.HtmlParagraph; - -/** - */ -public class HelloworldTestCase { - - @Test - public void testA() throws FailingHttpStatusCodeException, MalformedURLException, IOException { - HtmlPage page = (HtmlPage)new WebClient().getPage("http://localhost:8085/helloworld-stripes"); - Iterator ss = page.getAllHtmlChildElements().iterator(); - while(ss.hasNext()) { - HtmlElement htmlElement = (HtmlElement) ss.next(); - if( htmlElement instanceof HtmlParagraph) { - assertEquals("sayHello returns: Hello world", htmlElement.asText()); - break; - } - } - } - -} -- cgit v1.2.3