tuscany-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jmar...@apache.org
Subject svn commit: r439731 - in /incubator/tuscany/java/samples/sca/spring: ./ client/ client/src/ client/src/main/ client/src/main/java/ client/src/main/java/sample/ client/src/main/resources/ client/src/main/webapp/ client/src/main/webapp/META-INF/ client/s...
Date Sun, 03 Sep 2006 06:03:59 GMT
Author: jmarino
Date: Sat Sep  2 23:03:58 2006
New Revision: 439731

URL: http://svn.apache.org/viewvc?rev=439731&view=rev
Log:
add start of spring sample suite

Added:
    incubator/tuscany/java/samples/sca/spring/   (with props)
    incubator/tuscany/java/samples/sca/spring/client/
    incubator/tuscany/java/samples/sca/spring/client/pom.xml   (with props)
    incubator/tuscany/java/samples/sca/spring/client/src/
    incubator/tuscany/java/samples/sca/spring/client/src/main/
    incubator/tuscany/java/samples/sca/spring/client/src/main/java/
    incubator/tuscany/java/samples/sca/spring/client/src/main/java/sample/
    incubator/tuscany/java/samples/sca/spring/client/src/main/java/sample/TestBean.java  
(with props)
    incubator/tuscany/java/samples/sca/spring/client/src/main/java/sample/TestBeanImpl.java
  (with props)
    incubator/tuscany/java/samples/sca/spring/client/src/main/resources/
    incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/
    incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/META-INF/
    incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/META-INF/sca/
    incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/META-INF/sca/default.scdl
    incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/META-INF/tuscany.extensions/
    incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/META-INF/tuscany.extensions/spring.system.scdl
    incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/WEB-INF/
    incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/WEB-INF/classes/
    incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/WEB-INF/classes/application-context.xml
  (with props)
    incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/WEB-INF/web.xml   (with
props)
    incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/test.jsp
    incubator/tuscany/java/samples/sca/spring/client/src/test/
    incubator/tuscany/java/samples/sca/spring/client/src/test/java/
    incubator/tuscany/java/samples/sca/spring/pom.xml   (with props)

Propchange: incubator/tuscany/java/samples/sca/spring/
------------------------------------------------------------------------------
--- svn:ignore (added)
+++ svn:ignore Sat Sep  2 23:03:58 2006
@@ -0,0 +1,14 @@
+target
+*.iws
+*.ipr
+*.iml
+.project
+.classpath
+maven.log
+velocity.log*
+junit*.properties
+surefire*.properties
+.settings
+.deployables
+.wtpmodules
+

Added: incubator/tuscany/java/samples/sca/spring/client/pom.xml
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/samples/sca/spring/client/pom.xml?rev=439731&view=auto
==============================================================================
--- incubator/tuscany/java/samples/sca/spring/client/pom.xml (added)
+++ incubator/tuscany/java/samples/sca/spring/client/pom.xml Sat Sep  2 23:03:58 2006
@@ -0,0 +1,82 @@
+<?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>
+    <parent>
+        <groupId>org.apache.tuscany.samples.sca.spring</groupId>
+        <artifactId>tuscany-samples-sca-spring</artifactId>
+        <version>1.0-SNAPSHOT</version>
+    </parent>
+    <modelVersion>4.0.0</modelVersion>
+    <artifactId>spring-client</artifactId>
+    <packaging>war</packaging>
+    <name>Tuscany Spring Sample Client Web Application</name>
+    <description>Demonstrates using Spring with Tuscany as a client.</description>
+
+    <dependencies>
+        <dependency>
+            <groupId>org.osoa</groupId>
+            <artifactId>sca-api-r0.95</artifactId>
+            <version>1.0-SNAPSHOT</version>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.tuscany</groupId>
+            <artifactId>core</artifactId>
+            <version>${pom.version}</version>
+            <scope>runtime</scope> <!-- runtime is need for webapp integration
to include jar -->
+        </dependency>
+        <dependency>
+            <groupId>javax.servlet</groupId>
+            <artifactId>servlet-api</artifactId>
+            <scope>provided</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.tuscany.runtime</groupId>
+            <artifactId>webapp</artifactId>
+            <version>${pom.version}</version>
+            <scope>runtime</scope> <!-- runtime is need for webapp integration
to include jar -->
+        </dependency>
+        <dependency>
+            <groupId>org.apache.tuscany.runtime</groupId>
+            <artifactId>webapp-host</artifactId>
+            <version>${pom.version}</version>
+            <scope>runtime</scope> <!-- runtime is need for webapp integration
to include jar -->
+        </dependency>
+        <dependency>
+            <groupId>org.apache.tuscany.containers</groupId>
+            <artifactId>spring</artifactId>
+            <version>${pom.version}</version>
+            <scope>runtime</scope>
+        </dependency>
+		  <dependency>
+            <groupId>org.springframework</groupId>
+            <artifactId>spring</artifactId>
+            <version>2.0-rc3</version>
+            <scope>compile</scope>
+        </dependency>
+			<dependency>
+            <groupId>junit</groupId>
+            <artifactId>junit</artifactId>
+            <version>3.8.1</version>
+            <scope>test</scope>
+        </dependency>
+        
+    </dependencies>
+</project>

Propchange: incubator/tuscany/java/samples/sca/spring/client/pom.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/tuscany/java/samples/sca/spring/client/pom.xml
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Added: incubator/tuscany/java/samples/sca/spring/client/src/main/java/sample/TestBean.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/samples/sca/spring/client/src/main/java/sample/TestBean.java?rev=439731&view=auto
==============================================================================
--- incubator/tuscany/java/samples/sca/spring/client/src/main/java/sample/TestBean.java (added)
+++ incubator/tuscany/java/samples/sca/spring/client/src/main/java/sample/TestBean.java Sat
Sep  2 23:03:58 2006
@@ -0,0 +1,7 @@
+package sample;
+
+/**
+ * @version $Rev$ $Date$
+ */
+public class TestBean {
+}

Propchange: incubator/tuscany/java/samples/sca/spring/client/src/main/java/sample/TestBean.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/tuscany/java/samples/sca/spring/client/src/main/java/sample/TestBean.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Added: incubator/tuscany/java/samples/sca/spring/client/src/main/java/sample/TestBeanImpl.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/samples/sca/spring/client/src/main/java/sample/TestBeanImpl.java?rev=439731&view=auto
==============================================================================
--- incubator/tuscany/java/samples/sca/spring/client/src/main/java/sample/TestBeanImpl.java
(added)
+++ incubator/tuscany/java/samples/sca/spring/client/src/main/java/sample/TestBeanImpl.java
Sat Sep  2 23:03:58 2006
@@ -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;
+
+/**
+ * @version $Rev$ $Date$
+ */
+
+public class TestBeanImpl extends TestBean {
+
+    public TestBeanImpl() {
+    }
+}

Propchange: incubator/tuscany/java/samples/sca/spring/client/src/main/java/sample/TestBeanImpl.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/tuscany/java/samples/sca/spring/client/src/main/java/sample/TestBeanImpl.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Added: incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/META-INF/sca/default.scdl
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/META-INF/sca/default.scdl?rev=439731&view=auto
==============================================================================
--- incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/META-INF/sca/default.scdl
(added)
+++ incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/META-INF/sca/default.scdl
Sat Sep  2 23:03:58 2006
@@ -0,0 +1,37 @@
+<?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="SpringSample">
+    <component name="SpringSample">
+        <implementation.spring location="application-context.xml">
+           <!-- <service name="fooService">
+                <binding.test/>
+                <interface.java class="org.apache.tuscany.container.spring.mock.TestBean"/>
+                <reference>testBean</reference>
+            </service>
+            <reference name="testReference">
+                <interface.java class="org.apache.tuscany.container.spring.mock.TestBean"/>
+                <binding.test/>
+            </reference>          -->
+        </implementation.spring>
+
+    </component>
+
+
+</composite>

Added: incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/META-INF/tuscany.extensions/spring.system.scdl
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/META-INF/tuscany.extensions/spring.system.scdl?rev=439731&view=auto
==============================================================================
--- incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/META-INF/tuscany.extensions/spring.system.scdl
(added)
+++ incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/META-INF/tuscany.extensions/spring.system.scdl
Sat Sep  2 23:03:58 2006
@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ *  Copyright (c) 2006 The Apache Software Foundation or its licensors, as applicable.
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ -->
+<!--
+    Spring implementation extension configuration for the launcher environment.
+-->
+<composite xmlns="http://www.osoa.org/xmlns/sca/1.0"
+           xmlns:system="http://tuscany.apache.org/xmlns/system/1.0-SNAPSHOT"
+
+           name="org.apache.tuscany.launcher.SpringImplementation">
+
+    <component name="spring.implementationLoader">
+        <system:implementation.system class="org.apache.tuscany.container.spring.impl.SpringImplementationLoader"/>
+    </component>
+
+    <component name="spring.componentTypeLoader">
+        <system:implementation.system class="org.apache.tuscany.container.spring.impl.SpringComponentTypeLoader"/>
+    </component>
+
+    <component name="spring.componentBuilder">
+        <system:implementation.system class="org.apache.tuscany.container.spring.impl.SpringCompositeBuilder"/>
+    </component>
+
+</composite>
\ No newline at end of file

Added: incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/WEB-INF/classes/application-context.xml
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/WEB-INF/classes/application-context.xml?rev=439731&view=auto
==============================================================================
--- incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/WEB-INF/classes/application-context.xml
(added)
+++ incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/WEB-INF/classes/application-context.xml
Sat Sep  2 23:03:58 2006
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<beans xmlns="http://www.springframework.org/schema/beans"
+       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+       xmlns:sca="http://www.springframework.org/schema/sca"
+       xsi:schemaLocation="
+http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
+http://www.springframework.org/schema/sca http://www.springframework.org/schema/sca/SpringSCA.xsd">
+
+    <bean id="testBean" class="sample.TestBeanImpl" lazy-init="true">
+        <!--<property name="bean" ref="testReference"/>-->
+    </bean>
+
+</beans>

Propchange: incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/WEB-INF/classes/application-context.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/WEB-INF/classes/application-context.xml
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Added: incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/WEB-INF/web.xml
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/WEB-INF/web.xml?rev=439731&view=auto
==============================================================================
--- incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/WEB-INF/web.xml (added)
+++ incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/WEB-INF/web.xml Sat Sep
 2 23:03:58 2006
@@ -0,0 +1,71 @@
+<?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 Spring Sample</display-name>
+
+    <context-param>
+        <param-name>systemScdlPath</param-name>
+        <param-value>/META-INF/sca/webapp.system.scdl</param-value>
+    </context-param>
+
+    <context-param>
+        <param-name>applicationScdlPath</param-name>
+        <param-value>/META-INF/sca/default.scdl</param-value>
+    </context-param>
+
+    <context-param>
+        <param-name>currentCompositePath</param-name>
+        <param-value>SpringSample</param-value>
+    </context-param>
+
+    <filter>
+        <filter-name>TuscanyFilter</filter-name>
+        <filter-class>org.apache.tuscany.runtime.webapp.TuscanyFilter</filter-class>
+    </filter>
+
+    <filter-mapping>
+        <filter-name>TuscanyFilter</filter-name>
+        <url-pattern>*</url-pattern>
+    </filter-mapping>
+
+    <listener>
+        <listener-class>org.apache.tuscany.runtime.webapp.TuscanyContextListener</listener-class>
+    </listener>
+
+    <listener>
+        <listener-class>org.apache.tuscany.runtime.webapp.TuscanySessionListener</listener-class>
+    </listener>
+
+    <servlet>
+        <servlet-name>TuscanyServlet</servlet-name>
+        <display-name>Tuscany Servlet</display-name>
+        <servlet-class>org.apache.tuscany.runtime.webapp.TuscanyServlet</servlet-class>
+    </servlet>
+
+    <servlet-mapping>
+        <servlet-name>TuscanyServlet</servlet-name>
+        <url-pattern>/services/*</url-pattern>
+    </servlet-mapping>
+
+
+</web-app>

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

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

Added: incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/test.jsp
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/test.jsp?rev=439731&view=auto
==============================================================================
--- incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/test.jsp (added)
+++ incubator/tuscany/java/samples/sca/spring/client/src/main/webapp/test.jsp Sat Sep  2 23:03:58
2006
@@ -0,0 +1,18 @@
+<%@ page import="org.osoa.sca.CompositeContext" %>
+<%@ page import="org.osoa.sca.CurrentCompositeContext" %>
+<%@ page import="sample.TestBean"%>
+<%--
+
+Demonstrates accessing the current application context
+--%>
+<%@ page contentType="text/html;charset=UTF-8" language="java" %>
+<html>
+<head><title>Tuscany Spring sample</title></head>
+
+<body>A Sample Spring application</body>
+<%
+    CompositeContext context = CurrentCompositeContext.getContext();
+    // locates a bean in the Spring context
+    System.out.println("bean:" + context.locateService(TestBean.class, "testBean"));
+%>
+</html>
\ No newline at end of file

Added: incubator/tuscany/java/samples/sca/spring/pom.xml
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/samples/sca/spring/pom.xml?rev=439731&view=auto
==============================================================================
--- incubator/tuscany/java/samples/sca/spring/pom.xml (added)
+++ incubator/tuscany/java/samples/sca/spring/pom.xml Sat Sep  2 23:03:58 2006
@@ -0,0 +1,38 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.    
+-->
+<project>
+
+    <parent>
+        <groupId>org.apache.tuscany.samples.sca</groupId>
+        <artifactId>tuscany-samples-sca</artifactId>
+        <version>1.0-SNAPSHOT</version>
+    </parent>
+
+    <modelVersion>4.0.0</modelVersion>
+    <groupId>org.apache.tuscany.samples.sca.spring</groupId>
+    <artifactId>tuscany-samples-sca-spring</artifactId>
+    <packaging>pom</packaging>
+    <name>Tuscany Spring Samples</name>
+
+    <modules>
+        <module>client</module>
+    </modules>
+
+</project>

Propchange: incubator/tuscany/java/samples/sca/spring/pom.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/tuscany/java/samples/sca/spring/pom.xml
------------------------------------------------------------------------------
    svn:keywords = Rev Date



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


Mime
View raw message