servicemix-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ff...@apache.org
Subject svn commit: r726696 - in /servicemix/smx4/features/trunk/examples: ./ cxf-jms-osgi/ cxf-jms-osgi/src/ cxf-jms-osgi/src/main/ cxf-jms-osgi/src/main/java/ cxf-jms-osgi/src/main/java/org/ cxf-jms-osgi/src/main/java/org/apache/ cxf-jms-osgi/src/main/java/o...
Date Mon, 15 Dec 2008 13:57:01 GMT
Author: ffang
Date: Mon Dec 15 05:57:00 2008
New Revision: 726696

URL: http://svn.apache.org/viewvc?rev=726696&view=rev
Log:
[SMX4-172]Develop test case to demonstrate and verify native deployment of CXF service using
jms transport

Added:
    servicemix/smx4/features/trunk/examples/cxf-jms-osgi/
    servicemix/smx4/features/trunk/examples/cxf-jms-osgi/pom.xml   (with props)
    servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/
    servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/
    servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/java/
    servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/java/org/
    servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/java/org/apache/
    servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/java/org/apache/servicemix/
    servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/java/org/apache/servicemix/examples/
    servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/java/org/apache/servicemix/examples/cxf/
    servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/java/org/apache/servicemix/examples/cxf/HelloWorldImpl.java
  (with props)
    servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/
    servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/META-INF/
    servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/META-INF/spring/
    servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/META-INF/spring/activemq-broker.xml
  (with props)
    servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/META-INF/spring/beans.xml
  (with props)
    servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/wsdl/
    servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/wsdl/hello_world.wsdl
  (with props)
Modified:
    servicemix/smx4/features/trunk/examples/itests/pom.xml
    servicemix/smx4/features/trunk/examples/itests/src/test/java/org/apache/servicemix/examples/IntegrationTest.java
    servicemix/smx4/features/trunk/examples/pom.xml

Added: servicemix/smx4/features/trunk/examples/cxf-jms-osgi/pom.xml
URL: http://svn.apache.org/viewvc/servicemix/smx4/features/trunk/examples/cxf-jms-osgi/pom.xml?rev=726696&view=auto
==============================================================================
--- servicemix/smx4/features/trunk/examples/cxf-jms-osgi/pom.xml (added)
+++ servicemix/smx4/features/trunk/examples/cxf-jms-osgi/pom.xml Mon Dec 15 05:57:00 2008
@@ -0,0 +1,118 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+
+    <!--
+
+        Licensed to the Apache Software Foundation (ASF) under one or more
+        contributor license agreements.  See the NOTICE file distributed with
+        this work for additional information regarding copyright ownership.
+        The ASF licenses this file to You under the Apache License, Version 2.0
+        (the "License"); you may not use this file except in compliance with
+        the License.  You may obtain a copy of the License at
+
+           http://www.apache.org/licenses/LICENSE-2.0
+
+        Unless required by applicable law or agreed to in writing, software
+        distributed under the License is distributed on an "AS IS" BASIS,
+        WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+        See the License for the specific language governing permissions and
+        limitations under the License.
+    -->
+
+    <modelVersion>4.0.0</modelVersion>
+
+    <parent>
+        <groupId>org.apache.servicemix.examples</groupId>
+        <artifactId>examples</artifactId>
+        <version>4.0-m2-SNAPSHOT</version>
+    </parent>
+
+    <groupId>org.apache.servicemix.examples</groupId>
+    <artifactId>cxf-jms-osgi</artifactId>
+    <packaging>bundle</packaging>
+    <version>${servicemix.version}</version>
+    <name>Apache ServiceMix Example :: CXF JMS transport OSGi</name>
+
+    <dependencies>
+        <dependency>
+            <groupId>org.apache.cxf</groupId>
+            <artifactId>cxf-rt-frontend-jaxws</artifactId>
+            <version>${cxf.version}</version>
+            <scope>provided</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>org.apache.geronimo.specs</groupId>
+            <artifactId>geronimo-ws-metadata_2.0_spec</artifactId>
+            <version>${geronimo.wsmetadata.version}</version>
+        </dependency>
+    </dependencies>
+
+    <build>
+        <plugins>
+            <plugin>
+                <groupId>org.apache.cxf</groupId>
+                <artifactId>cxf-codegen-plugin</artifactId>
+                <version>${cxf.version}</version>
+                <executions>
+                    <execution>
+                        <id>generate-test-sources</id>
+                        <phase>generate-sources</phase>
+                        <configuration>
+                            <sourceRoot>${basedir}/target/generated/src/main/java</sourceRoot>
+                            <wsdlOptions>
+                                <wsdlOption>
+                                    <wsdl>${basedir}/src/main/resources/wsdl/hello_world.wsdl</wsdl>
+                                </wsdlOption>
+                            </wsdlOptions>
+                        </configuration>
+                        <goals>
+                            <goal>wsdl2java</goal>
+                        </goals>
+                    </execution>
+                </executions>
+            </plugin>
+            <plugin>
+                <groupId>org.apache.felix</groupId>
+                <artifactId>maven-bundle-plugin</artifactId>
+                <configuration>
+                    <instructions>
+                        <Bundle-SymbolicName>${pom.artifactId}</Bundle-SymbolicName>
+                        <Import-Package>
+                            javax.jws,
+                            javax.wsdl,
+                            javax.xml.bind,
+                            javax.xml.bind.annotation,
+                            javax.xml.namespace,
+                            javax.xml.ws,
+                            META-INF.cxf,
+                            org.apache.cxf.bus,
+                            org.apache.cxf.bus.spring,
+                            org.apache.cxf.bus.resource,
+                            org.apache.cxf.configuration.spring,
+                            org.apache.cxf.resource,
+                            org.springframework.beans.factory.config,
+                            org.apache.activemq.jndi,
+                            org.apache.activemq.xbean,
+                            org.apache.activemq.broker.region.policy,
+                            javax.transaction,
+                            org.apache.activemq,
+                            org.apache.activemq.pool,
+                            org.apache.activemq.util,
+                            org.apache.activemq.broker.jmx,
+                            org.apache.activemq.network,
+                            org.apache.activemq.store.amq,
+                            org.apache.activemq.usage,
+                            org.apache.activemq.broker,
+                            javax.jms
+                        </Import-Package>
+                        <Export-Package>org.apache.servicemix.examples.cxf</Export-Package>
+                        <Require-Bundle>org.apache.cxf.cxf-bundle</Require-Bundle>
+                    </instructions>
+                </configuration>
+            </plugin>
+        </plugins>
+    </build>
+
+</project>

Propchange: servicemix/smx4/features/trunk/examples/cxf-jms-osgi/pom.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: servicemix/smx4/features/trunk/examples/cxf-jms-osgi/pom.xml
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: servicemix/smx4/features/trunk/examples/cxf-jms-osgi/pom.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/java/org/apache/servicemix/examples/cxf/HelloWorldImpl.java
URL: http://svn.apache.org/viewvc/servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/java/org/apache/servicemix/examples/cxf/HelloWorldImpl.java?rev=726696&view=auto
==============================================================================
--- servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/java/org/apache/servicemix/examples/cxf/HelloWorldImpl.java
(added)
+++ servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/java/org/apache/servicemix/examples/cxf/HelloWorldImpl.java
Mon Dec 15 05:57:00 2008
@@ -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.
+ */
+// START SNIPPET: service
+package org.apache.servicemix.examples.cxf;
+
+import javax.jws.WebService;
+
+//@WebService(endpointInterface = "org.apache.servicemix.examples.cxf.HelloWorld")
+@WebService(serviceName = "HelloWorldImplService",
+            portName = "HelloWorldImplPort",
+            endpointInterface = "org.apache.servicemix.examples.cxf.HelloWorld",
+            targetNamespace = "http://cxf.examples.servicemix.apache.org/")
+public class HelloWorldImpl implements HelloWorld {
+
+    public String sayHi(String text) {
+        return "Hello " + text;
+    }
+}
+// END SNIPPET: service

Propchange: servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/java/org/apache/servicemix/examples/cxf/HelloWorldImpl.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/java/org/apache/servicemix/examples/cxf/HelloWorldImpl.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Added: servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/META-INF/spring/activemq-broker.xml
URL: http://svn.apache.org/viewvc/servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/META-INF/spring/activemq-broker.xml?rev=726696&view=auto
==============================================================================
--- servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/META-INF/spring/activemq-broker.xml
(added)
+++ servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/META-INF/spring/activemq-broker.xml
Mon Dec 15 05:57:00 2008
@@ -0,0 +1,134 @@
+<!--
+    Licensed to the Apache Software Foundation (ASF) under one or more
+    contributor license agreements.  See the NOTICE file distributed with
+    this work for additional information regarding copyright ownership.
+    The ASF licenses this file to You under the Apache License, Version 2.0
+    (the "License"); you may not use this file except in compliance with
+    the License.  You may obtain a copy of the License at
+   
+    http://www.apache.org/licenses/LICENSE-2.0
+   
+    Unless required by applicable law or agreed to in writing, software
+    distributed under the License is distributed on an "AS IS" BASIS,
+    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+    See the License for the specific language governing permissions and
+    limitations under the License.
+-->
+<beans
+  xmlns="http://www.springframework.org/schema/beans"
+  xmlns:amq="http://activemq.apache.org/schema/core"
+  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xmlns:osgi="http://www.springframework.org/schema/osgi"
+  xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
+  http://activemq.apache.org/schema/core http://activemq.apache.org/schema/core/activemq-core.xsd
  
+  http://activemq.apache.org/camel/schema/spring http://activemq.apache.org/camel/schema/spring/camel-spring.xsd
+  http://www.springframework.org/schema/osgi http://www.springframework.org/schema/osgi/spring-osgi.xsd">
+
+    <!-- Allows us to use system properties as variables in this configuration file -->
+    <bean class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer"/>
+
+    <broker xmlns="http://activemq.apache.org/schema/core" brokerName="default" dataDirectory="${servicemix.base}/data/activemq/default">
+
+        <!-- Destination specific policies using destination names or wildcards -->
+        <destinationPolicy>
+            <policyMap>
+                <policyEntries>
+                    <policyEntry queue=">" memoryLimit="5mb"/>
+                    <policyEntry topic=">" memoryLimit="5mb">
+                        <subscriptionRecoveryPolicy>
+                            <lastImageSubscriptionRecoveryPolicy/>
+                        </subscriptionRecoveryPolicy>
+                    </policyEntry>
+                </policyEntries>
+            </policyMap>
+        </destinationPolicy>
+
+        <!-- Use the following to configure how ActiveMQ is exposed in JMX -->
+        <managementContext>
+            <managementContext createConnector="false"/>
+        </managementContext>
+
+        <!-- The store and forward broker networks ActiveMQ will listen to -->
+        <networkConnectors>
+            <!-- by default just auto discover the other brokers -->
+            <networkConnector name="default-nc" uri="multicast://default"/>
+            <!-- Example of a static configuration:
+            <networkConnector name="host1 and host2" uri="static://(tcp://host1:61616,tcp://host2:61616)"/>
+            -->
+        </networkConnectors>
+
+        <persistenceAdapter>
+            <amqPersistenceAdapter syncOnWrite="false" directory="${servicemix.base}/data/activemq/default"
maxFileLength="20 mb"/>
+        </persistenceAdapter>
+
+        <!-- Use the following if you wish to configure the journal with JDBC -->
+        <!--
+        <persistenceAdapter>
+            <journaledJDBC dataDirectory="${activemq.base}/data" dataSource="#postgres-ds"/>
+        </persistenceAdapter>
+        -->
+
+        <!-- Or if you want to use pure JDBC without a journal -->
+        <!--
+        <persistenceAdapter>
+            <jdbcPersistenceAdapter dataSource="#postgres-ds"/>
+        </persistenceAdapter>
+        -->
+
+        <!--  The maximum about of space the broker will use before slowing down producers
-->
+        <systemUsage>
+            <systemUsage>
+                <memoryUsage>
+                    <memoryUsage limit="20 mb"/>
+                </memoryUsage>
+                <storeUsage>
+                    <storeUsage limit="1 gb" name="foo"/>
+                </storeUsage>
+                <tempUsage>
+                    <tempUsage limit="100 mb"/>
+                </tempUsage>
+            </systemUsage>
+        </systemUsage>
+
+
+        <!-- The transport connectors ActiveMQ will listen to -->
+        <transportConnectors>
+            <transportConnector name="openwire" uri="tcp://localhost:61616" discoveryUri="multicast://default"/>
+            <transportConnector name="stomp" uri="stomp://localhost:61613"/>
+        </transportConnectors>
+
+    </broker>
+
+    <bean id="activemqConnectionFactory" class="org.apache.activemq.ActiveMQConnectionFactory">
+        <property name="brokerURL" value="tcp://localhost:61616" />
+    </bean>
+
+    <bean id="pooledConnectionFactory" class="org.apache.activemq.pool.PooledConnectionFactoryBean">
+        <property name="maxConnections" value="8" />
+        <property name="maximumActive" value="500" />
+        <property name="transactionManager" ref="transactionManager" />
+        <property name="connectionFactory" ref="activemqConnectionFactory" />
+        <property name="resourceName" value="activemq.default" />
+    </bean>
+
+    <bean id="resourceManager" class="org.apache.activemq.pool.ActiveMQResourceManager"
init-method="recoverResource">
+          <property name="transactionManager" ref="transactionManager" />
+          <property name="connectionFactory" ref="activemqConnectionFactory" />
+          <property name="resourceName" value="activemq.default" />
+    </bean>
+
+    <osgi:reference id="transactionManager" interface="javax.transaction.TransactionManager"
+                    cardinality="0..1"/>
+
+    <osgi:service ref="pooledConnectionFactory">
+        <osgi:interfaces>
+            <value>javax.jms.ConnectionFactory</value>
+        </osgi:interfaces>
+        <osgi:service-properties>
+            <entry key="name" value="default"/>
+        </osgi:service-properties>
+    </osgi:service>
+
+</beans>
+
+

Propchange: servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/META-INF/spring/activemq-broker.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/META-INF/spring/activemq-broker.xml
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/META-INF/spring/activemq-broker.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/META-INF/spring/beans.xml
URL: http://svn.apache.org/viewvc/servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/META-INF/spring/beans.xml?rev=726696&view=auto
==============================================================================
--- servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/META-INF/spring/beans.xml
(added)
+++ servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/META-INF/spring/beans.xml
Mon Dec 15 05:57:00 2008
@@ -0,0 +1,57 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+	Licensed to the Apache Software Foundation (ASF) under one
+	or more contributor license agreements. See the NOTICE file
+	distributed with this work for additional information
+	regarding copyright ownership. The ASF licenses this file
+	to you under the Apache License, Version 2.0 (the
+	"License"); you may not use this file except in compliance
+	with the License. You may obtain a copy of the License at
+
+	http://www.apache.org/licenses/LICENSE-2.0
+
+	Unless required by applicable law or agreed to in writing,
+	software distributed under the License is distributed on an
+	"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+	KIND, either express or implied. See the License for the
+	specific language governing permissions and limitations
+	under the License.
+-->
+<!-- START SNIPPET: beans -->
+<beans xmlns="http://www.springframework.org/schema/beans"
+	xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+	xmlns:jaxws="http://cxf.apache.org/jaxws"
+	xmlns:osgi="http://www.springframework.org/schema/osgi"
+	xsi:schemaLocation="
+		http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
+		http://cxf.apache.org/jaxws http://cxf.apache.org/schemas/jaxws.xsd
+		http://www.springframework.org/schema/osgi http://www.springframework.org/schema/osgi/spring-osgi.xsd">
+
+    <import resource="classpath:META-INF/cxf/cxf.xml" />
+    <import resource="classpath:META-INF/cxf/cxf-extension-soap.xml" />
+    <import resource="classpath:META-INF/cxf/cxf-extension-jms.xml" />
+
+	<jaxws:endpoint id="JMSEndpoint"
+	    implementor="org.apache.servicemix.examples.cxf.HelloWorldImpl"
+	    wsdlLocation="wsdl/hello_world.wsdl"
+	    endpointName="e:HelloWorldImplPort"
+	    serviceName="s:HelloWorldImplService"
+	    xmlns:e="http://cxf.examples.servicemix.apache.org/"
+        xmlns:s="http://cxf.examples.servicemix.apache.org/"/>
+
+
+    <jaxws:client id="client" 
+     	serviceClass="org.apache.servicemix.examples.cxf.HelloWorld"    
+	    endpointName="e:HelloWorldImplPort"
+	    serviceName="s:HelloWorldImplService"
+	    xmlns:e="http://cxf.examples.servicemix.apache.org/"
+        xmlns:s="http://cxf.examples.servicemix.apache.org/"
+     	wsdlLocation="wsdl/hello_world.wsdl"
+     	/>   
+ 
+    <osgi:service id="testHelloWorld" ref="client"
+        interface="org.apache.servicemix.examples.cxf.HelloWorld"/>
+
+
+</beans>
+<!-- END SNIPPET: beans -->

Propchange: servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/META-INF/spring/beans.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/META-INF/spring/beans.xml
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/META-INF/spring/beans.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/wsdl/hello_world.wsdl
URL: http://svn.apache.org/viewvc/servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/wsdl/hello_world.wsdl?rev=726696&view=auto
==============================================================================
--- servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/wsdl/hello_world.wsdl
(added)
+++ servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/wsdl/hello_world.wsdl
Mon Dec 15 05:57:00 2008
@@ -0,0 +1,86 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+	Licensed to the Apache Software Foundation (ASF) under one
+	or more contributor license agreements. See the NOTICE file
+	distributed with this work for additional information
+	regarding copyright ownership. The ASF licenses this file
+	to you under the Apache License, Version 2.0 (the
+	"License"); you may not use this file except in compliance
+	with the License. You may obtain a copy of the License at
+
+	http://www.apache.org/licenses/LICENSE-2.0
+
+	Unless required by applicable law or agreed to in writing,
+	software distributed under the License is distributed on an
+	"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+	KIND, either express or implied. See the License for the
+	specific language governing permissions and limitations
+	under the License.
+-->
+<wsdl:definitions name="HelloWorldImplService" 
+                  targetNamespace="http://cxf.examples.servicemix.apache.org/" 
+                  xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" 
+                  xmlns:tns="http://cxf.examples.servicemix.apache.org/" 
+                  xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" 
+                  xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+                  xmlns:jms="http://cxf.apache.org/transports/jms">
+    <wsdl:types>
+        <xsd:schema attributeFormDefault="unqualified" 
+                    elementFormDefault="unqualified" 
+                    targetNamespace="http://cxf.examples.servicemix.apache.org/" 
+                    xmlns:tns="http://cxf.examples.servicemix.apache.org/" 
+                    xmlns:xsd="http://www.w3.org/2001/XMLSchema">
+            <xsd:element name="sayHi" type="tns:sayHi" />
+            <xsd:complexType name="sayHi">
+                <xsd:sequence>
+                    <xsd:element minOccurs="0" name="arg0" type="xsd:string" />
+                </xsd:sequence>
+            </xsd:complexType>
+            <xsd:element name="sayHiResponse" type="tns:sayHiResponse" />
+            <xsd:complexType name="sayHiResponse">
+                <xsd:sequence>
+                    <xsd:element minOccurs="0" name="return" type="xsd:string" />
+                </xsd:sequence>
+            </xsd:complexType>
+        </xsd:schema>
+    </wsdl:types>
+    <wsdl:message name="sayHiResponse">
+        <wsdl:part element="tns:sayHiResponse" name="parameters">
+        </wsdl:part>
+    </wsdl:message>
+    <wsdl:message name="sayHi">
+        <wsdl:part element="tns:sayHi" name="parameters">
+        </wsdl:part>
+    </wsdl:message>
+    <wsdl:portType name="HelloWorld">
+        <wsdl:operation name="sayHi">
+            <wsdl:input message="tns:sayHi" name="sayHi">
+            </wsdl:input>
+            <wsdl:output message="tns:sayHiResponse" name="sayHiResponse">
+            </wsdl:output>
+        </wsdl:operation>
+    </wsdl:portType>
+    <wsdl:binding name="HelloWorldImplServiceSoapBinding" type="tns:HelloWorld">
+        <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"
/>
+        <wsdl:operation name="sayHi">
+            <soap:operation soapAction="" style="document" />
+            <wsdl:input name="sayHi">
+                <soap:body use="literal" />
+            </wsdl:input>
+            <wsdl:output name="sayHiResponse">
+                <soap:body use="literal" />
+            </wsdl:output>
+        </wsdl:operation>
+    </wsdl:binding>
+    <wsdl:service name="HelloWorldImplService">
+        <wsdl:port binding="tns:HelloWorldImplServiceSoapBinding" name="HelloWorldImplPort">
+            <jms:address
+                   jndiConnectionFactoryName="ConnectionFactory"
+                   jndiDestinationName="dynamicQueues/test.jmstransport.text">       
            <jms:JMSNamingProperty name="java.naming.factory.initial" value="org.apache.activemq.jndi.ActiveMQInitialContextFactory"/>
+                   <jms:JMSNamingProperty name="java.naming.provider.url" value="tcp://localhost:61616"/>
+            </jms:address>
+
+            <jms:server durableSubscriberName="CXF_subscriber"/>
+        </wsdl:port>
+    </wsdl:service>
+</wsdl:definitions>

Propchange: servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/wsdl/hello_world.wsdl
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/wsdl/hello_world.wsdl
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: servicemix/smx4/features/trunk/examples/cxf-jms-osgi/src/main/resources/wsdl/hello_world.wsdl
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Modified: servicemix/smx4/features/trunk/examples/itests/pom.xml
URL: http://svn.apache.org/viewvc/servicemix/smx4/features/trunk/examples/itests/pom.xml?rev=726696&r1=726695&r2=726696&view=diff
==============================================================================
--- servicemix/smx4/features/trunk/examples/itests/pom.xml (original)
+++ servicemix/smx4/features/trunk/examples/itests/pom.xml Mon Dec 15 05:57:00 2008
@@ -196,6 +196,11 @@
             <version>${project.version}</version>
         </dependency>
         <dependency>
+            <groupId>org.apache.servicemix.examples</groupId>
+            <artifactId>cxf-jms-osgi</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+        <dependency>
 		    <groupId>org.apache.servicemix.examples</groupId>
 		    <artifactId>cxf-soap-handler-osgi</artifactId>
             <version>${project.version}</version>
@@ -262,10 +267,52 @@
         </dependency>
         <dependency>
           <groupId>org.apache.geronimo.specs</groupId>
+          <artifactId>geronimo-j2ee-management_1.1_spec</artifactId>
+          <version>${geronimo.j2ee.management.version}</version>
+        </dependency>
+        <dependency>
+          <groupId>org.apache.geronimo.specs</groupId>
           <artifactId>geronimo-jta_1.1_spec</artifactId>
           <version>${geronimo.jta.version}</version>
         </dependency>
         <dependency>
+          <groupId>commons-pool</groupId>
+          <artifactId>commons-pool</artifactId>
+          <version>${commons.pool.version}</version>
+        </dependency>
+        <dependency>
+          <groupId>org.apache.xbean</groupId>
+          <artifactId>xbean-spring</artifactId>
+          <version>${xbean.version}</version>
+        </dependency>
+        
+        <dependency>
+          <groupId>org.apache.activemq</groupId>
+          <artifactId>activemq-core</artifactId>
+          <version>${activemq.version}</version>
+        </dependency>
+        <dependency>
+          <groupId>org.apache.activemq</groupId>
+          <artifactId>activemq-ra</artifactId>
+          <version>${activemq.version}</version>
+        </dependency>
+        <dependency>
+          <groupId>org.apache.activemq</groupId>
+          <artifactId>activemq-console</artifactId>
+          <version>${activemq.version}</version>
+        </dependency>
+        <dependency>
+          <groupId>org.apache.activemq</groupId>
+          <artifactId>activemq-pool</artifactId>
+          <version>${activemq.version}</version>
+        </dependency>
+       
+        <dependency>
+          <groupId>org.apache.geronimo.specs</groupId>
+          <artifactId>geronimo-jms_1.1_spec</artifactId>
+          <version>${geronimo.jms.version}</version>
+        </dependency>
+        <dependency>
 		    <groupId>org.apache.geronimo.specs</groupId>
 		    <artifactId>geronimo-saaj_1.3_spec</artifactId>
             <version>${geronimo.saaj.version}</version>
@@ -288,7 +335,17 @@
         <dependency>
             <groupId>org.springframework</groupId>
             <artifactId>spring-context</artifactId>
-            <version>2.5.5</version>
+            <version>${spring.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.springframework</groupId>
+            <artifactId>spring-jms</artifactId>
+            <version>${spring.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.springframework</groupId>
+            <artifactId>spring-tx</artifactId>
+            <version>${spring.version}</version>
         </dependency>
     </dependencies>
 

Modified: servicemix/smx4/features/trunk/examples/itests/src/test/java/org/apache/servicemix/examples/IntegrationTest.java
URL: http://svn.apache.org/viewvc/servicemix/smx4/features/trunk/examples/itests/src/test/java/org/apache/servicemix/examples/IntegrationTest.java?rev=726696&r1=726695&r2=726696&view=diff
==============================================================================
--- servicemix/smx4/features/trunk/examples/itests/src/test/java/org/apache/servicemix/examples/IntegrationTest.java
(original)
+++ servicemix/smx4/features/trunk/examples/itests/src/test/java/org/apache/servicemix/examples/IntegrationTest.java
Mon Dec 15 05:57:00 2008
@@ -70,6 +70,19 @@
             getBundle("org.apache.geronimo.specs", "geronimo-ws-metadata_2.0_spec"),
             getBundle("org.apache.geronimo.specs", "geronimo-j2ee-connector_1.5_spec"),
             getBundle("org.apache.geronimo.specs", "geronimo-jta_1.1_spec"),
+            
+            //for activemq
+            getBundle("org.springframework", "spring-jms"),
+            getBundle("org.springframework", "spring-tx"),
+            getBundle("org.apache.geronimo.specs", "geronimo-j2ee-management_1.1_spec"),
+            getBundle("org.apache.geronimo.specs", "geronimo-jms_1.1_spec"),
+            getBundle("commons-pool", "commons-pool"),
+            getBundle("org.apache.xbean", "xbean-spring"),
+            getBundle("org.apache.activemq", "activemq-core"),
+            getBundle("org.apache.activemq", "activemq-ra"),
+            getBundle("org.apache.activemq", "activemq-console"),
+            getBundle("org.apache.activemq", "activemq-pool"),
+                        
             getBundle("org.apache.servicemix.specs", "org.apache.servicemix.specs.stax-api-1.0"),
             getBundle("org.apache.servicemix.specs", "org.apache.servicemix.specs.saaj-api-1.3"),
             getBundle("org.apache.servicemix.specs", "org.apache.servicemix.specs.jaxb-api-2.1"),
@@ -95,6 +108,7 @@
             getBundle("org.apache.servicemix.nmr", "org.apache.servicemix.nmr.osgi"),
             getBundle("org.apache.servicemix.document", "org.apache.servicemix.document"),
             getBundle("org.apache.servicemix.examples", "cxf-http-osgi"),
+            getBundle("org.apache.servicemix.examples", "cxf-jms-osgi"),
             getBundle("org.apache.servicemix.examples", "cxf-soap-handler-osgi"),
             getBundle("org.apache.servicemix.examples", "cxf-handler-cfg"),
             getBundle("org.apache.servicemix.examples", "cxf-ws-addressing"),
@@ -122,6 +136,22 @@
 
         assertEquals("Hello Bonjour", helloWorld.sayHi("Bonjour"));
     }
+    
+    public void testJmsOsgi() throws Exception {
+        Thread.sleep(5000);
+        waitOnContextCreation("cxf-jms-osgi");
+        Thread.sleep(5000);
+
+        ServiceReference ref = bundleContext.getServiceReference(HelloWorld.class.getName());
+        assertNotNull("Service Reference is null", ref);
+
+        org.apache.servicemix.examples.cxf.HelloWorld helloWorld = null;
+
+        helloWorld = (org.apache.servicemix.examples.cxf.HelloWorld) bundleContext.getService(ref);
+        assertNotNull("Cannot find the service", helloWorld);
+
+        assertEquals("Hello Bonjour", helloWorld.sayHi("Bonjour"));
+    }
 
     protected Manifest getManifest() {
         Manifest mf = super.getManifest();

Modified: servicemix/smx4/features/trunk/examples/pom.xml
URL: http://svn.apache.org/viewvc/servicemix/smx4/features/trunk/examples/pom.xml?rev=726696&r1=726695&r2=726696&view=diff
==============================================================================
--- servicemix/smx4/features/trunk/examples/pom.xml (original)
+++ servicemix/smx4/features/trunk/examples/pom.xml Mon Dec 15 05:57:00 2008
@@ -44,6 +44,7 @@
         <module>cxf-nmr</module>
         <module>cxf-osgi</module>
         <module>cxf-http-osgi</module>
+        <module>cxf-jms-osgi</module>
         <module>cxf-soap-handler-osgi</module>
         <module>cxf-handler-cfg</module>
         <module>cxf-ws-addressing</module>



Mime
View raw message