You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tuscany.apache.org by an...@apache.org on 2007/07/26 17:03:25 UTC

svn commit: r559842 - in /incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp: ./ src/ src/main/ src/main/java/ src/main/java/helloworld/ src/main/resources/ src/main/resources/wsdl/ src/main/webapp/ src/main/webapp/META-INF/ src/main/webap...

Author: antelder
Date: Thu Jul 26 08:03:13 2007
New Revision: 559842

URL: http://svn.apache.org/viewvc?view=rev&rev=559842
Log:
Add helloworld ws webapp sample

Added:
    incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/   (with props)
    incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/pom.xml   (with props)
    incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/
    incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/
    incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/java/
    incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/java/helloworld/
    incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/java/helloworld/HelloWorldImpl.java   (with props)
    incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/java/helloworld/HelloWorldService.java   (with props)
    incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/resources/
    incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/resources/wsdl/
    incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/resources/wsdl/helloworld.wsdl   (with props)
    incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/webapp/
    incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/webapp/META-INF/
    incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/webapp/META-INF/sca-deployables/
    incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/webapp/META-INF/sca-deployables/helloworldws.composite
    incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/webapp/WEB-INF/
    incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/webapp/WEB-INF/web.xml   (with props)
    incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/test/
    incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/test/java/

Propchange: incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/
------------------------------------------------------------------------------
--- svn:ignore (added)
+++ svn:ignore Thu Jul 26 08:03:13 2007
@@ -0,0 +1,18 @@
+dojo
+work
+target
+*.iws
+*.ipr
+*.iml
+.project
+.classpath
+derby.log
+maven.log
+velocity.log*
+junit*.properties
+surefire*.properties
+.settings
+.deployables
+.wtpmodules
+.felix
+

Added: incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/pom.xml
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/pom.xml?view=auto&rev=559842
==============================================================================
--- incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/pom.xml (added)
+++ incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/pom.xml Thu Jul 26 08:03:13 2007
@@ -0,0 +1,72 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+    * Licensed to the Apache Software Foundation (ASF) under one
+    * or more contributor license agreements.  See the NOTICE file
+    * distributed with this work for additional information
+    * regarding copyright ownership.  The ASF licenses this file
+    * to you under the Apache License, Version 2.0 (the
+    * "License"); you may not use this file except in compliance
+    * with the License.  You may obtain a copy of the License at
+    * 
+    *   http://www.apache.org/licenses/LICENSE-2.0
+    * 
+    * Unless required by applicable law or agreed to in writing,
+    * software distributed under the License is distributed on an
+    * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+    * KIND, either express or implied.  See the License for the
+    * specific language governing permissions and limitations
+    * under the License.    
+-->
+<project>
+    <modelVersion>4.0.0</modelVersion>
+    <parent>
+        <groupId>org.apache.tuscany.sca</groupId>
+        <artifactId>tuscany-sca</artifactId>
+        <version>1.0-incubating-SNAPSHOT</version>
+    </parent>
+    <artifactId>sample-helloworld-ws-service-webapp</artifactId>
+    <name>Apache Tuscany HelloWorld Web Service Sample</name>
+    <packaging>war</packaging>
+
+    <repositories>
+       <repository>
+          <id>apache.incubator</id>
+          <url>http://people.apache.org/repo/m2-incubating-repository</url>
+       </repository>
+    </repositories>
+
+    <dependencies>
+        <dependency>
+            <groupId>org.apache.tuscany.sca</groupId>
+            <artifactId>tuscany-host-webapp</artifactId>
+            <version>1.0-incubating-SNAPSHOT</version>
+        </dependency>
+
+        <dependency>
+            <groupId>org.apache.tuscany.sca</groupId>
+            <artifactId>tuscany-binding-ws-axis2</artifactId>
+            <version>1.0-incubating-SNAPSHOT</version>
+            <scope>runtime</scope>
+            <exclusions>
+                <exclusion>
+                    <!-- exclude servlet api, bug in axis2 binding pom -->
+                    <groupId>javax.servlet</groupId>
+                    <artifactId>servlet-api</artifactId>
+                </exclusion>
+            </exclusions>
+        </dependency>
+
+        <dependency>
+            <groupId>org.apache.tuscany.sca</groupId>
+            <artifactId>tuscany-implementation-java-runtime</artifactId>
+            <version>1.0-incubating-SNAPSHOT</version>
+            <scope>runtime</scope>
+        </dependency>
+
+    </dependencies>
+    
+    <build>
+       <finalName>${artifactId}</finalName>
+    </build>
+
+</project>

Propchange: incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/pom.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/pom.xml
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/pom.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/java/helloworld/HelloWorldImpl.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/java/helloworld/HelloWorldImpl.java?view=auto&rev=559842
==============================================================================
--- incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/java/helloworld/HelloWorldImpl.java (added)
+++ incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/java/helloworld/HelloWorldImpl.java Thu Jul 26 08:03:13 2007
@@ -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 helloworld;
+
+import org.osoa.sca.annotations.Service;
+
+/**
+ * This class implements the HelloWorld service.
+ */
+@Service(HelloWorldService.class)
+public class HelloWorldImpl implements HelloWorldService {
+
+    public String getGreetings(String name) {
+        return "Hello " + name;
+    }
+
+}

Propchange: incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/java/helloworld/HelloWorldImpl.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/java/helloworld/HelloWorldImpl.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Added: incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/java/helloworld/HelloWorldService.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/java/helloworld/HelloWorldService.java?view=auto&rev=559842
==============================================================================
--- incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/java/helloworld/HelloWorldService.java (added)
+++ incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/java/helloworld/HelloWorldService.java Thu Jul 26 08:03:13 2007
@@ -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 helloworld;
+
+import org.osoa.sca.annotations.Remotable;
+import org.osoa.sca.annotations.Service;
+
+/**
+ * This is the business interface of the HelloWorld greetings service.
+ */
+@Remotable
+@Service
+public interface HelloWorldService {
+
+    public String getGreetings(String name);
+}
+

Propchange: incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/java/helloworld/HelloWorldService.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/java/helloworld/HelloWorldService.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Added: incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/resources/wsdl/helloworld.wsdl
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/resources/wsdl/helloworld.wsdl?view=auto&rev=559842
==============================================================================
--- incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/resources/wsdl/helloworld.wsdl (added)
+++ incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/resources/wsdl/helloworld.wsdl Thu Jul 26 08:03:13 2007
@@ -0,0 +1,79 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.    
+-->
+<wsdl:definitions targetNamespace="http://helloworld" xmlns:tns="http://helloworld" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+	name="helloworld">
+
+    <wsdl:types>
+        <schema elementFormDefault="qualified" targetNamespace="http://helloworld" xmlns="http://www.w3.org/2001/XMLSchema">
+
+            <element name="getGreetings">
+                <complexType>
+                    <sequence>
+                        <element name="name" type="xsd:string"/>
+                    </sequence>
+                </complexType>
+            </element>
+
+            <element name="getGreetingsResponse">
+                <complexType>
+                    <sequence>
+                        <element name="getGreetingsReturn" type="xsd:string"/>
+                    </sequence>
+                </complexType>
+            </element>
+            
+        </schema>
+    </wsdl:types>
+
+    <wsdl:message name="getGreetingsRequest">
+        <wsdl:part element="tns:getGreetings" name="parameters"/>
+    </wsdl:message>
+
+    <wsdl:message name="getGreetingsResponse">
+        <wsdl:part element="tns:getGreetingsResponse" name="parameters"/>
+    </wsdl:message>
+
+    <wsdl:portType name="HelloWorld">
+        <wsdl:operation name="getGreetings">
+            <wsdl:input message="tns:getGreetingsRequest" name="getGreetingsRequest"/>
+            <wsdl:output message="tns:getGreetingsResponse" name="getGreetingsResponse"/>
+        </wsdl:operation>
+    </wsdl:portType>
+
+    <wsdl:binding name="HelloWorldSoapBinding" type="tns:HelloWorld">
+        <wsdlsoap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
+        <wsdl:operation name="getGreetings">
+            <wsdlsoap:operation soapAction=""/>
+            <wsdl:input name="getGreetingsRequest">
+                <wsdlsoap:body use="literal"/>
+            </wsdl:input>
+            <wsdl:output name="getGreetingsResponse">
+                <wsdlsoap:body use="literal"/>
+            </wsdl:output>
+        </wsdl:operation>
+    </wsdl:binding>
+
+    <wsdl:service name="HelloWorldService">
+        <wsdl:port binding="tns:HelloWorldSoapBinding" name="HelloWorldSoapPort">
+            <wsdlsoap:address location="http://localhost:8080/services/HelloWorldWebService"/>
+        </wsdl:port>
+    </wsdl:service>
+
+</wsdl:definitions>

Propchange: incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/resources/wsdl/helloworld.wsdl
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/resources/wsdl/helloworld.wsdl
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/resources/wsdl/helloworld.wsdl
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/webapp/META-INF/sca-deployables/helloworldws.composite
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/webapp/META-INF/sca-deployables/helloworldws.composite?view=auto&rev=559842
==============================================================================
--- incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/webapp/META-INF/sca-deployables/helloworldws.composite (added)
+++ incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/webapp/META-INF/sca-deployables/helloworldws.composite Thu Jul 26 08:03:13 2007
@@ -0,0 +1,32 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+    * Licensed to the Apache Software Foundation (ASF) under one
+    * or more contributor license agreements.  See the NOTICE file
+    * distributed with this work for additional information
+    * regarding copyright ownership.  The ASF licenses this file
+    * to you under the Apache License, Version 2.0 (the
+    * "License"); you may not use this file except in compliance
+    * with the License.  You may obtain a copy of the License at
+    * 
+    *   http://www.apache.org/licenses/LICENSE-2.0
+    * 
+    * Unless required by applicable law or agreed to in writing,
+    * software distributed under the License is distributed on an
+    * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+    * KIND, either express or implied.  See the License for the
+    * specific language governing permissions and limitations
+    * under the License.    
+-->
+<composite xmlns="http://www.osoa.org/xmlns/sca/1.0"
+    name="helloworldws">
+
+    <service name="HelloWorldService" promote="HelloWorldComponent">
+        <interface.wsdl interface="http://helloworld#wsdl.interface(HelloWorld)" />
+        <binding.ws />
+    </service>
+
+    <component name="HelloWorldComponent">
+       <implementation.java class="helloworld.HelloWorldImpl" />
+    </component>
+
+</composite>

Added: incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/webapp/WEB-INF/web.xml
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/webapp/WEB-INF/web.xml?view=auto&rev=559842
==============================================================================
--- incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/webapp/WEB-INF/web.xml (added)
+++ incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/webapp/WEB-INF/web.xml Thu Jul 26 08:03:13 2007
@@ -0,0 +1,45 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<!--
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.    
+-->
+
+<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web
+Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
+<web-app>
+
+    <display-name>Tuscany sample HelloWorld JSON-RPC</display-name>
+    
+    <listener>
+        <listener-class>org.apache.tuscany.sca.webapp.TuscanyContextListener</listener-class>
+    </listener>
+
+    <servlet>
+        <servlet-name>TuscanyServlet</servlet-name>
+        <servlet-class>org.apache.tuscany.sca.webapp.TuscanyServlet</servlet-class>
+    </servlet>
+ 
+    <servlet-mapping>
+        <servlet-name>TuscanyServlet</servlet-name>
+        <url-pattern>/SCA/*</url-pattern>
+    </servlet-mapping>
+
+    <welcome-file-list id="WelcomeFileList">
+        <welcome-file>/SCA/HelloWorldComponent/HelloWorldService?wsdl</welcome-file>
+    </welcome-file-list>  
+
+</web-app>

Propchange: incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/webapp/WEB-INF/web.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/webapp/WEB-INF/web.xml
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/tuscany/java/sca/samples/helloworld-ws-service-webapp/src/main/webapp/WEB-INF/web.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml



---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-commits-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-commits-help@ws.apache.org