You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cxf.apache.org by ni...@apache.org on 2008/09/17 12:07:28 UTC
svn commit: r696227 [1/2] - in /cxf/trunk:
distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/
distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/etc/
distribution/src/main/release/samples/integ...
Author: ningjiang
Date: Wed Sep 17 03:07:25 2008
New Revision: 696227
URL: http://svn.apache.org/viewvc?rev=696227&view=rev
Log:
CXF-1801 applied patch with thanks to William
Added:
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb/
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/README.txt (with props)
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/build.xml (with props)
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/etc/
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/etc/cxf.xml (with props)
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/etc/ejb-jar.xml (with props)
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/etc/ra.xml (with props)
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/client/
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/client/Client.java (with props)
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/ejb/
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/ejb/GreeterBean.java (with props)
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/ejb/GreeterLocal.java (with props)
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/ejb/GreeterLocalHome.java (with props)
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/wsdl/
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/wsdl/hello_world.wsdl (with props)
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/README.txt (with props)
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/build.xml (with props)
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/etc/
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/etc/ejb-jar.xml (with props)
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/etc/ra.xml (with props)
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/demo/
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/demo/client/
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/demo/client/GreeterClient.java (with props)
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/demo/ejb/
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/demo/ejb/GreeterBean.java (with props)
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/demo/ejb/GreeterHome.java (with props)
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/demo/ejb/GreeterLocal.java (with props)
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/demo/ejb/GreeterLocalHome.java (with props)
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/demo/ejb/GreeterRemote.java (with props)
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/org/
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/org/apache/
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/org/apache/hello_world_soap_http/
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/org/apache/hello_world_soap_http/Greeter.java (with props)
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb/README.txt (with props)
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb/build.xml (with props)
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb/etc/
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb/etc/ejb-jar.xml (with props)
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb/etc/ra.xml (with props)
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb/src/
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb/src/demo/
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb/src/demo/client/
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb/src/demo/client/GreeterClient.java (with props)
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb/src/demo/ejb/
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb/src/demo/ejb/GreeterBean.java (with props)
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb/src/org/
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb/src/org/apache/
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb/src/org/apache/hello_world_soap_http/
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb/src/org/apache/hello_world_soap_http/Greeter.java (with props)
cxf/trunk/integration/jca/src/main/java/org/apache/cxf/jca/inbound/
cxf/trunk/integration/jca/src/main/java/org/apache/cxf/jca/inbound/DispatchMDBActivationSpec.java (with props)
cxf/trunk/integration/jca/src/main/java/org/apache/cxf/jca/inbound/DispatchMDBInvoker.java (with props)
cxf/trunk/integration/jca/src/main/java/org/apache/cxf/jca/inbound/DispatchMDBMessageListener.java (with props)
cxf/trunk/integration/jca/src/main/java/org/apache/cxf/jca/inbound/DispatchMDBMessageListenerImpl.java (with props)
cxf/trunk/integration/jca/src/main/java/org/apache/cxf/jca/inbound/InboundEndpoint.java (with props)
cxf/trunk/integration/jca/src/main/java/org/apache/cxf/jca/inbound/MDBActivationSpec.java (with props)
cxf/trunk/integration/jca/src/main/java/org/apache/cxf/jca/inbound/MDBActivationWork.java (with props)
cxf/trunk/integration/jca/src/main/java/org/apache/cxf/jca/inbound/MDBInvoker.java (with props)
Modified:
cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound/README.txt
cxf/trunk/integration/jca/src/main/java/org/apache/cxf/jca/cxf/ResourceAdapterImpl.java
cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/EndpointUtils.java
Added: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/README.txt
URL: http://svn.apache.org/viewvc/cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/README.txt?rev=696227&view=auto
==============================================================================
--- cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/README.txt (added)
+++ cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/README.txt Wed Sep 17 03:07:25 2008
@@ -0,0 +1,192 @@
+CXF INBOUND RESOURCE ADAPTER MESSAGE DRIVEN BEAN DISPATCHING SAMPLE (WSDL)
+==========================================================================
+
+Please read the "Introduction to the inbound-mdb* Samples" section
+in the inbound-mdb/README.txt. It contains important information.
+
+
+MDB Invoking Session Bean (with WSDL)
+-------------------------------------
+
+This sample is similar to the "inbound-mdb-dispatch" sample except that it
+is bundled with WSDL and CXF bus config in the EJB jar. CXF will create
+a service bean based on the provided WSDL. The CXF bus config file in
+etc/cxf.xml enabled logging feature. Also, this sample does not implement a
+remote interface for the GreeterBean.
+
+
+Building and running the sample using Ant
+-----------------------------------------
+From the base directory of this sample (i.e., where this README file is
+located), the Ant build.xml file can be used to build and run the sample.
+
+
+Build CXF J2C RAR file
+----------------------
+ (Unix) % ant generate.rar
+ (Windows) > ant generate.rar
+
+The result RAR file is located in build/lib/cxf.rar
+
+Launch the application server
+-----------------------------
+
+The sample requires an application server (WebSphere 6.1). Make sure
+you have a running instance of an application server.
+
+Deploy the CXF JCA Connector
+-----------------------------
+
+The CXF JCA Connector must be deployed to the application server before
+running the sample. The JCA Connector used in this sample can only be
+shared by the inbound-mdb-dispatch sample. If you have deployed
+a CXF JCA Connector from that sample, you can skip the following steps
+and goto "Building Message Driven Bean Jar". Otherwise, please make sure
+there is no other CXF JCA Connector deployed into the application
+server.
+
+Please consult your vendor documentation on Resource Adapter deployment.
+Here are basic instructions to deploy the connector in WebSphere 6.1.
+
+1. Logon to WebSphere Integrated Solution Console. The default address is:
+
+ http://<hostname>:9060/ibm/console/login.do
+
+2. Navigate to tree menu: Resources -> Resource adapters -> Resource adapters
+
+3. On the Resource adapters page, click the "Install RAR" button.
+
+4. On the Install RAR File page, select the "Local path" radio button if this
+ sample is on the same machine as the WebSphere server. Otherwise, select
+ the "Server path" radio button. Specify or browse to the path
+ build/lib/cxf.rar file in this sample. Then, click the "Next" button.
+
+5. On the next page, click the "OK" button to install the Resource Adapter.
+
+6. On the next page, click the "CXF JCA Connector" link to edit the Resource
+ Adatper.
+
+7. On the "Configuration" page, click the "J2C activation specification"
+ link.
+
+8. On the next page, click the "New" button to create a new Activation
+ Specifications.
+
+9. On the next page, enter "MyActivationSpec" in the Name textbox and click
+ the "OK" button.
+
+ Notice that the JNDI name is optional. If it is omitted, a JNDI name
+ is created for you as eis/<ActivationSpecName> where <ActivationSpecName>
+ is "MyActivationSpec" above.
+
+10. Finally, click the "Save" link to commit the configuration.
+
+ Notice that you can specify activation config values in the new
+ activation spec you just created. The activation spec will be associated
+ to your MDB later. The MDB's deployment descriptor can define activation
+ config values to override the values specified in the associated activation
+ spec.
+
+
+Building Message Driven Bean Jar
+--------------------------------
+
+Issue the command:
+
+ (Unix) % ant
+ (Windows) > ant
+
+
+Deploying the Message Drive Bean
+--------------------------------
+
+Please consult your vendor documentation on EJB deployment. Here are
+basic instructions to deploy the MDB in WebSphere 6.1.
+
+1. Logon to WebSphere Integrated Solution Console. The default address is:
+
+ http://<hostname>:9060/ibm/console/login.do
+
+2. Navigate to tree menu: Applications -> Install new Applications
+
+3. On the "Preparing for the application installation" page, select the "Local
+ path" radio button if this sample is on the same machine as the WebSphere
+ server. Otherwise, select the "Server path" radio button. Specify or
+ browse to the path j2ee-archives/greeterwithwsdlejb.jar file in this
+ sample. Then, click the "Next" button.
+
+4. Click the "Next" button on the "Step 1: Select installation options" page.
+
+5. Click the "Next" button on the "Step 2: Map modules to servers" page.
+
+6. On the "Step 3: Bind listeners for message-driven beans" page, click the
+ "Activation Specification" radio button on the far right column. The
+ specify the Target Resource JNDI Name as below and the client the "Next"
+ button.
+
+ eis/MyActivationSpec
+
+7. On the "Step 4: Provide JNDI names for beans" page, enter
+ "ejb/GreeterWithWsdlBean" then click the "Next" button.
+
+8. On the "Step 5: Map EJB references to beans" page, enter value below and
+ then click the "Next" button.
+
+ ejb/GreeterWithWsdlBean
+
+9. On the "Step 6: Summary" page, click the "Finish" button.
+
+10. Click the "Save" link to commit the configuration.
+
+11. Navigate to tree menu: Applications -> Enterprise Applications
+
+12. Select the box next to "greeterwithwsdlejb_jar" and click the "Start"
+ button at the top to start the MDB.
+
+
+Running the Demo
+----------------
+
+Once the resource adapter and the EJB application have been deployed,
+the client can be run with the ant build script:
+
+ ant client
+
+
+This will launch an CXF Java Client which contacts the web service
+endpoint facade. The facade then invokes the MDB's message listener
+which is org.apache.cxf.jca.inbound.DispatchMDBMessageListenerImpl.
+The DispatchMDBMessageListenerImpl performs a JNDI lookup to obtain a
+EJBLocalObject reference to the target Stateless Session Bean that
+implements the Greater interface. The output from the Session Bean
+(GreeterBean) is returned to the client.
+
+Notice that service contract (WSDL) is the same as the one in wsdl_first
+sample. Therefore, you can also run the same client in the wsdl_first.
+
+The following output is observed from the client.
+
+client:
+ [java] file:/C:/apache-cxf-2.2-SNAPSHOT/samples/integration/jca/inbound-mdb
+-dispatch-wsdl/wsdl/hello_world.wsdl
+ [java] Invoking sayHi...
+ [java] Server responded with: Bonjour
+
+ [java] Invoking greetMe...
+ [java] Server responded with: Hello WTAM
+
+ [java] Invoking greetMe with invalid length string, expecting exception...
+
+ [java] Invoking greetMeOneWay...
+ [java] No response from server as method is OneWay
+
+ [java] Invoking pingMe, expecting exception...
+ [java] Expected exception: PingMeFault has occurred: PingMeFault raised by
+server
+ [java] FaultDetail major:2
+ [java] FaultDetail minor:1
+
+Also, if trace log is enabled in the application server, you are able to see
+SOAP messages exchanged between the server and client.
+
+
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/README.txt
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/README.txt
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/build.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/build.xml?rev=696227&view=auto
==============================================================================
--- cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/build.xml (added)
+++ cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/build.xml Wed Sep 17 03:07:25 2008
@@ -0,0 +1,120 @@
+<?xml version="1.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.
+-->
+
+<project name="Inbound Connection Demo" default="build" basedir=".">
+ <property environment="env"/>
+
+ <property environment="env"/>
+ <condition property="cxf.home" value="${env.CXF_HOME}">
+ <isset property="env.CXF_HOME"/>
+ </condition>
+
+ <fail message="this sample need to use CXF_HOME enviroment, please setup CXF_HOME in your environment" unless="cxf.home"/>
+
+ <property name="j2ee.resources.dir" location="${basedir}/../common/resources"/>
+ <property name="build.archives" value="${basedir}/j2ee-archives"/>
+ <property name="ejb.xml" location="./etc/ejb.xml"/>
+ <property name="j2ee.archives" value="j2ee-archives"/>
+ <property name="demos.current.dir" value="."/>
+ <property name="build.classes.dir" value="${basedir}/build"/>
+
+ <import file="../../../common_build.xml"/>
+
+
+ <path id="other.classpath">
+ <fileset dir="${cxf.home}/modules/integration" >
+ <include name="cxf-integration-jca-*.jar"/>
+ </fileset>
+ <pathelement location="${basedir}/../common/lib/geronimo-ejb_3.0_spec-1.0.1.jar"/>
+ </path>
+
+ <target name="init">
+ <mkdir dir="${build.classes.dir}/cxf-rar/META-INF"/>
+ <mkdir dir="${build.classes.dir}/lib"/>
+ <mkdir dir="${j2ee.archives}"/>
+ </target>
+
+ <target name="generate.code">
+ <echo level="info" message="Generating code using wsdl2java..."/>
+ <wsdl2java file="hello_world.wsdl"/>
+ </target>
+
+ <target name="generate.rar" depends="init">
+ <copy file="${basedir}/etc/ra.xml" todir="${build.classes.dir}/cxf-rar/META-INF"/>
+ <copy todir="${build.classes.dir}/cxf-rar">
+ <fileset dir="${cxf.home}/lib">
+ <include name="*.jar"/>
+ <exclude name="cxf*.jar"/>
+ </fileset>
+ <fileset dir="${cxf.home}/modules">
+ <include name="*.jar"/>
+ <exclude name="*manifest*.jar"/>
+ </fileset>
+ <fileset dir="${cxf.home}/modules/integration">
+ <include name="*.jar"/>
+ <exclude name="*-jbi-*.jar"/>
+ </fileset>
+ </copy>
+ <jar destfile="${build.classes.dir}/lib/cxf.rar"
+ basedir="${build.classes.dir}/cxf-rar"/>
+ </target>
+
+ <target name="build" description="compile the code" depends="build.ejb.jar"/>
+
+ <target name="j2ee.compile" depends="init,maybe.generate.code">
+ <javac destdir="${build.classes.dir}" debug="true" fork="yes">
+ <src path="${basedir}/src"/>
+ <src path="${build.dir}/src"/>
+ <classpath>
+ <pathelement location="${cxf.home}/modules/cxf-manifest.jar"/>
+ <pathelement location="${build.classes.dir}"/>
+ <path refid="cxf.classpath"/>
+ <path refid="other.classpath"/>
+ </classpath>
+ </javac>
+ </target>
+
+ <target name="clean">
+ <delete dir="${build.dir}"/>
+ <delete dir="${basedir}/j2ee-archives"/>
+ </target>
+
+ <target name="build.ejb.jar" depends="j2ee.compile">
+ <jar destfile="${j2ee.archives}/greeterwithwsdlejb.jar">
+ <metainf dir="${basedir}/etc">
+ <include name="ejb-jar.xml"/>
+ </metainf>
+ <fileset dir="${build.classes.dir}/" includes="org/**/*.class"/>
+ <fileset dir="${build.classes.dir}/" includes="demo/ejb/**/Greeter*.class"/>
+ <fileset dir="${basedir}" includes="wsdl/**/*.wsdl"/>
+ <fileset dir="${basedir}" includes="etc/cxf.xml"/>
+ </jar>
+ </target>
+
+ <target name="client" description="run demo client" depends="build">
+ <property name="param" value=""/>
+ <cxfrun classname="demo.client.Client"
+ param1="${basedir}/wsdl/hello_world.wsdl"
+ param2="${op}"
+ param3="${param}"/>
+ </target>
+
+</project>
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/build.xml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/build.xml
------------------------------------------------------------------------------
svn:keywords = Rev Date
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/build.xml
------------------------------------------------------------------------------
svn:mime-type = text/xml
Added: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/etc/cxf.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/etc/cxf.xml?rev=696227&view=auto
==============================================================================
--- cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/etc/cxf.xml (added)
+++ cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/etc/cxf.xml Wed Sep 17 03:07:25 2008
@@ -0,0 +1,29 @@
+<beans xmlns="http://www.springframework.org/schema/beans"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns:cxf="http://cxf.apache.org/core"
+ xsi:schemaLocation="
+ http://cxf.apache.org/core http://cxf.apache.org/schemas/core.xsd
+ http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.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.
+ -->
+
+ <cxf:bus>
+ <cxf:features>
+ <cxf:logging/>
+ </cxf:features>
+ </cxf:bus>
+</beans>
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/etc/cxf.xml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/etc/cxf.xml
------------------------------------------------------------------------------
svn:keywords = Rev Date
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/etc/cxf.xml
------------------------------------------------------------------------------
svn:mime-type = text/xml
Added: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/etc/ejb-jar.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/etc/ejb-jar.xml?rev=696227&view=auto
==============================================================================
--- cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/etc/ejb-jar.xml (added)
+++ cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/etc/ejb-jar.xml Wed Sep 17 03:07:25 2008
@@ -0,0 +1,125 @@
+<?xml version="1.0"?>
+<ejb-jar xmlns="http://java.sun.com/xml/ns/javaee"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
+ http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd"
+ version="3.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.
+ -->
+
+ <enterprise-beans>
+ <session>
+ <ejb-name>GreeterWithWsdlBean</ejb-name>
+ <local-home>demo.ejb.GreeterLocalHome</local-home>
+ <local>demo.ejb.GreeterLocal</local>
+ <ejb-class>demo.ejb.GreeterBean</ejb-class>
+ <session-type>Stateless</session-type>
+ <transaction-type>Container</transaction-type>
+ </session>
+
+ <message-driven>
+ <ejb-name>GreeterEndpointActivator</ejb-name>
+ <ejb-class>org.apache.cxf.jca.inbound.DispatchMDBMessageListenerImpl</ejb-class>
+ <messaging-type>org.apache.cxf.jca.inbound.DispatchMDBMessageListener</messaging-type>
+ <transaction-type>Bean</transaction-type>
+
+ <activation-config>
+ <!-- bus configuration location -->
+ <activation-config-property>
+ <activation-config-property-name>
+ busConfigLocation
+ </activation-config-property-name>
+ <activation-config-property-value>
+ etc/cxf.xml
+ </activation-config-property-value>
+ </activation-config-property>
+ <!-- wsdl location -->
+ <activation-config-property>
+ <activation-config-property-name>
+ wsdlLocation
+ </activation-config-property-name>
+ <activation-config-property-value>
+ wsdl/hello_world.wsdl
+ </activation-config-property-value>
+ </activation-config-property>
+ <!-- service name -->
+ <activation-config-property>
+ <activation-config-property-name>
+ serviceName
+ </activation-config-property-name>
+ <activation-config-property-value>
+ {http://apache.org/hello_world_soap_http}SOAPService
+ </activation-config-property-value>
+ </activation-config-property>
+ <!-- endpoint name -->
+ <activation-config-property>
+ <activation-config-property-name>
+ endpointName
+ </activation-config-property-name>
+ <activation-config-property-value>
+ {http://apache.org/hello_world_soap_http}SOAPPort
+ </activation-config-property-value>
+ </activation-config-property>
+ <!-- service interface class -->
+ <activation-config-property>
+ <activation-config-property-name>
+ serviceInterfaceClass
+ </activation-config-property-name>
+ <activation-config-property-value>
+ org.apache.hello_world_soap_http.Greeter
+ </activation-config-property-value>
+ </activation-config-property>
+ <!-- address -->
+ <activation-config-property>
+ <activation-config-property-name>
+ address
+ </activation-config-property-name>
+ <activation-config-property-value>
+ http://localhost:9000/SoapContext/SoapPort
+ </activation-config-property-value>
+ </activation-config-property>
+ <!-- display name-->
+ <activation-config-property>
+ <activation-config-property-name>
+ displayName
+ </activation-config-property-name>
+ <activation-config-property-value>
+ GreeterWithWsdlEndpoint
+ </activation-config-property-value>
+ </activation-config-property>
+ <!-- targetBeanJndiName -->
+ <activation-config-property>
+ <activation-config-property-name>
+ targetBeanJndiName
+ </activation-config-property-name>
+ <activation-config-property-value>
+ java:comp/env/GreeterWithWsdlLocalHome
+ </activation-config-property-value>
+ </activation-config-property>
+ </activation-config>
+
+ <ejb-local-ref>
+ <ejb-ref-name>GreeterWithWsdlLocalHome</ejb-ref-name>
+ <ejb-ref-type>Session</ejb-ref-type>
+ <local-home>demo.ejb.GreeterLocalHome</local-home>
+ <local>demo.ejb.GreeterLocal</local>
+ <ejb-link>GreeterWithWsdlBean</ejb-link>
+ </ejb-local-ref>
+ </message-driven>
+
+ </enterprise-beans>
+</ejb-jar>
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/etc/ejb-jar.xml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/etc/ejb-jar.xml
------------------------------------------------------------------------------
svn:keywords = Rev Date
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/etc/ejb-jar.xml
------------------------------------------------------------------------------
svn:mime-type = text/xml
Added: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/etc/ra.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/etc/ra.xml?rev=696227&view=auto
==============================================================================
--- cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/etc/ra.xml (added)
+++ cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/etc/ra.xml Wed Sep 17 03:07:25 2008
@@ -0,0 +1,54 @@
+<?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.
+ -->
+<connector xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
+http://java/sun.com/xml/ns/j2ee/connector_1_5.xsd"
+ version="1.5">
+ <display-name>CXF JCA Connector</display-name>
+ <vendor-name>Apache CXF</vendor-name>
+ <eis-type>CXF</eis-type>
+ <resourceadapter-version>2.0</resourceadapter-version>
+ <license>
+ <license-required>false</license-required>
+ </license>
+ <resourceadapter>
+ <resourceadapter-class> org.apache.cxf.jca.cxf.ResourceAdapterImpl
+ </resourceadapter-class>
+ <inbound-resourceadapter>
+ <messageadapter>
+ <messagelistener>
+ <messagelistener-type>
+ org.apache.cxf.jca.inbound.DispatchMDBMessageListener
+ </messagelistener-type>
+ <activationspec>
+ <activationspec-class>
+ org.apache.cxf.jca.inbound.DispatchMDBActivationSpec
+ </activationspec-class>
+ <required-config-property>
+ <config-property-name>displayName
+ </config-property-name>
+ </required-config-property>
+ <required-config-property>
+ <config-property-name>targetBeanJndiName
+ </config-property-name>
+ </required-config-property>
+ </activationspec>
+ </messagelistener>
+ </messageadapter>
+ </inbound-resourceadapter>
+ </resourceadapter>
+</connector>
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/etc/ra.xml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/etc/ra.xml
------------------------------------------------------------------------------
svn:keywords = Rev Date
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/etc/ra.xml
------------------------------------------------------------------------------
svn:mime-type = text/xml
Added: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/client/Client.java
URL: http://svn.apache.org/viewvc/cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/client/Client.java?rev=696227&view=auto
==============================================================================
--- cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/client/Client.java (added)
+++ cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/client/Client.java Wed Sep 17 03:07:25 2008
@@ -0,0 +1,97 @@
+/**
+ * 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 demo.client;
+
+import java.io.File;
+import java.net.URL;
+import javax.xml.namespace.QName;
+import javax.xml.ws.WebServiceException;
+import org.apache.hello_world_soap_http.Greeter;
+import org.apache.hello_world_soap_http.PingMeFault;
+import org.apache.hello_world_soap_http.SOAPService;
+import org.apache.hello_world_soap_http.types.FaultDetail;
+
+public final class Client {
+
+ private static final QName SERVICE_NAME
+ = new QName("http://apache.org/hello_world_soap_http", "SOAPService");
+
+
+ private Client() {
+ }
+
+ public static void main(String args[]) throws Exception {
+
+ if (args.length == 0) {
+ System.out.println("please specify wsdl");
+ System.exit(1);
+ }
+
+ URL wsdlURL;
+ File wsdlFile = new File(args[0]);
+ if (wsdlFile.exists()) {
+ wsdlURL = wsdlFile.toURL();
+ } else {
+ wsdlURL = new URL(args[0]);
+ }
+
+ System.out.println(wsdlURL);
+ SOAPService ss = new SOAPService(wsdlURL, SERVICE_NAME);
+ Greeter port = ss.getSoapPort();
+ String resp;
+
+ System.out.println("Invoking sayHi...");
+ resp = port.sayHi();
+ System.out.println("Server responded with: " + resp);
+ System.out.println();
+
+ System.out.println("Invoking greetMe...");
+ resp = port.greetMe(System.getProperty("user.name"));
+ System.out.println("Server responded with: " + resp);
+ System.out.println();
+
+ System.out.println("Invoking greetMe with invalid length string, expecting exception...");
+ try {
+ resp = port.greetMe("Invoking greetMe with invalid length string, expecting exception...");
+ } catch (WebServiceException ex) {
+ System.out.println("Caught expected WebServiceException:");
+ System.out.println(" " + ex.getMessage());
+ }
+
+ System.out.println();
+
+ System.out.println("Invoking greetMeOneWay...");
+ port.greetMeOneWay(System.getProperty("user.name"));
+ System.out.println("No response from server as method is OneWay");
+ System.out.println();
+
+ try {
+ System.out.println("Invoking pingMe, expecting exception...");
+ port.pingMe();
+ } catch (PingMeFault ex) {
+ System.out.println("Expected exception: PingMeFault has occurred: " + ex.getMessage());
+ FaultDetail detail = ex.getFaultInfo();
+ System.out.println("FaultDetail major:" + detail.getMajor());
+ System.out.println("FaultDetail minor:" + detail.getMinor());
+ }
+ System.exit(0);
+ }
+
+}
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/client/Client.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/client/Client.java
------------------------------------------------------------------------------
svn:keywords = Rev Date
Added: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/ejb/GreeterBean.java
URL: http://svn.apache.org/viewvc/cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/ejb/GreeterBean.java?rev=696227&view=auto
==============================================================================
--- cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/ejb/GreeterBean.java (added)
+++ cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/ejb/GreeterBean.java Wed Sep 17 03:07:25 2008
@@ -0,0 +1,82 @@
+/**
+ * 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 demo.ejb;
+
+import java.util.logging.Logger;
+import javax.ejb.CreateException;
+import javax.ejb.SessionBean;
+import javax.ejb.SessionContext;
+
+import org.apache.hello_world_soap_http.Greeter;
+import org.apache.hello_world_soap_http.PingMeFault;
+import org.apache.hello_world_soap_http.types.FaultDetail;
+
+public class GreeterBean implements SessionBean, Greeter {
+
+ private static final Logger LOG =
+ Logger.getLogger(GreeterBean.class.getPackage().getName());
+
+ //------------- Business Methods
+ // (copied from wsdl_first sample)
+
+ public String greetMe(String me) {
+ LOG.info("Executing operation greetMe");
+ System.out.println("Executing operation greetMe");
+ System.out.println("Message received: " + me + "\n");
+ return "Hello " + me;
+ }
+
+ public void greetMeOneWay(String me) {
+ LOG.info("Executing operation greetMeOneWay");
+ System.out.println("Executing operation greetMeOneWay\n");
+ System.out.println("Hello there " + me);
+ }
+
+ public String sayHi() {
+ LOG.info("Executing operation sayHi");
+ System.out.println("Executing operation sayHi\n");
+ return "Bonjour";
+ }
+
+ public void pingMe() throws PingMeFault {
+ FaultDetail faultDetail = new FaultDetail();
+ faultDetail.setMajor((short)2);
+ faultDetail.setMinor((short)1);
+ LOG.info("Executing operation pingMe, throwing PingMeFault exception");
+ System.out.println("Executing operation pingMe, throwing PingMeFault exception\n");
+ throw new PingMeFault("PingMeFault raised by server", faultDetail);
+ }
+
+ //------------- EJB Methods
+ public void ejbActivate() {
+ }
+
+ public void ejbRemove() {
+ }
+
+ public void ejbPassivate() {
+ }
+
+ public void ejbCreate() throws CreateException {
+ }
+
+ public void setSessionContext(SessionContext con) {
+ }
+
+}
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/ejb/GreeterBean.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/ejb/GreeterBean.java
------------------------------------------------------------------------------
svn:keywords = Rev Date
Added: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/ejb/GreeterLocal.java
URL: http://svn.apache.org/viewvc/cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/ejb/GreeterLocal.java?rev=696227&view=auto
==============================================================================
--- cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/ejb/GreeterLocal.java (added)
+++ cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/ejb/GreeterLocal.java Wed Sep 17 03:07:25 2008
@@ -0,0 +1,27 @@
+/**
+ * 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 demo.ejb;
+
+import javax.ejb.EJBLocalObject;
+import org.apache.hello_world_soap_http.Greeter;
+
+public interface GreeterLocal extends EJBLocalObject, Greeter {
+}
+
+
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/ejb/GreeterLocal.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/ejb/GreeterLocal.java
------------------------------------------------------------------------------
svn:keywords = Rev Date
Added: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/ejb/GreeterLocalHome.java
URL: http://svn.apache.org/viewvc/cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/ejb/GreeterLocalHome.java?rev=696227&view=auto
==============================================================================
--- cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/ejb/GreeterLocalHome.java (added)
+++ cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/ejb/GreeterLocalHome.java Wed Sep 17 03:07:25 2008
@@ -0,0 +1,27 @@
+/**
+ * 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 demo.ejb;
+
+import javax.ejb.CreateException;
+import javax.ejb.EJBLocalHome;
+
+public interface GreeterLocalHome extends EJBLocalHome {
+ GreeterLocal create() throws CreateException;
+}
+
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/ejb/GreeterLocalHome.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/src/demo/ejb/GreeterLocalHome.java
------------------------------------------------------------------------------
svn:keywords = Rev Date
Added: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/wsdl/hello_world.wsdl
URL: http://svn.apache.org/viewvc/cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/wsdl/hello_world.wsdl?rev=696227&view=auto
==============================================================================
--- cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/wsdl/hello_world.wsdl (added)
+++ cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/wsdl/hello_world.wsdl Wed Sep 17 03:07:25 2008
@@ -0,0 +1,181 @@
+<?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="HelloWorld" targetNamespace="http://apache.org/hello_world_soap_http"
+ xmlns="http://schemas.xmlsoap.org/wsdl/"
+ xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+ xmlns:tns="http://apache.org/hello_world_soap_http"
+ xmlns:x1="http://apache.org/hello_world_soap_http/types"
+ xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema">
+ <wsdl:types>
+ <schema targetNamespace="http://apache.org/hello_world_soap_http/types"
+ xmlns="http://www.w3.org/2001/XMLSchema"
+ xmlns:tns="http://apache.org/hello_world_soap_http/types"
+ elementFormDefault="qualified">
+ <simpleType name="MyStringType">
+ <restriction base="string">
+ <maxLength value="30" />
+ </restriction>
+ </simpleType>
+
+ <element name="sayHi">
+ <complexType/>
+ </element>
+ <element name="sayHiResponse">
+ <complexType>
+ <sequence>
+ <element name="responseType" type="string"/>
+ </sequence>
+ </complexType>
+ </element>
+ <element name="greetMe">
+ <complexType>
+ <sequence>
+ <element name="requestType" type="tns:MyStringType"/>
+ </sequence>
+ </complexType>
+ </element>
+ <element name="greetMeResponse">
+ <complexType>
+ <sequence>
+ <element name="responseType" type="string"/>
+ </sequence>
+ </complexType>
+ </element>
+ <element name="greetMeOneWay">
+ <complexType>
+ <sequence>
+ <element name="requestType" type="string"/>
+ </sequence>
+ </complexType>
+ </element>
+ <element name="pingMe">
+ <complexType/>
+ </element>
+ <element name="pingMeResponse">
+ <complexType/>
+ </element>
+ <element name="faultDetail">
+ <complexType>
+ <sequence>
+ <element name="minor" type="short"/>
+ <element name="major" type="short"/>
+ </sequence>
+ </complexType>
+ </element>
+ </schema>
+ </wsdl:types>
+ <wsdl:message name="sayHiRequest">
+ <wsdl:part element="x1:sayHi" name="in"/>
+ </wsdl:message>
+ <wsdl:message name="sayHiResponse">
+ <wsdl:part element="x1:sayHiResponse" name="out"/>
+ </wsdl:message>
+ <wsdl:message name="greetMeRequest">
+ <wsdl:part element="x1:greetMe" name="in"/>
+ </wsdl:message>
+ <wsdl:message name="greetMeResponse">
+ <wsdl:part element="x1:greetMeResponse" name="out"/>
+ </wsdl:message>
+ <wsdl:message name="greetMeOneWayRequest">
+ <wsdl:part element="x1:greetMeOneWay" name="in"/>
+ </wsdl:message>
+ <wsdl:message name="pingMeRequest">
+ <wsdl:part name="in" element="x1:pingMe"/>
+ </wsdl:message>
+ <wsdl:message name="pingMeResponse">
+ <wsdl:part name="out" element="x1:pingMeResponse"/>
+ </wsdl:message>
+ <wsdl:message name="pingMeFault">
+ <wsdl:part name="faultDetail" element="x1:faultDetail"/>
+ </wsdl:message>
+
+ <wsdl:portType name="Greeter">
+ <wsdl:operation name="sayHi">
+ <wsdl:input message="tns:sayHiRequest" name="sayHiRequest"/>
+ <wsdl:output message="tns:sayHiResponse" name="sayHiResponse"/>
+ </wsdl:operation>
+
+ <wsdl:operation name="greetMe">
+ <wsdl:input message="tns:greetMeRequest" name="greetMeRequest"/>
+ <wsdl:output message="tns:greetMeResponse" name="greetMeResponse"/>
+ </wsdl:operation>
+
+ <wsdl:operation name="greetMeOneWay">
+ <wsdl:input message="tns:greetMeOneWayRequest" name="greetMeOneWayRequest"/>
+ </wsdl:operation>
+
+ <wsdl:operation name="pingMe">
+ <wsdl:input name="pingMeRequest" message="tns:pingMeRequest"/>
+ <wsdl:output name="pingMeResponse" message="tns:pingMeResponse"/>
+ <wsdl:fault name="pingMeFault" message="tns:pingMeFault"/>
+ </wsdl:operation>
+ </wsdl:portType>
+ <wsdl:binding name="Greeter_SOAPBinding" type="tns:Greeter">
+ <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
+
+ <wsdl:operation name="sayHi">
+ <soap:operation soapAction="" style="document"/>
+ <wsdl:input name="sayHiRequest">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="sayHiResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ </wsdl:operation>
+
+ <wsdl:operation name="greetMe">
+ <soap:operation soapAction="" style="document"/>
+ <wsdl:input name="greetMeRequest">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="greetMeResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ </wsdl:operation>
+
+ <wsdl:operation name="greetMeOneWay">
+ <soap:operation soapAction="" style="document"/>
+ <wsdl:input name="greetMeOneWayRequest">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ </wsdl:operation>
+
+ <wsdl:operation name="pingMe">
+ <soap:operation style="document"/>
+ <wsdl:input>
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output>
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="pingMeFault">
+ <soap:fault name="pingMeFault" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+
+ </wsdl:binding>
+ <wsdl:service name="SOAPService">
+ <wsdl:port binding="tns:Greeter_SOAPBinding" name="SoapPort">
+ <soap:address location="http://localhost:9000/SoapContext/SoapPort"/>
+ </wsdl:port>
+ </wsdl:service>
+</wsdl:definitions>
+
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/wsdl/hello_world.wsdl
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/wsdl/hello_world.wsdl
------------------------------------------------------------------------------
svn:keywords = Rev Date
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch-wsdl/wsdl/hello_world.wsdl
------------------------------------------------------------------------------
svn:mime-type = text/xml
Added: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/README.txt
URL: http://svn.apache.org/viewvc/cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/README.txt?rev=696227&view=auto
==============================================================================
--- cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/README.txt (added)
+++ cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/README.txt Wed Sep 17 03:07:25 2008
@@ -0,0 +1,198 @@
+CXF INBOUND RESOURCE ADAPTER MESSAGE DRIVEN BEAN DISPATCHING SAMPLE
+===================================================================
+
+Please read the "Introduction to the inbound-mdb* Samples" section
+in the inbound-mdb/README.txt. It contains important information.
+
+
+MDB Invoking Session Bean
+-------------------------
+
+This sample shows the MDB invoked by the service endpoint facade, which
+dispatches the request to a targeted Stateless Session Bean. The
+Stateless Session Bean is where the service implementation resides. It is
+important to note that the targeted EJB must be a Stateless Session Bean.
+
+The MDB is a generic implementation. In fact, the default implementation
+is supplied by CXF JCA integration. The user does not have to write it.
+See in etc/ejb-jar.xml, the ejb-class for the MDB is
+org.apache.cxf.jca.inbound.DispatchMDBMessageListenerImpl. When this
+implementation class is specified, the messaging-type should be set to
+org.apache.cxf.jca.inbound.DispatchMDBMessageListener. Also, notice that
+the messagelistener-type in ra.xml matches the MDB's messaging-type.
+
+As you can see in etc/ra.xml file, the activation spec specified is
+org.apache.cxf.jca.inbound.DispatchMDBActivationSpec so that the target
+Session Bean's JNDI name can be specified.
+
+Like the inbound-mdb sample, this sample does not have a WSDL. CXF
+will use the service endpoint interface (Greeter) to build a service model
+as it is defined in the serviceInterfaceClass property in the etc/ejb-jar.xml.
+
+In ejb-jar.xml, you will notice that there is a ejb-local-ref, which is
+required for the MDB to lookup a Local EJB object (reference) of the target
+Session Bean. To use the dispatching function provided by
+org.apache.cxf.jca.inbound.DispatchMDBMessageListenerImpl, a ejb-local-ref
+must be defined in the ejb-jar.xml.
+
+The advantage of the approach is that users don't need to update the ra.xml
+in order to expose a new EJB as Web Service since the service endpoint
+interface is not exposed to the resource adapter's deployement descriptor.
+
+We also define a remote interface for the Session Bean (GreeterBean). It is
+completely optional. The remote interface is not accessed by the CXF JCA
+connector. Defining a remote interface would allow a EJB client to invoke
+the Session Bean from outside the application server.
+
+
+Building and running the sample using Ant
+-----------------------------------------
+From the base directory of this sample (i.e., where this README file is
+located), the Ant build.xml file can be used to build and run the sample.
+
+
+Build CXF J2C RAR file
+----------------------
+ (Unix) % ant generate.rar
+ (Windows) > ant generate.rar
+
+The result RAR file is located in build/lib/cxf.rar
+
+Launch the application server
+-----------------------------
+
+The sample requires an application server (WebSphere 6.1). Make sure
+you have a running instance of an application server.
+
+Deploy the CXF JCA Connector
+-----------------------------
+
+The CXF JCA Connector must be deployed to the application server before
+running the sample. The JCA Connector used in this sample can only be
+shared by the inbound-mdb-dispatch-wsdl sample. If you have deployed
+a CXF JCA Connector from that sample, you can skip the following steps
+and goto "Building Message Driven Bean Jar". Otherwise, please make sure
+there is no other CXF JCA Connector deployed into the application
+server.
+
+Please consult your vendor documentation on Resource Adapter deployment.
+Here are basic instructions to deploy the connector in WebSphere 6.1.
+
+1. Logon to WebSphere Integrated Solution Console. The default address is:
+
+ http://<hostname>:9060/ibm/console/login.do
+
+2. Navigate to tree menu: Resources -> Resource adapters -> Resource adapters
+
+3. On the Resource adapters page, click the "Install RAR" button.
+
+4. On the Install RAR File page, select the "Local path" radio button if this
+ sample is on the same machine as the WebSphere server. Otherwise, select
+ the "Server path" radio button. Specify or browse to the path
+ build/lib/cxf.rar file in this sample. Then, click the "Next" button.
+
+5. On the next page, click the "OK" button to install the Resource Adapter.
+
+6. On the next page, click the "CXF JCA Connector" link to edit the Resource
+ Adatper.
+
+7. On the "Configuration" page, click the "J2C activation specification"
+ link.
+
+8. On the next page, click the "New" button to create a new Activation
+ Specifications.
+
+9. On the next page, enter "MyActivationSpec" in the Name textbox and click
+ the "OK" button.
+
+ Notice that the JNDI name is optional. If it is omitted, a JNDI name
+ is created for you as eis/<ActivationSpecName> where <ActivationSpecName>
+ is "MyActivationSpec" above.
+
+10. Finally, click the "Save" link to commit the configuration.
+
+ Notice that you can specify activation config values in the new
+ activation spec you just created. The activation spec will be associated
+ to your MDB later. The MDB's deployment descriptor can define activation
+ config values to override the values specified in the associated activation
+ spec.
+
+
+Building Message Driven Bean Jar
+--------------------------------
+
+Issue the command:
+
+ (Unix) % ant
+ (Windows) > ant
+
+
+Deploying the Message Drive Bean
+--------------------------------
+
+Please consult your vendor documentation on EJB deployment. Here are
+basic instructions to deploy the MDB in WebSphere 6.1.
+
+1. Logon to WebSphere Integrated Solution Console. The default address is:
+
+ http://<hostname>:9060/ibm/console/login.do
+
+2. Navigate to tree menu: Applications -> Install new Applications
+
+3. On the "Preparing for the application installation" page, the select "Local
+ path" radio button if this sample is on the same machine as the WebSphere
+ server. Otherwise, select the "Server path" radio button. Specify or
+ browse to the path j2ee-archives/dispatchedgreeterejb.jar file in this
+ sample. Then, click the "Next" button.
+
+4. Click the "Next" button on the "Step 1: Select installation options" page.
+
+5. Click the "Next" button on the "Step 2: Map modules to servers" page.
+
+6. On the "Step 3: Bind listeners for message-driven beans" page, click the
+ "Activation Specification" radio button on the far right column. The
+ specify the Target Resource JNDI Name as below and the client the "Next"
+ button.
+
+ eis/MyActivationSpec
+
+7. On the "Step 4: Provide JNDI names for beans" page, enter
+ "ejb/DispatchedGreeterBean" then click the "Next" button.
+
+8. On the "Step 5: Map EJB references to beans" page, enter value below and
+ then click the "Next" button.
+
+ ejb/DispatchedGreeterBean
+
+9. On the "Step 6: Summary" page, click the "Finish" button.
+
+10. Click the "Save" link to commit the configuration.
+
+11. Navigate to tree menu: Applications -> Enterprise Applications
+
+12. Select the box next to "dispatchedgreeterejb_jar" and click the "Start"
+ button at the top to start the MDB. Make sure the "greeterejb_jar" is
+ not started since dispatchedgreeterejb_jar's facade endpoint will try
+ to bind to the same transport address.
+
+
+Running the Demo
+----------------
+
+Once the resource adapter and the EJB application have been deployed,
+the client can be run with the ant build script:
+
+ ant client
+
+This will launch an CXF Java Client which contacts the web service
+endpoint facade. The facade then invokes the MDB's message listener
+which is org.apache.cxf.jca.inbound.DispatchMDBMessageListenerImpl.
+The DispatchMDBMessageListenerImpl performs a JNDI lookup to obtain a
+EJBLocalObject reference to the target Stateless Session Bean that
+implements the Greater interface. The output from the Session Bean
+(GreeterBean) is returned to the client.
+
+The following output is observed from the client.
+
+client:
+ [java] server return: Hi CXF from an EJB
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/README.txt
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/README.txt
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/build.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/build.xml?rev=696227&view=auto
==============================================================================
--- cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/build.xml (added)
+++ cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/build.xml Wed Sep 17 03:07:25 2008
@@ -0,0 +1,116 @@
+<?xml version="1.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.
+-->
+
+<project name="Inbound Connection Demo" default="build" basedir=".">
+ <property environment="env"/>
+
+ <property environment="env"/>
+ <condition property="cxf.home" value="${env.CXF_HOME}">
+ <isset property="env.CXF_HOME"/>
+ </condition>
+
+ <fail message="this sample need to use CXF_HOME enviroment, please setup CXF_HOME in your environment" unless="cxf.home"/>
+
+ <property name="j2ee.resources.dir" location="${basedir}/../common/resources"/>
+ <property name="build.archives" value="${basedir}/j2ee-archives"/>
+ <property name="ejb.xml" location="./etc/ejb.xml"/>
+ <property name="j2ee.archives" value="j2ee-archives"/>
+ <property name="demos.current.dir" value="."/>
+ <property name="build.classes.dir" value="${basedir}/build"/>
+
+ <import file="../../../common_build.xml"/>
+
+
+ <path id="other.classpath">
+ <fileset dir="${cxf.home}/modules/integration" >
+ <include name="cxf-integration-jca-*.jar"/>
+ </fileset>
+ <pathelement location="${basedir}/../common/lib/geronimo-ejb_3.0_spec-1.0.1.jar"/>
+ </path>
+
+ <target name="init">
+ <mkdir dir="${build.classes.dir}/cxf-rar/META-INF"/>
+ <mkdir dir="${build.classes.dir}/lib"/>
+ <mkdir dir="${j2ee.archives}"/>
+ </target>
+
+ <target name="generate.rar" depends="init">
+ <copy file="${basedir}/etc/ra.xml" todir="${build.classes.dir}/cxf-rar/META-INF"/>
+ <copy todir="${build.classes.dir}/cxf-rar">
+ <fileset dir="${cxf.home}/lib">
+ <include name="*.jar"/>
+ <exclude name="cxf*.jar"/>
+ </fileset>
+ <fileset dir="${cxf.home}/modules">
+ <include name="*.jar"/>
+ <exclude name="*manifest*.jar"/>
+ </fileset>
+ <fileset dir="${cxf.home}/modules/integration">
+ <include name="*.jar"/>
+ <exclude name="*-jbi-*.jar"/>
+ </fileset>
+ </copy>
+ <jar destfile="${build.classes.dir}/lib/cxf.rar"
+ basedir="${build.classes.dir}/cxf-rar"/>
+ </target>
+
+ <target name="build" description="compile the code" depends="init,j2ee.compile,build.ejb.jar"/>
+
+ <target name="j2ee.compile">
+ <javac srcdir="${basedir}/src" destdir="${build.classes.dir}" debug="true" fork="yes">
+ <include name="**/*.java"/>
+ <classpath>
+ <pathelement location="${cxf.home}/modules/cxf-manifest.jar"/>
+ <pathelement location="${build.classes.dir}"/>
+ <path refid="cxf.classpath"/>
+ <path refid="other.classpath"/>
+ </classpath>
+ </javac>
+ </target>
+
+ <target name="clean">
+ <delete dir="${build.dir}"/>
+ <delete dir="${basedir}/j2ee-archives"/>
+ </target>
+
+ <target name="build.ejb.jar">
+ <jar destfile="${j2ee.archives}/dispatchedgreeterejb.jar">
+ <metainf dir="./etc">
+ <include name="*ejb*.xml"/>
+ </metainf>
+ <fileset dir="${build.classes.dir}/" includes="org/**/*.class"/>
+ <fileset dir="${build.classes.dir}">
+ <include name="**/ejb/*.class"/>
+ </fileset>
+ </jar>
+ </target>
+
+ <target name="client" description="run the client side demo " >
+ <java classname="demo.client.GreeterClient" fork="true">
+ <sysproperty key="java.util.logging.config.file" value="${cxf.home}/etc/logging.properties"/>
+ <arg value="${wsdl.location}"/>
+ <classpath>
+ <pathelement location="${build.classes.dir}"/>
+ <path refid="cxf.classpath"/>
+ </classpath>
+ </java>
+ </target>
+</project>
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/build.xml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/build.xml
------------------------------------------------------------------------------
svn:keywords = Rev Date
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/build.xml
------------------------------------------------------------------------------
svn:mime-type = text/xml
Added: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/etc/ejb-jar.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/etc/ejb-jar.xml?rev=696227&view=auto
==============================================================================
--- cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/etc/ejb-jar.xml (added)
+++ cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/etc/ejb-jar.xml Wed Sep 17 03:07:25 2008
@@ -0,0 +1,90 @@
+<?xml version="1.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.
+ -->
+<ejb-jar xmlns="http://java.sun.com/xml/ns/javaee"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
+ http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd"
+ version="3.0">
+
+ <enterprise-beans>
+ <session>
+ <ejb-name>DispatchedGreeterBean</ejb-name>
+ <home>demo.ejb.GreeterHome</home>
+ <remote>demo.ejb.GreeterRemote</remote>
+ <local-home>demo.ejb.GreeterLocalHome</local-home>
+ <local>demo.ejb.GreeterLocal</local>
+ <ejb-class>demo.ejb.GreeterBean</ejb-class>
+ <session-type>Stateless</session-type>
+ <transaction-type>Container</transaction-type>
+ </session>
+
+ <message-driven>
+ <ejb-name>GreeterEndpointActivator</ejb-name>
+ <ejb-class>org.apache.cxf.jca.inbound.DispatchMDBMessageListenerImpl</ejb-class>
+ <messaging-type>org.apache.cxf.jca.inbound.DispatchMDBMessageListener</messaging-type>
+ <transaction-type>Bean</transaction-type>
+
+ <activation-config>
+ <!-- display name-->
+ <activation-config-property>
+ <activation-config-property-name>
+ DisplayName
+ </activation-config-property-name>
+ <activation-config-property-value>
+ DispatchedGreeterEndpoint
+ </activation-config-property-value>
+ </activation-config-property>
+ <!-- service endpoint interface -->
+ <activation-config-property>
+ <activation-config-property-name>
+ serviceInterfaceClass
+ </activation-config-property-name>
+ <activation-config-property-value>
+ org.apache.hello_world_soap_http.Greeter
+ </activation-config-property-value>
+ </activation-config-property>
+ <!-- address -->
+ <activation-config-property>
+ <activation-config-property-name>
+ address
+ </activation-config-property-name>
+ <activation-config-property-value>
+ http://localhost:9999/GreeterBean
+ </activation-config-property-value>
+ </activation-config-property>
+ <!-- targetBeanJndiName -->
+ <activation-config-property>
+ <activation-config-property-name>
+ targetBeanJndiName
+ </activation-config-property-name>
+ <activation-config-property-value>
+ java:comp/env/DispatchedGreeterLocalHome
+ </activation-config-property-value>
+ </activation-config-property>
+ </activation-config>
+
+ <ejb-local-ref>
+ <ejb-ref-name>DispatchedGreeterLocalHome</ejb-ref-name>
+ <ejb-ref-type>Session</ejb-ref-type>
+ <local-home>demo.ejb.GreeterLocalHome</local-home>
+ <local>demo.ejb.GreeterLocal</local>
+ <ejb-link>DispatchedGreeterBean</ejb-link>
+ </ejb-local-ref>
+ </message-driven>
+
+ </enterprise-beans>
+</ejb-jar>
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/etc/ejb-jar.xml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/etc/ejb-jar.xml
------------------------------------------------------------------------------
svn:keywords = Rev Date
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/etc/ejb-jar.xml
------------------------------------------------------------------------------
svn:mime-type = text/xml
Added: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/etc/ra.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/etc/ra.xml?rev=696227&view=auto
==============================================================================
--- cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/etc/ra.xml (added)
+++ cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/etc/ra.xml Wed Sep 17 03:07:25 2008
@@ -0,0 +1,54 @@
+<?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.
+ -->
+<connector xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
+http://java/sun.com/xml/ns/j2ee/connector_1_5.xsd"
+ version="1.5">
+ <display-name>CXF JCA Connector</display-name>
+ <vendor-name>Apache CXF</vendor-name>
+ <eis-type>CXF</eis-type>
+ <resourceadapter-version>2.0</resourceadapter-version>
+ <license>
+ <license-required>false</license-required>
+ </license>
+ <resourceadapter>
+ <resourceadapter-class> org.apache.cxf.jca.cxf.ResourceAdapterImpl
+ </resourceadapter-class>
+ <inbound-resourceadapter>
+ <messageadapter>
+ <messagelistener>
+ <messagelistener-type>
+ org.apache.cxf.jca.inbound.DispatchMDBMessageListener
+ </messagelistener-type>
+ <activationspec>
+ <activationspec-class>
+ org.apache.cxf.jca.inbound.DispatchMDBActivationSpec
+ </activationspec-class>
+ <required-config-property>
+ <config-property-name>displayName
+ </config-property-name>
+ </required-config-property>
+ <required-config-property>
+ <config-property-name>targetBeanJndiName
+ </config-property-name>
+ </required-config-property>
+ </activationspec>
+ </messagelistener>
+ </messageadapter>
+ </inbound-resourceadapter>
+ </resourceadapter>
+</connector>
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/etc/ra.xml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/etc/ra.xml
------------------------------------------------------------------------------
svn:keywords = Rev Date
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/etc/ra.xml
------------------------------------------------------------------------------
svn:mime-type = text/xml
Added: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/demo/client/GreeterClient.java
URL: http://svn.apache.org/viewvc/cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/demo/client/GreeterClient.java?rev=696227&view=auto
==============================================================================
--- cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/demo/client/GreeterClient.java (added)
+++ cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/demo/client/GreeterClient.java Wed Sep 17 03:07:25 2008
@@ -0,0 +1,60 @@
+/**
+ * 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 demo.client;
+
+import java.net.InetAddress;
+import java.net.UnknownHostException;
+import javax.xml.namespace.QName;
+import org.apache.cxf.Bus;
+import org.apache.cxf.bus.spring.SpringBusFactory;
+import org.apache.cxf.jaxws.ServiceImpl;
+
+/**
+ * validate call to ejb in jboss from command line
+ */
+public final class GreeterClient {
+
+ protected GreeterClient() {
+ }
+
+ public static void main(String[] args) throws Exception {
+ Bus bus = new SpringBusFactory().getDefaultBus();
+ QName serviceQName = new QName("http://apache.org/hello_world_soap_http", "Greeter");
+ QName portQName = new QName("http://apache.org/hello_world_soap_http", "HelloPort");
+ String bindingId = "http://schemas.xmlsoap.org/soap/";
+
+ String hostName = "";
+ try {
+ InetAddress addr = InetAddress.getLocalHost();
+ hostName = addr.getCanonicalHostName();
+ } catch (UnknownHostException e) {
+ e.printStackTrace();
+ }
+
+ String address = "http://" + hostName + ":9999/GreeterBean";
+
+ ServiceImpl ss = new ServiceImpl(bus, null, serviceQName, null);
+ ss.addPort(portQName, bindingId, address);
+ org.apache.hello_world_soap_http.Greeter port = ss.getPort(portQName,
+ org.apache.hello_world_soap_http.Greeter.class);
+ String response = port.greetMe(" CXF");
+ System.out.println(" server return: " + response);
+ }
+}
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/demo/client/GreeterClient.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/demo/client/GreeterClient.java
------------------------------------------------------------------------------
svn:keywords = Rev Date
Added: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/demo/ejb/GreeterBean.java
URL: http://svn.apache.org/viewvc/cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/demo/ejb/GreeterBean.java?rev=696227&view=auto
==============================================================================
--- cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/demo/ejb/GreeterBean.java (added)
+++ cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/demo/ejb/GreeterBean.java Wed Sep 17 03:07:25 2008
@@ -0,0 +1,54 @@
+/**
+ * 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 demo.ejb;
+
+import javax.ejb.CreateException;
+import javax.ejb.SessionBean;
+import javax.ejb.SessionContext;
+
+public class GreeterBean implements SessionBean {
+
+ //------------- Business Methods
+ public String sayHi() {
+ System.out.println("sayHi invoked");
+ return "Hi from an EJB";
+ }
+
+ public String greetMe(String user) {
+ System.out.println("greetMe invoked user:" + user);
+ return "Hi " + user + " from an EJB";
+ }
+
+ //------------- EJB Methods
+ public void ejbActivate() {
+ }
+
+ public void ejbRemove() {
+ }
+
+ public void ejbPassivate() {
+ }
+
+ public void ejbCreate() throws CreateException {
+ }
+
+ public void setSessionContext(SessionContext con) {
+ }
+
+}
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/demo/ejb/GreeterBean.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/demo/ejb/GreeterBean.java
------------------------------------------------------------------------------
svn:keywords = Rev Date
Added: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/demo/ejb/GreeterHome.java
URL: http://svn.apache.org/viewvc/cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/demo/ejb/GreeterHome.java?rev=696227&view=auto
==============================================================================
--- cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/demo/ejb/GreeterHome.java (added)
+++ cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/demo/ejb/GreeterHome.java Wed Sep 17 03:07:25 2008
@@ -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 demo.ejb;
+
+import java.rmi.RemoteException;
+import javax.ejb.CreateException;
+import javax.ejb.EJBHome;
+
+public interface GreeterHome extends EJBHome {
+ GreeterRemote create() throws CreateException, RemoteException;
+}
+
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/demo/ejb/GreeterHome.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: cxf/trunk/distribution/src/main/release/samples/integration/jca/inbound-mdb-dispatch/src/demo/ejb/GreeterHome.java
------------------------------------------------------------------------------
svn:keywords = Rev Date