[jboss-svn-commits] JBL Code SVN: r28016 - in labs/jbossesb/trunk/product: samples/quickstarts and 70 other directories.
jboss-svn-commits at lists.jboss.org
jboss-svn-commits at lists.jboss.org
Tue Jul 14 14:32:15 EDT 2009
Author: dward
Date: 2009-07-14 14:32:14 -0400 (Tue, 14 Jul 2009)
New Revision: 28016
Added:
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/build.xml
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/deployment.xml
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/jboss-esb.xml
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/lib/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/log4j.xml
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/readme.txt
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/src/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/src/org/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/src/org/jboss/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/src/org/jboss/soa/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/src/org/jboss/soa/esb/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/src/org/jboss/soa/esb/samples/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/src/org/jboss/soa/esb/samples/quickstart/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_basic/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_basic/test/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_basic/test/SendWSMessage.java
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/lib/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/lib/ext/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/resources/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/resources/WEB-INF/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/resources/WEB-INF/classes/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/resources/WEB-INF/lib/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/resources/WEB-INF/web.xml
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/src/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/src/org/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/src/org/jboss/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/src/org/jboss/soa/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/src/org/jboss/soa/esb/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/src/org/jboss/soa/esb/samples/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/src/org/jboss/soa/esb/samples/quickstart/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_basic/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_basic/HelloWorldWS.java
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/view/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/view/index.jsp
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/Proxy_Routed_Rules.drl
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/build.xml
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/deployment.xml
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/jbm-queue-service.xml
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/jbmq-queue-service.xml
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/jboss-esb.xml
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/lib/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/log4j.xml
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/readme.txt
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/src/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/src/org/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/src/org/jboss/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/src/org/jboss/soa/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/src/org/jboss/soa/esb/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/src/org/jboss/soa/esb/samples/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/src/org/jboss/soa/esb/samples/quickstart/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_routed/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_routed/test/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_routed/test/SendWSMessage.java
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/lib/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/lib/ext/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/resources/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/resources/WEB-INF/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/resources/WEB-INF/classes/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/resources/WEB-INF/lib/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/resources/WEB-INF/web.xml
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/src/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/src/org/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/src/org/jboss/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/src/org/jboss/soa/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/src/org/jboss/soa/esb/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/src/org/jboss/soa/esb/samples/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/src/org/jboss/soa/esb/samples/quickstart/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_routed/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_routed/GoodbyeWS.java
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_routed/HelloWS.java
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/view/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/view/index.jsp
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/Proxy_Versioning_RequestTransform.xsl
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/Proxy_Versioning_WsdlTransform.xml
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/build.xml
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/deployment.xml
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/jboss-esb.xml
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/lib/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/log4j.xml
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/readme.txt
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/src/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/src/org/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/src/org/jboss/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/src/org/jboss/soa/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/src/org/jboss/soa/esb/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/src/org/jboss/soa/esb/samples/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/src/org/jboss/soa/esb/samples/quickstart/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_versioning/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_versioning/test/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_versioning/test/SendWSMessage.java
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/lib/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/lib/ext/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/resources/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/resources/WEB-INF/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/resources/WEB-INF/classes/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/resources/WEB-INF/lib/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/resources/WEB-INF/web.xml
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/src/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/src/org/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/src/org/jboss/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/src/org/jboss/soa/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/src/org/jboss/soa/esb/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/src/org/jboss/soa/esb/samples/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/src/org/jboss/soa/esb/samples/quickstart/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_versioning/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_versioning/InvoicingWS.java
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/view/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/view/index.jsp
Removed:
labs/jbossesb/trunk/product/samples/quickstarts/webservice_wsproxy_basic/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_wsproxy_routed/
labs/jbossesb/trunk/product/samples/quickstarts/webservice_wsproxy_versioning/
Modified:
labs/jbossesb/trunk/product/docs/ProgrammersGuide.odt
labs/jbossesb/trunk/product/services/soap/src/main/java/org/jboss/soa/esb/actions/soap/proxy/SOAPProxy.java
Log:
Task completion for https://jira.jboss.org/jira/browse/JBESB-2746
Modified: labs/jbossesb/trunk/product/docs/ProgrammersGuide.odt
===================================================================
(Binary files differ)
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/build.xml
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/build.xml (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/build.xml 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,83 @@
+<project name="Quickstart_webservice_proxy_basic" default="deploy" basedir=".">
+
+ <description>
+ ${ant.project.name}
+ ${line.separator}
+ </description>
+
+ <!-- Import the base Ant build script... -->
+ <import file="../conf/base-build.xml"/>
+
+ <property name="war.build.dir" location="${build.dir}/war/classes"/>
+
+ <target name="quickstart-specific-checks" depends="assert-ws-available"/>
+
+ <target name="quickstart-specific-assemblies" depends="makewar"/>
+
+ <target name="quickstart-specific-predeploys">
+ <copy todir="${org.jboss.esb.server.deploy.dir}"
+ file="build/predeploy/${ant.project.name}.war"/>
+ <sleep seconds="3"/>
+ </target>
+
+ <target name="quickstart-specific-undeploys">
+ <delete file="${org.jboss.esb.server.deploy.dir}/${ant.project.name}.war"/>
+ </target>
+
+ <target name="makewar" description="make war">
+ <!-- Compile... -->
+ <mkdir dir="${war.build.dir}" />
+ <javac srcdir="war/src" destdir="${war.build.dir}" debug="true">
+ <classpath>
+ <path refid="compile-classpath" />
+ <fileset dir="war/lib/ext" includes="*.jar" />
+ </classpath>
+ </javac>
+
+ <!-- War... -->
+ <mkdir dir="build/predeploy"/>
+ <war warfile="build/predeploy/${ant.project.name}.war"
+ webxml="${basedir}/war/resources/WEB-INF/web.xml">
+ <webinf dir="${basedir}/war/resources/WEB-INF">
+ <include name="jboss-web.xml"/>
+ </webinf>
+ <classes dir="${war.build.dir}" includes="**/*.class"/>
+ <fileset dir="${basedir}/war/view">
+ <include name="**/*"/>
+ </fileset>
+ <classes dir="${basedir}">
+ <include name="juddi.properties"/>
+ </classes>
+ </war>
+ </target>
+
+ <target name="quickstart-specific-clean">
+ <delete file="${basedir}/listener.log"/>
+ </target>
+
+ <target name="run">
+ <echo>standalone mode is not available for this quickstart.</echo>
+ </target>
+
+ <target name="runinternal" depends="compile">
+ <java fork="yes" classname="org.jboss.soa.esb.samples.quickstart.webservice_proxy_basic.test.SendWSMessage" failonerror="true">
+ <arg value="${runtest.arg.url}"/>
+ <arg value="${user.name}"/>
+ <classpath refid="exec-classpath"/>
+ </java>
+ </target>
+
+ <target name="runws">
+ <echo>Calling JBossWS webservice directly.</echo>
+ <property name="runtest.arg.url" value="http://localhost:8080/Quickstart_webservice_proxy_basic/HelloWorldWS"/>
+ <antcall target="runinternal"/>
+ </target>
+
+ <target name="runjbr">
+ <echo>Calling JBossWS webservice via JBossRemotingGatewayListener and SOAPProxy.</echo>
+ <property name="runtest.arg.url" value="http://localhost:9090"/>
+ <antcall target="runinternal"/>
+ </target>
+ <target name="runtest" depends="runjbr"/>
+
+</project>
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/build.xml
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/deployment.xml
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/deployment.xml (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/deployment.xml 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,4 @@
+<jbossesb-deployment>
+ <depends>jboss.esb:deployment=soap.esb</depends>
+</jbossesb-deployment>
+
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/deployment.xml
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/jboss-esb.xml
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/jboss-esb.xml (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/jboss-esb.xml 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<jbossesb xmlns="http://anonsvn.labs.jboss.com/labs/jbossesb/trunk/product/etc/schemas/xml/jbossesb-1.1.0.xsd" parameterReloadSecs="5">
+
+ <providers>
+ <jbr-provider name="JBR-PROVIDER" protocol="http" host="localhost">
+ <jbr-bus busid="JBR-BUS" port="9090"/>
+ </jbr-provider>
+ </providers>
+
+ <services>
+ <service category="Proxy_Basic" name="Proxy"
+ description="Basic WebService Proxy"
+ invmScope="GLOBAL" >
+ <listeners>
+ <jbr-listener name="JBR-GATEWAY"
+ busidref="JBR-BUS"
+ is-gateway="true"
+ />
+ </listeners>
+ <actions mep="RequestResponse">
+ <action name="echo-request"
+ class="org.jboss.soa.esb.actions.SystemPrintln">
+ <property name="message" value="Message before SOAPProxy" />
+ </action>
+ <action name="proxy"
+ class="org.jboss.soa.esb.actions.soap.proxy.SOAPProxy">
+ <property name="wsdl" value="http://localhost:8080/Quickstart_webservice_proxy_basic/HelloWorldWS?wsdl"/>
+ </action>
+ <action name="echo-response"
+ class="org.jboss.soa.esb.actions.SystemPrintln">
+ <property name="message" value="Message after SOAPProxy" />
+ </action>
+ </actions>
+ </service>
+ </services>
+
+</jbossesb>
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/jboss-esb.xml
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/log4j.xml
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/log4j.xml (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/log4j.xml 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
+
+<!-- ===================================================================== -->
+<!-- -->
+<!-- Log4j Configuration -->
+<!-- -->
+<!-- ===================================================================== -->
+
+<!-- $Id$ -->
+
+<!--
+ | For more configuration infromation and examples see the Jakarta Log4j
+ | owebsite: http://jakarta.apache.org/log4j
+ -->
+
+<log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/" debug="false">
+
+ <!-- ============================== -->
+ <!-- Append messages to the console -->
+ <!-- ============================== -->
+
+ <appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
+ <errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/>
+ <param name="Target" value="System.out"/>
+
+ <layout class="org.apache.log4j.PatternLayout">
+ <!-- The default pattern: Date Priority [Category] Message\n -->
+ <param name="ConversionPattern" value="%d{ABSOLUTE} %-5p [%t][%c{1}] %m%n"/>
+ </layout>
+ </appender>
+
+ <!-- ================================= -->
+ <!-- Preserve messages in a local file -->
+ <!-- ================================= -->
+
+ <!-- A size based file rolling appender -->
+ <appender name="FILE" class="org.jboss.logging.appender.RollingFileAppender">
+ <errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/>
+ <param name="File" value="./listener.log"/>
+ <param name="Append" value="false"/>
+ <param name="MaxFileSize" value="500KB"/>
+ <param name="MaxBackupIndex" value="1"/>
+
+ <layout class="org.apache.log4j.PatternLayout">
+ <param name="ConversionPattern" value="%d %-5p [%t][%c] %m%n"/>
+ </layout>
+ </appender>
+
+ <!-- ================ -->
+ <!-- Limit categories -->
+ <!-- ================ -->
+
+ <category name="org.jboss">
+ <priority value="WARN"/>
+ </category>
+ <category name="org.jboss.soa.esb">
+ <priority value="ERROR"/>
+ </category>
+ <category name="org.jboss.internal.soa.esb">
+ <priority value="ERROR"/>
+ </category>
+ <category name="org.apache">
+ <priority value="ERROR"/>
+ </category>
+ <category name="quickstart">
+ <priority value="INFO"/>
+ </category>
+ <!-- ======================= -->
+ <!-- Setup the Root category -->
+ <!-- ======================= -->
+
+ <root>
+ <appender-ref ref="CONSOLE"/>
+ <appender-ref ref="FILE"/>
+ </root>
+
+</log4j:configuration>
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/log4j.xml
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/readme.txt
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/readme.txt (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/readme.txt 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,103 @@
+Overview:
+=========
+ Consumption of an external WS endpoint.
+
+Running this quickstart:
+========================
+ Please refer to 'ant help-quickstarts' for prerequisites about the quickstarts
+ and a more detailed descripton of the different ways to run the quickstarts.
+
+To Run:
+===========================
+ 1. In a command terminal window in this folder ("Window1"), type 'ant deploy'.
+ - In your server console, you will see output like this:
+
+01:18:45,517 INFO [SOAPProxy] mapped soapaction [""] to binding [{http://webservice_proxy_basic/helloworld}HelloWorldBinding]
+01:18:45,518 INFO [SOAPProxy] mapped operation [{http://webservice_proxy_basic/helloworld}sayHello] to binding [{http://webservice_proxy_basic/helloworld}HelloWorldBinding]
+01:18:45,518 INFO [SOAPProxy] mapped binding [{http://webservice_proxy_basic/helloworld}HelloWorldBinding] to transport [org.jboss.soa.esb.actions.soap.proxy.HttpSOAPProxyTransport] with endpoint address: [http://localhost:8080/Quickstart_webservice_proxy_basic/HelloWorldWS]
+
+ 2. Open another command terminal window in this folder ("Window2"), type
+ 'ant runtest'.
+
+ 3. Switch back to Application Server console to see the output from the ESB
+
+ 4. In this folder ("Window1"), type 'ant undeploy'.
+
+ 'runws' target description:
+ - This simply calls the target JBossWS webservice directly.
+ - The request url is: http://localhost:8080/Quickstart_webservice_proxy_basic/HelloWorldWS
+ - Running it will create output similar to the runjbr output below.
+
+ 'runjbr' (alias 'runtest') target description:
+ - This will exercise the target webservice *via* the SOAPProxy, first going
+ through a JBoss Remoting Gateway Listener.
+ - The request url is: http://localhost:9090
+ - Running it will create output like this in the server console:
+
+01:19:15,983 INFO [STDOUT] Message before SOAPProxy:
+01:19:15,983 INFO [STDOUT] [<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:hello="http://webservice_proxy_basic/helloworld"><soapenv:Header/><soapenv:Body><hello:sayHello><toWhom>dward</toWhom></hello:sayHello></soapenv:Body></soapenv:Envelope>].
+01:19:15,993 INFO [STDOUT] Message after SOAPProxy:
+01:19:15,993 INFO [STDOUT] [<env:Envelope xmlns:env='http://schemas.xmlsoap.org/soap/envelope/'><env:Header></env:Header><env:Body><ns2:sayHelloResponse xmlns:ns2="http://webservice_proxy_basic/helloworld"><return>Hello 'dward' on Mon Jul 06 01:19:15 GMT-05:00 2009</return></ns2:sayHelloResponse></env:Body></env:Envelope>].
+
+ ...and this in the client console:
+
+ [java] **** REQUEST URL: http://localhost:9090
+ [java] **** REQUEST BODY: <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:hello="http://webservice_proxy_basic/helloworld"><soapenv:Header/><soapenv:Body><hello:sayHello><toWhom>dward</toWhom></hello:sayHello></soapenv:Body></soapenv:Envelope>
+ [java] 01:19:15,946 DEBUG [main][header] >> "POST / HTTP/1.1[\r][\n]"
+ [java] 01:19:15,978 DEBUG [main][header] >> "Content-Type: text/xml;charset=UTF-8[\r][\n]"
+ [java] 01:19:15,978 DEBUG [main][header] >> "SOAPAction: ""[\r][\n]"
+ [java] 01:19:15,979 DEBUG [main][header] >> "User-Agent: Jakarta Commons-HttpClient/3.0.1[\r][\n]"
+ [java] 01:19:15,979 DEBUG [main][header] >> "Host: localhost:9090[\r][\n]"
+ [java] 01:19:15,979 DEBUG [main][header] >> "Content-Length: 253[\r][\n]"
+ [java] 01:19:15,980 DEBUG [main][header] >> "[\r][\n]"
+ [java] 01:19:15,980 DEBUG [main][content] >> "<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:hello="http://webservice_proxy_basic/helloworld"><soapenv:Header/><soapenv:Body><hello:sayHello><toWhom>dward</toWhom></hello:sayHello></soapenv:Body></soapenv:Envelope>"
+ [java] 01:19:15,994 DEBUG [main][header] << "HTTP/1.1 200 OK[\r][\n]"
+ [java] 01:19:15,995 DEBUG [main][header] << "Server: Apache-Coyote/1.1[\r][\n]"
+ [java] 01:19:15,996 DEBUG [main][header] << "X-Powered-By: Servlet 2.4; JBoss-4.2.3.GA (build: SVNTag=JBoss_4_2_3_GA date=200807181417)/JBossWeb-2.0[\r][\n]"
+ [java] 01:19:15,996 DEBUG [main][header] << "Date: Mon, 06 Jul 2009 06:19:15 GMT[\r][\n]"
+ [java] 01:19:15,996 DEBUG [main][header] << "Content-Type: text/xml;charset=UTF-8[\r][\n]"
+ [java] 01:19:15,996 DEBUG [main][header] << "Content-Length: 297[\r][\n]"
+ [java] **** RESPONSE CODE: 200
+ [java] 01:19:16,000 DEBUG [main][content] << "<env:Envelope xmlns:env='http://schemas.xmlsoap.org/soap/envelope/'><env:Header></env:Header><env:Body><ns2:sayHelloResponse xmlns:ns2="http://webservice_proxy_basic/helloworld"><return>Hello 'dward' on Mon Jul 06 01:19:15 GMT-05:00 2009</return></ns2:sa"
+ [java] 01:19:16,000 DEBUG [main][content] << "yHelloResponse></env:Body></env:Envelope>"
+ [java] **** RESPONSE BODY: <env:Envelope xmlns:env='http://schemas.xmlsoap.org/soap/envelope/'><env:Header></env:Header><env:Body><ns2:sayHelloResponse xmlns:ns2="http://webservice_proxy_basic/helloworld"><return>Hello 'dward' on Mon Jul 06 01:19:15 GMT-05:00 2009</return></ns2:sayHelloResponse></env:Body></env:Envelope>
+
+
+Project file descriptions:
+==========================
+ jboss-esb.xml:
+ A JBoss Remoting Gateway Listener accepts the incoming HTTP call makes it available to the
+ Proxy_Basic/Proxy service, who has a message exchange pattern of RequestResponse. In the
+ action chain, there are 3 actions:
+ 1) echo out the incoming SOAP request,
+ 2) use the SOAPProxy class to invoke the original webservice endpoint,
+ 3) echo out the outgoing SOAP response.
+ Configuration:
+ - wsdl (required): The original wsdl url whose WS endpoint will get re-written and exposed as
+ new wsdl from the ESB:
+ http://localhost:8080/contract/contract.jsp?serviceCat=Proxy_Basic&serviceName=Proxy&protocol=http
+ Depending upon the <definitions><service><port><soap:address location attribute's protocol
+ (for example "http"), a protocol-specific SOAPProxyTransport implementation is used.
+ For other possible configuration properties, see the specific SOAPProxyTransport implementations
+ themselves.
+
+ log4j.xml:
+ Needed to configure log4J used by the quickstart.
+
+ src/../SendWSMessage.java:
+ Sends a SOAP message to the target webservice endpoint (see "ant run*" above).
+
+ build.xml:
+ Targets and structure description:
+
+ * the runws task calls the
+ org.jboss.soa.esb.samples.quickstart.webservice_proxy_basic.test.SendWSMessage class and
+ passes in and argument representing the *ORIGINAL* webservice endpoint
+ and an argument representing the string-based message to invoke the webservice with.
+
+ * the runjbr (also runtest) task calls the
+ org.jboss.soa.esb.samples.quickstart.webservice_proxy_basic.test.SendWSMessage class and
+ passes in and argument representing the *PROXIED* webservice endpoint (via JBoss Remoting)
+ and an argument representing the string-based message to invoke the webservice with.
+
+
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/readme.txt
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_basic/test/SendWSMessage.java
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_basic/test/SendWSMessage.java (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_basic/test/SendWSMessage.java 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,98 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, JBoss Inc., and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+ * PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
+ * You should have received a copy of the GNU Lesser General Public License,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ *
+ * (C) 2005-2009
+ */
+package org.jboss.soa.esb.samples.quickstart.webservice_proxy_basic.test;
+
+import java.io.InputStream;
+
+import org.apache.commons.httpclient.HttpClient;
+import org.apache.commons.httpclient.methods.PostMethod;
+import org.apache.commons.httpclient.methods.StringRequestEntity;
+import org.jboss.internal.soa.esb.util.StreamUtils;
+
+/**
+ * Sends a simple webservice request to the proxied webservice, printing both the request and the response to the console.
+ *
+ * @author dward at jboss.org
+ */
+public class SendWSMessage
+{
+
+ private static final String SOAP_PRE =
+ "<soapenv:Envelope xmlns:soapenv=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:hello=\"http://webservice_proxy_basic/helloworld\">" +
+ "<soapenv:Header/>" +
+ "<soapenv:Body>" +
+ "<hello:sayHello>" +
+ "<toWhom>";
+
+ private static final String SOAP_POST =
+ "</toWhom>" +
+ "</hello:sayHello>" +
+ "</soapenv:Body>" +
+ "</soapenv:Envelope>";
+
+ // see product/samples/quickstarts/webservice_proxy_basic/build.xml
+ public static void main(String... args) throws Exception
+ {
+ if (args.length < 2)
+ {
+ // for testing main method from Eclipse (build.xml passes these args in)
+ args = new String[2];
+ //args[0] = "http://localhost:8080/Quickstart_webservice_proxy_basic/HelloWorldWS"; // original ws ("ant runws")
+ args[0] = "http://localhost:9090"; // proxy via jbr gateway ("ant runjbr" or "ant runtest")
+ //args[0] = "http://localhost:9999/Proxy_Basic/HelloWorldWS/"; // proxy via http gateway ("ant runhttp")
+ args[1] = System.getProperty("user.name");
+ }
+
+ String url = args[0];
+ System.out.println("**** REQUEST URL: " + url);
+ PostMethod method = new PostMethod(url);
+ method.setRequestHeader("Content-Type", "text/xml;charset=UTF-8");
+
+ // this line should be used for better performance/interop but is not necessary
+ // http://www.w3.org/TR/2000/NOTE-SOAP-20000508/#_Toc478383528
+ // http://www.ws-i.org/Profiles/BasicProfile-1.1.html#SOAPAction_HTTP_Header
+ method.setRequestHeader("SOAPAction", "\"\"");
+
+ String request = SOAP_PRE + args[1] + SOAP_POST;
+ System.out.println("**** REQUEST BODY: " + request);
+ method.setRequestEntity( new StringRequestEntity(request) );
+
+ HttpClient client = new HttpClient();
+ InputStream response = null;
+ try
+ {
+ int code = client.executeMethod(method);
+ System.out.println("**** RESPONSE CODE: " + code);
+
+ response = method.getResponseBodyAsStream();
+ byte[] bytes = StreamUtils.readStream(response);
+ System.out.println("**** RESPONSE BODY: " + new String(bytes, method.getResponseCharSet()));
+ }
+ finally
+ {
+ method.releaseConnection();
+ if (response != null)
+ {
+ response.close();
+ }
+ }
+ }
+
+}
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_basic/test/SendWSMessage.java
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/resources/WEB-INF/web.xml
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/resources/WEB-INF/web.xml (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/resources/WEB-INF/web.xml 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+
+<web-app 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/web-app_2_4.xsd" version="2.4">
+ <servlet>
+ <servlet-name>HelloWorldWS</servlet-name>
+ <servlet-class>org.jboss.soa.esb.samples.quickstart.webservice_proxy_basic.HelloWorldWS</servlet-class>
+ </servlet>
+
+ <servlet-mapping>
+ <servlet-name>HelloWorldWS</servlet-name>
+ <url-pattern>/HelloWorldWS</url-pattern>
+ </servlet-mapping>
+
+</web-app>
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/resources/WEB-INF/web.xml
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_basic/HelloWorldWS.java
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_basic/HelloWorldWS.java (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_basic/HelloWorldWS.java 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,41 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, JBoss Inc., and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+ * PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
+ * You should have received a copy of the GNU Lesser General Public License,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ *
+ * (C) 2005-2009
+ */
+package org.jboss.soa.esb.samples.quickstart.webservice_proxy_basic;
+
+import javax.jws.WebMethod;
+import javax.jws.WebParam;
+import javax.jws.WebService;
+
+/**
+ * Simple rpc-style webservice that returns a hello greeting (using the passed-in name) and the current date.
+ *
+ * @author dward at jboss.org
+ */
+ at WebService(name = "HelloWorld", targetNamespace = "http://webservice_proxy_basic/helloworld")
+public class HelloWorldWS
+{
+
+ @WebMethod
+ public String sayHello(@WebParam(name = "toWhom") String toWhom)
+ {
+ return "Hello '" + toWhom + "' on " + new java.util.Date();
+ }
+
+}
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_basic/HelloWorldWS.java
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/view/index.jsp
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/view/index.jsp (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/view/index.jsp 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,9 @@
+<html>
+ <body>
+ This is just a place holder.<br>
+ Verify the that the WS has been deployed by hitting
+ <a href="http://localhost:8080/jbossws">
+ http://localhost:8080/jbossws
+ </a>
+ </body>
+</html>
\ No newline at end of file
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_basic/war/view/index.jsp
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/Proxy_Routed_Rules.drl
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/Proxy_Routed_Rules.drl (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/Proxy_Routed_Rules.drl 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,26 @@
+package com.jboss.soa.esb.routing.cbr
+
+import org.jboss.soa.esb.message.Message;
+import org.jboss.soa.esb.message.format.MessageType;
+
+expander XPathLanguage.dsl
+
+global java.util.List destinations;
+
+rule "Hello Routing Rule"
+
+ when
+ xpathMatch expr "/soapenv:Envelope/soapenv:Body/hello:sayHello" use namespaces "soapenv=http://schemas.xmlsoap.org/soap/envelope/,hello=http://webservice_proxy_routed/hello"
+ then
+ Log : "Routing to Hello...";
+ Destination : "hello";
+
+end
+
+rule "Goodbye Routing Rule"
+ when
+ xpathMatch expr "/soapenv:Envelope/soapenv:Body/goodbye:sayGoodbye" use namespaces "soapenv=http://schemas.xmlsoap.org/soap/envelope/,goodbye=http://webservice_proxy_routed/goodbye"
+ then
+ Log : "Routing to Goodbye...";
+ Destination : "goodbye";
+end
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/Proxy_Routed_Rules.drl
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/build.xml
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/build.xml (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/build.xml 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,88 @@
+<project name="Quickstart_webservice_proxy_routed" default="deploy" basedir=".">
+
+ <description>
+ ${ant.project.name}
+ ${line.separator}
+ </description>
+
+ <property name="additional.deploys" value="Proxy_Routed_Rules.drl"/>
+
+ <!-- Import the base Ant build script... -->
+ <import file="../conf/base-build.xml"/>
+
+ <property name="war.build.dir" location="${build.dir}/war/classes"/>
+
+ <target name="quickstart-specific-checks" depends="assert-ws-available"/>
+
+ <target name="quickstart-specific-assemblies" depends="makewar"/>
+
+ <target name="quickstart-specific-predeploys">
+ <copy todir="${org.jboss.esb.server.deploy.dir}"
+ file="build/predeploy/${ant.project.name}.war"/>
+ <sleep seconds="3"/>
+ </target>
+
+ <target name="quickstart-specific-undeploys">
+ <delete file="${org.jboss.esb.server.deploy.dir}/${ant.project.name}.war"/>
+ </target>
+
+ <target name="makewar" description="make war">
+ <!-- Compile... -->
+ <mkdir dir="${war.build.dir}" />
+ <javac srcdir="war/src" destdir="${war.build.dir}" debug="true">
+ <classpath>
+ <path refid="compile-classpath" />
+ <fileset dir="war/lib/ext" includes="*.jar" />
+ </classpath>
+ </javac>
+
+ <!-- War... -->
+ <mkdir dir="build/predeploy"/>
+ <war warfile="build/predeploy/${ant.project.name}.war"
+ webxml="${basedir}/war/resources/WEB-INF/web.xml">
+ <webinf dir="${basedir}/war/resources/WEB-INF">
+ <include name="jboss-web.xml"/>
+ </webinf>
+ <classes dir="${war.build.dir}" includes="**/*.class"/>
+ <fileset dir="${basedir}/war/view">
+ <include name="**/*"/>
+ </fileset>
+ <classes dir="${basedir}">
+ <include name="juddi.properties"/>
+ </classes>
+ </war>
+ </target>
+
+ <target name="quickstart-specific-clean">
+ <delete file="${basedir}/listener.log"/>
+ </target>
+
+ <target name="run">
+ <echo>standalone mode is not available for this quickstart.</echo>
+ </target>
+
+ <target name="runinternal" depends="compile">
+ <java fork="yes" classname="org.jboss.soa.esb.samples.quickstart.webservice_proxy_routed.test.SendWSMessage" failonerror="true">
+ <arg value="${runtest.arg.url}"/>
+ <arg value="${user.name}"/>
+ <arg value="${runtest.arg.msg}"/>
+ <classpath refid="exec-classpath"/>
+ </java>
+ </target>
+
+ <target name="runhello">
+ <echo>Calling hello JBossWS webservice via JBossRemotingGatewayListener and SOAPProxy.</echo>
+ <property name="runtest.arg.url" value="http://localhost:9090"/>
+ <property name="runtest.arg.msg" value="hello"/>
+ <antcall target="runinternal"/>
+ </target>
+ <target name="runtest" depends="runhello"/>
+
+ <target name="rungoodbye">
+ <echo>Calling goodbye JBossWS webservice via JBossRemotingGatewayListener and SOAPProxy.</echo>
+ <property name="runtest.arg.url" value="http://localhost:9090"/>
+ <property name="runtest.arg.msg" value="goodbye"/>
+ <antcall target="runinternal"/>
+ </target>
+
+</project>
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/build.xml
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/deployment.xml
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/deployment.xml (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/deployment.xml 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,10 @@
+<jbossesb-deployment>
+ <depends>jboss.esb:deployment=soap.esb</depends>
+ <depends>jboss.esb:deployment=jbrules.esb</depends>
+ <depends>jboss.esb.quickstart.destination:service=Queue,name=quickstart_webservice_proxy_routed_cbr_esb</depends>
+ <depends>jboss.esb.quickstart.destination:service=Queue,name=quickstart_webservice_proxy_routed_cbr_esb_reply</depends>
+ <depends>jboss.esb.quickstart.destination:service=Queue,name=quickstart_webservice_proxy_routed_hello_esb</depends>
+ <depends>jboss.esb.quickstart.destination:service=Queue,name=quickstart_webservice_proxy_routed_hello_esb_reply</depends>
+ <depends>jboss.esb.quickstart.destination:service=Queue,name=quickstart_webservice_proxy_routed_goodbye_esb_reply</depends>
+</jbossesb-deployment>
+
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/deployment.xml
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/jbm-queue-service.xml
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/jbm-queue-service.xml (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/jbm-queue-service.xml 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,39 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<server>
+ <mbean code="org.jboss.jms.server.destination.QueueService"
+ name="jboss.esb.quickstart.destination:service=Queue,name=quickstart_webservice_proxy_routed_cbr_esb"
+ xmbean-dd="xmdesc/Queue-xmbean.xml">
+ <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
+ <depends>jboss.messaging:service=PostOffice</depends>
+ </mbean>
+ <mbean code="org.jboss.jms.server.destination.QueueService"
+ name="jboss.esb.quickstart.destination:service=Queue,name=quickstart_webservice_proxy_routed_cbr_esb_reply"
+ xmbean-dd="xmdesc/Queue-xmbean.xml">
+ <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
+ <depends>jboss.messaging:service=PostOffice</depends>
+ </mbean>
+ <mbean code="org.jboss.jms.server.destination.QueueService"
+ name="jboss.esb.quickstart.destination:service=Queue,name=quickstart_webservice_proxy_routed_hello_esb"
+ xmbean-dd="xmdesc/Queue-xmbean.xml">
+ <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
+ <depends>jboss.messaging:service=PostOffice</depends>
+ </mbean>
+ <mbean code="org.jboss.jms.server.destination.QueueService"
+ name="jboss.esb.quickstart.destination:service=Queue,name=quickstart_webservice_proxy_routed_hello_esb_reply"
+ xmbean-dd="xmdesc/Queue-xmbean.xml">
+ <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
+ <depends>jboss.messaging:service=PostOffice</depends>
+ </mbean>
+ <mbean code="org.jboss.jms.server.destination.QueueService"
+ name="jboss.esb.quickstart.destination:service=Queue,name=quickstart_webservice_proxy_routed_goodbye_esb"
+ xmbean-dd="xmdesc/Queue-xmbean.xml">
+ <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
+ <depends>jboss.messaging:service=PostOffice</depends>
+ </mbean>
+ <mbean code="org.jboss.jms.server.destination.QueueService"
+ name="jboss.esb.quickstart.destination:service=Queue,name=quickstart_webservice_proxy_routed_goodbye_esb_reply"
+ xmbean-dd="xmdesc/Queue-xmbean.xml">
+ <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
+ <depends>jboss.messaging:service=PostOffice</depends>
+ </mbean>
+</server>
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/jbm-queue-service.xml
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/jbmq-queue-service.xml
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/jbmq-queue-service.xml (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/jbmq-queue-service.xml 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,39 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<server>
+ <mbean code="org.jboss.mq.server.jmx.Queue"
+ name="jboss.esb.quickstart.destination:service=Queue,name=quickstart_webservice_proxy_routed_cbr_esb">
+ <depends optional-attribute-name="DestinationManager">
+ jboss.mq:service=DestinationManager
+ </depends>
+ </mbean>
+ <mbean code="org.jboss.mq.server.jmx.Queue"
+ name="jboss.esb.quickstart.destination:service=Queue,name=quickstart_webservice_proxy_routed_cbr_esb_reply">
+ <depends optional-attribute-name="DestinationManager">
+ jboss.mq:service=DestinationManager
+ </depends>
+ </mbean>
+ <mbean code="org.jboss.mq.server.jmx.Queue"
+ name="jboss.esb.quickstart.destination:service=Queue,name=quickstart_webservice_proxy_routed_hello_esb">
+ <depends optional-attribute-name="DestinationManager">
+ jboss.mq:service=DestinationManager
+ </depends>
+ </mbean>
+ <mbean code="org.jboss.mq.server.jmx.Queue"
+ name="jboss.esb.quickstart.destination:service=Queue,name=quickstart_webservice_proxy_routed_hello_esb_reply">
+ <depends optional-attribute-name="DestinationManager">
+ jboss.mq:service=DestinationManager
+ </depends>
+ </mbean>
+ <mbean code="org.jboss.mq.server.jmx.Queue"
+ name="jboss.esb.quickstart.destination:service=Queue,name=quickstart_webservice_proxy_routed_goodbye_esb">
+ <depends optional-attribute-name="DestinationManager">
+ jboss.mq:service=DestinationManager
+ </depends>
+ </mbean>
+ <mbean code="org.jboss.mq.server.jmx.Queue"
+ name="jboss.esb.quickstart.destination:service=Queue,name=quickstart_webservice_proxy_routed_goodbye_esb_reply">
+ <depends optional-attribute-name="DestinationManager">
+ jboss.mq:service=DestinationManager
+ </depends>
+ </mbean>
+</server>
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/jbmq-queue-service.xml
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/jboss-esb.xml
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/jboss-esb.xml (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/jboss-esb.xml 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,121 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<jbossesb xmlns="http://anonsvn.labs.jboss.com/labs/jbossesb/trunk/product/etc/schemas/xml/jbossesb-1.1.0.xsd" parameterReloadSecs="5">
+
+ <providers>
+
+ <jbr-provider name="JBossRemoting" protocol="http" host="localhost">
+ <jbr-bus busid="Proxy_CBR-GwChannel" port="9090"/>
+ </jbr-provider>
+
+ <jms-provider name="JBossMQ" connection-factory="ConnectionFactory">
+ <jms-bus busid="Proxy_CBR-EsbChannel">
+ <jms-message-filter
+ dest-type="QUEUE"
+ dest-name="queue/quickstart_webservice_proxy_routed_cbr_esb"
+ />
+ </jms-bus>
+ <jms-bus busid="Proxy_Hello-EsbChannel">
+ <jms-message-filter
+ dest-type="QUEUE"
+ dest-name="queue/quickstart_webservice_proxy_routed_hello_esb"
+ />
+ </jms-bus>
+ <jms-bus busid="Proxy_Goodbye-EsbChannel">
+ <jms-message-filter
+ dest-type="QUEUE"
+ dest-name="queue/quickstart_webservice_proxy_routed_goodbye_esb"
+ />
+ </jms-bus>
+ </jms-provider>
+
+ </providers>
+
+ <services>
+
+ <service category="Proxy_Routed" name="Proxy_CBR"
+ description="Routed WebService Proxy: CBR">
+ <listeners>
+ <jbr-listener
+ name="Proxy_CBR-GwListener"
+ busidref="Proxy_CBR-GwChannel"
+ is-gateway="true"
+ />
+ <jms-listener
+ name="Proxy_CBR-EsbListener"
+ busidref="Proxy_CBR-EsbChannel"
+ />
+ </listeners>
+ <actions>
+ <action name="proxy_cbr_echo_request"
+ class="org.jboss.soa.esb.actions.SystemPrintln">
+ <property name="message" value="Message before ContentBasedRouter" />
+ </action>
+ <action name="proxy_cbr"
+ class="org.jboss.soa.esb.actions.ContentBasedRouter">
+ <property name="ruleSet" value="Proxy_Routed_Rules.drl"/>
+ <property name="ruleLanguage" value="XPathLanguage.dsl"/>
+ <property name="destinations">
+ <route-to
+ destination-name="hello"
+ service-category="Proxy_Routed"
+ service-name="Proxy_Hello" />
+ <route-to
+ destination-name="goodbye"
+ service-category="Proxy_Routed"
+ service-name="Proxy_Goodbye" />
+ </property>
+ </action>
+ </actions>
+ </service>
+
+ <service category="Proxy_Routed" name="Proxy_Hello"
+ description="Routed WebService Proxy: Hello">
+ <listeners>
+ <jms-listener
+ name="Proxy_Hello-EsbListener"
+ busidref="Proxy_Hello-EsbChannel"
+ />
+ </listeners>
+ <actions>
+ <action name="proxy_hello_echo_request"
+ class="org.jboss.soa.esb.actions.SystemPrintln">
+ <property name="message" value="Message before Hello SOAPProxy" />
+ </action>
+ <action name="proxy_hello_proxy"
+ class="org.jboss.soa.esb.actions.soap.proxy.SOAPProxy">
+ <property name="wsdl" value="http://localhost:8080/Quickstart_webservice_proxy_routed/HelloWS?wsdl"/>
+ </action>
+ <action name="proxy_hello_echo_response"
+ class="org.jboss.soa.esb.actions.SystemPrintln">
+ <property name="message" value="Message after Hello SOAPProxy" />
+ </action>
+ </actions>
+ </service>
+
+ <service category="Proxy_Routed" name="Proxy_Goodbye"
+ description="Routed WebService Proxy: Goodbye">
+ <listeners>
+ <jms-listener
+ name="Proxy_Goodbye-EsbListener"
+ busidref="Proxy_Goodbye-EsbChannel"
+ />
+ </listeners>
+ <actions>
+ <action name="proxy_goodbye_echo_request"
+ class="org.jboss.soa.esb.actions.SystemPrintln">
+ <property name="message" value="Message before Goodbye SOAPProxy" />
+ </action>
+ <action name="proxy_goodbye_proxy"
+ class="org.jboss.soa.esb.actions.soap.proxy.SOAPProxy">
+ <property name="wsdl" value="http://localhost:8080/Quickstart_webservice_proxy_routed/GoodbyeWS?wsdl"/>
+ </action>
+ <action name="proxy_goodbye_echo_response"
+ class="org.jboss.soa.esb.actions.SystemPrintln">
+ <property name="message" value="Message after Goodbye SOAPProxy" />
+ </action>
+ </actions>
+ </service>
+
+ </services>
+
+</jbossesb>
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/jboss-esb.xml
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/log4j.xml
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/log4j.xml (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/log4j.xml 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
+
+<!-- ===================================================================== -->
+<!-- -->
+<!-- Log4j Configuration -->
+<!-- -->
+<!-- ===================================================================== -->
+
+<!-- $Id$ -->
+
+<!--
+ | For more configuration infromation and examples see the Jakarta Log4j
+ | owebsite: http://jakarta.apache.org/log4j
+ -->
+
+<log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/" debug="false">
+
+ <!-- ============================== -->
+ <!-- Append messages to the console -->
+ <!-- ============================== -->
+
+ <appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
+ <errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/>
+ <param name="Target" value="System.out"/>
+
+ <layout class="org.apache.log4j.PatternLayout">
+ <!-- The default pattern: Date Priority [Category] Message\n -->
+ <param name="ConversionPattern" value="%d{ABSOLUTE} %-5p [%t][%c{1}] %m%n"/>
+ </layout>
+ </appender>
+
+ <!-- ================================= -->
+ <!-- Preserve messages in a local file -->
+ <!-- ================================= -->
+
+ <!-- A size based file rolling appender -->
+ <appender name="FILE" class="org.jboss.logging.appender.RollingFileAppender">
+ <errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/>
+ <param name="File" value="./listener.log"/>
+ <param name="Append" value="false"/>
+ <param name="MaxFileSize" value="500KB"/>
+ <param name="MaxBackupIndex" value="1"/>
+
+ <layout class="org.apache.log4j.PatternLayout">
+ <param name="ConversionPattern" value="%d %-5p [%t][%c] %m%n"/>
+ </layout>
+ </appender>
+
+ <!-- ================ -->
+ <!-- Limit categories -->
+ <!-- ================ -->
+
+ <category name="org.jboss">
+ <priority value="WARN"/>
+ </category>
+ <category name="org.jboss.soa.esb">
+ <priority value="ERROR"/>
+ </category>
+ <category name="org.jboss.internal.soa.esb">
+ <priority value="ERROR"/>
+ </category>
+ <category name="org.apache">
+ <priority value="ERROR"/>
+ </category>
+ <category name="quickstart">
+ <priority value="INFO"/>
+ </category>
+ <!-- ======================= -->
+ <!-- Setup the Root category -->
+ <!-- ======================= -->
+
+ <root>
+ <appender-ref ref="CONSOLE"/>
+ <appender-ref ref="FILE"/>
+ </root>
+
+</log4j:configuration>
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/log4j.xml
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/readme.txt
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/readme.txt (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/readme.txt 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,141 @@
+Overview:
+=========
+ Route to appropriate service to fulfill the awaiting WS client's request.
+
+Running this quickstart:
+========================
+ Please refer to 'ant help-quickstarts' for prerequisites about the quickstarts
+ and a more detailed descripton of the different ways to run the quickstarts.
+
+To Run:
+===========================
+ 1. In a command terminal window in this folder ("Window1"), type 'ant deploy'.
+ - In your server console, you will see output like this in the server console:
+
+01:01:00,370 INFO [SOAPProxy] mapped soapaction [""] to binding [{http://webservice_proxy_routed/hello}HelloBinding]
+01:01:00,370 INFO [SOAPProxy] mapped operation [{http://webservice_proxy_routed/hello}sayHello] to binding [{http://webservice_proxy_routed/hello}HelloBinding]
+01:01:00,370 INFO [SOAPProxy] mapped binding [{http://webservice_proxy_routed/hello}HelloBinding] to transport [org.jboss.soa.esb.actions.soap.proxy.HttpSOAPProxyTransport] with endpoint address: [http://localhost:8080/Quickstart_webservice_proxy_routed/HelloWS]
+...
+01:01:00,571 INFO [SOAPProxy] mapped soapaction [""] to binding [{http://webservice_proxy_routed/goodbye}GoodbyeBinding]
+01:01:00,572 INFO [SOAPProxy] mapped operation [{http://webservice_proxy_routed/goodbye}sayGoodbye] to binding [{http://webservice_proxy_routed/goodbye}GoodbyeBinding]
+01:01:00,572 INFO [SOAPProxy] mapped binding [{http://webservice_proxy_routed/goodbye}GoodbyeBinding] to transport [org.jboss.soa.esb.actions.soap.proxy.HttpSOAPProxyTransport] with endpoint address: [http://localhost:8080/Quickstart_webservice_proxy_routed/GoodbyeWS]
+
+ 2. Open another command terminal window in this folder ("Window2"), type
+ 'ant runtest'.
+
+ 3. Switch back to Application Server console to see the output from the ESB
+
+ 4. In this folder ("Window1"), type 'ant undeploy'.
+
+ 'runhello' (alias 'runtest') target description:
+ - This will exercise the Hello webservice *via* a SOAPProxy, first going
+ through a JBoss Remoting Gateway Listener, then a ContentBasedRouter
+ to know whih proxied web service to invoke, which in this case is HelloWS.
+ - The request url is: http://localhost:9090
+ - Running it will create output like this in the server console:
+
+01:02:33,412 INFO [STDOUT] Message before ContentBasedRouter:
+01:02:33,412 INFO [STDOUT] [<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:hello="http://webservice_proxy_routed/hello"><soapenv:Header/><soapenv:Body><hello:sayHello><toWhom>dward</toWhom></hello:sayHello></soapenv:Body></soapenv:Envelope>].
+01:02:33,429 INFO [STDOUT] Routing to Hello...
+01:02:33,442 INFO [STDOUT] Message before Hello SOAPProxy:
+01:02:33,442 INFO [STDOUT] [<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:hello="http://webservice_proxy_routed/hello"><soapenv:Header/><soapenv:Body><hello:sayHello><toWhom>dward</toWhom></hello:sayHello></soapenv:Body></soapenv:Envelope>].
+01:02:33,450 INFO [STDOUT] Message after Hello SOAPProxy:
+01:02:33,450 INFO [STDOUT] [<env:Envelope xmlns:env='http://schemas.xmlsoap.org/soap/envelope/'><env:Header></env:Header><env:Body><ns2:sayHelloResponse xmlns:ns2="http://webservice_proxy_routed/hello"><return>Hello 'dward' on Mon Jul 06 01:02:33 GMT-05:00 2009</return></ns2:sayHelloResponse></env:Body></env:Envelope>].
+
+ ...and this in the client console:
+
+ [java] **** REQUEST URL: http://localhost:9090
+ [java] **** REQUEST BODY: <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:hello="http://webservice_proxy_routed/hello"><soapenv:Header/><soapenv:Body><hello:sayHello><toWhom>dward</toWhom></hello:sayHello></soapenv:Body></soapenv:Envelope>
+ [java] 01:02:33,380 DEBUG [main][header] >> "POST / HTTP/1.1[\r][\n]"
+ [java] 01:02:33,401 DEBUG [main][header] >> "Content-Type: text/xml;charset=UTF-8[\r][\n]"
+ [java] 01:02:33,402 DEBUG [main][header] >> "SOAPAction: ""[\r][\n]"
+ [java] 01:02:33,402 DEBUG [main][header] >> "User-Agent: Jakarta Commons-HttpClient/3.0.1[\r][\n]"
+ [java] 01:02:33,403 DEBUG [main][header] >> "Host: localhost:9090[\r][\n]"
+ [java] 01:02:33,403 DEBUG [main][header] >> "Content-Length: 249[\r][\n]"
+ [java] 01:02:33,403 DEBUG [main][header] >> "[\r][\n]"
+ [java] 01:02:33,403 DEBUG [main][content] >> "<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:hello="http://webservice_proxy_routed/hello"><soapenv:Header/><soapenv:Body><hello:sayHello><toWhom>dward</toWhom></hello:sayHello></soapenv:Body></soapenv:Envelope>"
+ [java] 01:02:33,460 DEBUG [main][header] << "HTTP/1.1 200 OK[\r][\n]"
+ [java] 01:02:33,461 DEBUG [main][header] << "Server: Apache-Coyote/1.1[\r][\n]"
+ [java] 01:02:33,462 DEBUG [main][header] << "X-Powered-By: Servlet 2.4; JBoss-4.2.3.GA (build: SVNTag=JBoss_4_2_3_GA date=200807181417)/JBossWeb-2.0[\r][\n]"
+ [java] 01:02:33,462 DEBUG [main][header] << "Date: Mon, 06 Jul 2009 06:02:33 GMT[\r][\n]"
+ [java] 01:02:33,462 DEBUG [main][header] << "Content-Type: text/xml;charset=UTF-8[\r][\n]"
+ [java] 01:02:33,462 DEBUG [main][header] << "Content-Length: 293[\r][\n]"
+ [java] **** RESPONSE CODE: 200
+ [java] 01:02:33,466 DEBUG [main][content] << "<env:Envelope xmlns:env='http://schemas.xmlsoap.org/soap/envelope/'><env:Header></env:Header><env:Body><ns2:sayHelloResponse xmlns:ns2="http://webservice_proxy_routed/hello"><return>Hello 'dward' on Mon Jul 06 01:02:33 GMT-05:00 2009</return></ns2:sayHel"
+ [java] 01:02:33,466 DEBUG [main][content] << "loResponse></env:Body></env:Envelope>"
+ [java] **** RESPONSE BODY: <env:Envelope xmlns:env='http://schemas.xmlsoap.org/soap/envelope/'><env:Header></env:Header><env:Body><ns2:sayHelloResponse xmlns:ns2="http://webservice_proxy_routed/hello"><return>Hello 'dward' on Mon Jul 06 01:02:33 GMT-05:00 2009</return></ns2:sayHelloResponse></env:Body></env:Envelope>e>
+
+ 'rungoodbye' target description:
+ - This will exercise the Goodbye webservice *via* a SOAPProxy, first going
+ through a JBoss Remoting Gateway Listener, then a ContentBasedRouter
+ to know whih proxied web service to invoke, which in this case is GoodbyeWS.
+ - The request url is: http://localhost:9090
+ - Running it will create output like this in the server console:
+
+01:03:32,618 INFO [STDOUT] Message before ContentBasedRouter:
+01:03:32,618 INFO [STDOUT] [<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:goodbye="http://webservice_proxy_routed/goodbye"><soapenv:Header/><soapenv:Body><goodbye:sayGoodbye><toWhom>dward</toWhom></goodbye:sayGoodbye></soapenv:Body></soapenv:Envelope>].
+01:03:32,626 INFO [STDOUT] Routing to Goodbye...
+01:03:32,724 INFO [STDOUT] Message before Goodbye SOAPProxy:
+01:03:32,724 INFO [STDOUT] [<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:goodbye="http://webservice_proxy_routed/goodbye"><soapenv:Header/><soapenv:Body><goodbye:sayGoodbye><toWhom>dward</toWhom></goodbye:sayGoodbye></soapenv:Body></soapenv:Envelope>].
+01:03:32,739 INFO [STDOUT] Message after Goodbye SOAPProxy:
+01:03:32,739 INFO [STDOUT] [<env:Envelope xmlns:env='http://schemas.xmlsoap.org/soap/envelope/'><env:Header></env:Header><env:Body><ns2:sayGoodbyeResponse xmlns:ns2="http://webservice_proxy_routed/goodbye"><return>Goodbye 'dward' on Mon Jul 06 01:03:32 GMT-05:00 2009</return></ns2:sayGoodbyeResponse></env:Body></env:Envelope>].].
+
+ ...and this in the client console:
+
+ [java] **** REQUEST URL: http://localhost:9090
+ [java] **** REQUEST BODY: <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:goodbye="http://webservice_proxy_routed/goodbye"><soapenv:Header/><soapenv:Body><goodbye:sayGoodbye><toWhom>dward</toWhom></goodbye:sayGoodbye></soapenv:Body></soapenv:Envelope>
+ [java] 01:03:32,488 DEBUG [main][header] >> "POST / HTTP/1.1[\r][\n]"
+ [java] 01:03:32,520 DEBUG [main][header] >> "Content-Type: text/xml;charset=UTF-8[\r][\n]"
+ [java] 01:03:32,520 DEBUG [main][header] >> "SOAPAction: ""[\r][\n]"
+ [java] 01:03:32,521 DEBUG [main][header] >> "User-Agent: Jakarta Commons-HttpClient/3.0.1[\r][\n]"
+ [java] 01:03:32,528 DEBUG [main][header] >> "Host: localhost:9090[\r][\n]"
+ [java] 01:03:32,529 DEBUG [main][header] >> "Content-Length: 261[\r][\n]"
+ [java] 01:03:32,529 DEBUG [main][header] >> "[\r][\n]"
+ [java] 01:03:32,529 DEBUG [main][content] >> "<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:goodbye="http://webservice_proxy_routed/goodbye"><soapenv:Header/><soapenv:Body><goodbye:sayGoodbye><toWhom>dward</toWhom></goodbye:sayGoodbye></soapenv:Body></soapenv:Envelope>"
+ [java] 01:03:32,759 DEBUG [main][header] << "HTTP/1.1 200 OK[\r][\n]"
+ [java] 01:03:32,760 DEBUG [main][header] << "Server: Apache-Coyote/1.1[\r][\n]"
+ [java] 01:03:32,761 DEBUG [main][header] << "X-Powered-By: Servlet 2.4; JBoss-4.2.3.GA (build: SVNTag=JBoss_4_2_3_GA date=200807181417)/JBossWeb-2.0[\r][\n]"
+ [java] 01:03:32,761 DEBUG [main][header] << "Date: Mon, 06 Jul 2009 06:03:32 GMT[\r][\n]"
+ [java] 01:03:32,761 DEBUG [main][header] << "Content-Type: text/xml;charset=UTF-8[\r][\n]"
+ [java] 01:03:32,761 DEBUG [main][header] << "Content-Length: 301[\r][\n]"
+ [java] **** RESPONSE CODE: 200
+ [java] 01:03:32,764 DEBUG [main][content] << "<env:Envelope xmlns:env='http://schemas.xmlsoap.org/soap/envelope/'><env:Header></env:Header><env:Body><ns2:sayGoodbyeResponse xmlns:ns2="http://webservice_proxy_routed/goodbye"><return>Goodbye 'dward' on Mon Jul 06 01:03:32 GMT-05:00 2009</return></ns2:"
+ [java] 01:03:32,764 DEBUG [main][content] << "sayGoodbyeResponse></env:Body></env:Envelope>"
+ [java] **** RESPONSE BODY: <env:Envelope xmlns:env='http://schemas.xmlsoap.org/soap/envelope/'><env:Header></env:Header><env:Body><ns2:sayGoodbyeResponse xmlns:ns2="http://webservice_proxy_routed/goodbye"><return>Goodbye 'dward' on Mon Jul 06 01:03:32 GMT-05:00 2009</return></ns2:sayGoodbyeResponse></env:Body></env:Envelope>
+
+Project file descriptions:
+==========================
+ jboss-esb.xml:
+ A JBoss Remoting Gateway Listener accepts the incoming HTTP call makes it available to the
+ Proxy_Routed/Proxy_CBR service, who uses a ContentBasedRouter configured with a drools rules
+ file.
+
+ Proxy_Routed_Rules.drl:
+ Uses xpath expressions to match the body content of the soap envelope, and
+ depending on that content, route to either the "hello" destination (which
+ invokes the HelloWS via a SOAPProxy), or the "goodbye" desitination
+ (which invokes the GoodbyeWS via a SOAPProxy).
+
+ log4j.xml:
+ Needed to configure log4J used by the quickstart.
+
+ src/../SendWSMessage.java:
+ Sends a SOAP message to the target webservice endpoint (see "ant run*" above).
+
+ build.xml:
+ Targets and structure description:
+
+ * the runhello (also runtest) task calls the
+ org.jboss.soa.esb.samples.quickstart.webservice_proxy_routed.test.SendWSMessage class and
+ passes in and argument representing the *PROXIED* webservice endpoint (via JBoss Remoting)
+ and an argument representing the string-based message to invoke the webservice with.
+ SendWSMessage will submit a soap request which the CBR will determine to route to the proxied
+ (via SOAPProxy) HelloWS.
+
+ * the rungoodbye task calls the
+ org.jboss.soa.esb.samples.quickstart.webservice_proxy_routed.test.SendWSMessage class and
+ passes in and argument representing the *PROXIED* webservice endpoint (via HTTP Gateway)
+ and an argument representing the string-based message to invoke the webservice with.
+ SendWSMessage will submit a soap request which the CBR will determine to route to the proxied
+ (via SOAPProxy) GoodbyeWS.
+
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/readme.txt
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_routed/test/SendWSMessage.java
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_routed/test/SendWSMessage.java (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_routed/test/SendWSMessage.java 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,111 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, JBoss Inc., and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+ * PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
+ * You should have received a copy of the GNU Lesser General Public License,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ *
+ * (C) 2005-2009
+ */
+package org.jboss.soa.esb.samples.quickstart.webservice_proxy_routed.test;
+
+import java.io.InputStream;
+
+import org.apache.commons.httpclient.HttpClient;
+import org.apache.commons.httpclient.methods.PostMethod;
+import org.apache.commons.httpclient.methods.StringRequestEntity;
+import org.jboss.internal.soa.esb.util.StreamUtils;
+
+/**
+ * Sends a simple webservice request to the proxied webservice, printing both the request and the response to the console.
+ *
+ * @author dward at jboss.org
+ */
+public class SendWSMessage
+{
+
+ private static final String HELLO_SOAP_PRE =
+ "<soapenv:Envelope xmlns:soapenv=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:hello=\"http://webservice_proxy_routed/hello\">" +
+ "<soapenv:Header/>" +
+ "<soapenv:Body>" +
+ "<hello:sayHello>" +
+ "<toWhom>";
+
+ private static final String HELLO_SOAP_POST =
+ "</toWhom>" +
+ "</hello:sayHello>" +
+ "</soapenv:Body>" +
+ "</soapenv:Envelope>";
+
+ private static final String GOODBYE_SOAP_PRE =
+ "<soapenv:Envelope xmlns:soapenv=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:goodbye=\"http://webservice_proxy_routed/goodbye\">" +
+ "<soapenv:Header/>" +
+ "<soapenv:Body>" +
+ "<goodbye:sayGoodbye>" +
+ "<toWhom>";
+
+ private static final String GOODBYE_SOAP_POST =
+ "</toWhom>" +
+ "</goodbye:sayGoodbye>" +
+ "</soapenv:Body>" +
+ "</soapenv:Envelope>";
+
+ // see product/samples/quickstarts/webservice_proxy_routed/build.xml
+ public static void main(String... args) throws Exception
+ {
+ if (args.length < 3)
+ {
+ // for testing main method from Eclipse (build.xml passes these args in)
+ args = new String[3];
+ args[0] = "http://localhost:9090"; // proxy via jbr gateway ("ant runhello" or "ant rungoodbye")
+ args[1] = System.getProperty("user.name");
+ args[2] = "hello";
+ }
+
+ String url = args[0];
+ System.out.println("**** REQUEST URL: " + url);
+ PostMethod method = new PostMethod(url);
+ method.setRequestHeader("Content-Type", "text/xml;charset=UTF-8");
+
+ // this line should be used for better performance/interop but is not necessary
+ // http://www.w3.org/TR/2000/NOTE-SOAP-20000508/#_Toc478383528
+ // http://www.ws-i.org/Profiles/BasicProfile-1.1.html#SOAPAction_HTTP_Header
+ method.setRequestHeader("SOAPAction", "\"\"");
+
+ boolean hello = "hello".equals(args[2]);
+ String request = (hello ? HELLO_SOAP_PRE : GOODBYE_SOAP_PRE) + args[1] + (hello ? HELLO_SOAP_POST : GOODBYE_SOAP_POST);
+ System.out.println("**** REQUEST BODY: " + request);
+ method.setRequestEntity( new StringRequestEntity(request) );
+
+ HttpClient client = new HttpClient();
+ InputStream response = null;
+ try
+ {
+ int code = client.executeMethod(method);
+ System.out.println("**** RESPONSE CODE: " + code);
+
+ response = method.getResponseBodyAsStream();
+ byte[] bytes = StreamUtils.readStream(response);
+ System.out.println("**** RESPONSE BODY: " + new String(bytes, method.getResponseCharSet()));
+ }
+ finally
+ {
+ method.releaseConnection();
+ if (response != null)
+ {
+ response.close();
+ }
+ }
+ }
+
+}
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_routed/test/SendWSMessage.java
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/resources/WEB-INF/web.xml
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/resources/WEB-INF/web.xml (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/resources/WEB-INF/web.xml 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<web-app 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/web-app_2_4.xsd" version="2.4">
+
+ <servlet>
+ <servlet-name>HelloWS</servlet-name>
+ <servlet-class>org.jboss.soa.esb.samples.quickstart.webservice_proxy_routed.HelloWS</servlet-class>
+ </servlet>
+
+ <servlet>
+ <servlet-name>GoodbyeWS</servlet-name>
+ <servlet-class>org.jboss.soa.esb.samples.quickstart.webservice_proxy_routed.GoodbyeWS</servlet-class>
+ </servlet>
+
+ <servlet-mapping>
+ <servlet-name>HelloWS</servlet-name>
+ <url-pattern>/HelloWS</url-pattern>
+ </servlet-mapping>
+
+ <servlet-mapping>
+ <servlet-name>GoodbyeWS</servlet-name>
+ <url-pattern>/GoodbyeWS</url-pattern>
+ </servlet-mapping>
+
+</web-app>
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/resources/WEB-INF/web.xml
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_routed/GoodbyeWS.java
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_routed/GoodbyeWS.java (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_routed/GoodbyeWS.java 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,41 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, JBoss Inc., and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+ * PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
+ * You should have received a copy of the GNU Lesser General Public License,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ *
+ * (C) 2005-2009
+ */
+package org.jboss.soa.esb.samples.quickstart.webservice_proxy_routed;
+
+import javax.jws.WebMethod;
+import javax.jws.WebParam;
+import javax.jws.WebService;
+
+/**
+ * Simple rpc-style webservice that returns a goodbye message (using the passed-in name) and the current date.
+ *
+ * @author dward at jboss.org
+ */
+ at WebService(name = "Goodbye", targetNamespace = "http://webservice_proxy_routed/goodbye")
+public class GoodbyeWS
+{
+
+ @WebMethod
+ public String sayGoodbye(@WebParam(name = "toWhom") String toWhom)
+ {
+ return "Goodbye '" + toWhom + "' on " + new java.util.Date();
+ }
+
+}
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_routed/GoodbyeWS.java
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_routed/HelloWS.java
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_routed/HelloWS.java (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_routed/HelloWS.java 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,41 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, JBoss Inc., and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+ * PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
+ * You should have received a copy of the GNU Lesser General Public License,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ *
+ * (C) 2005-2009
+ */
+package org.jboss.soa.esb.samples.quickstart.webservice_proxy_routed;
+
+import javax.jws.WebMethod;
+import javax.jws.WebParam;
+import javax.jws.WebService;
+
+/**
+ * Simple rpc-style webservice that returns a hello message (using the passed-in name) and the current date.
+ *
+ * @author dward at jboss.org
+ */
+ at WebService(name = "Hello", targetNamespace = "http://webservice_proxy_routed/hello")
+public class HelloWS
+{
+
+ @WebMethod
+ public String sayHello(@WebParam(name = "toWhom") String toWhom)
+ {
+ return "Hello '" + toWhom + "' on " + new java.util.Date();
+ }
+
+}
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_routed/HelloWS.java
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/view/index.jsp
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/view/index.jsp (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/view/index.jsp 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,9 @@
+<html>
+ <body>
+ This is just a place holder.<br>
+ Verify the that the WS has been deployed by hitting
+ <a href="http://localhost:8080/jbossws">
+ http://localhost:8080/jbossws
+ </a>
+ </body>
+</html>
\ No newline at end of file
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_routed/war/view/index.jsp
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/Proxy_Versioning_RequestTransform.xsl
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/Proxy_Versioning_RequestTransform.xsl (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/Proxy_Versioning_RequestTransform.xsl 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<xsl:stylesheet version="1.0"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+ xmlns:inv="http://webservice_proxy_versioning/invoicing">
+
+ <xsl:output method="xml" indent="yes" omit-xml-declaration="yes"/>
+
+ <xsl:template match="inv:processInvoice">
+ <xsl:copy>
+ <invoiceNumber><xsl:value-of select="invoiceNumber"/></invoiceNumber>
+ <!-- here we add the processDate element to conform to the newer version -->
+ <!-- (xsl 2 would give us the current-dateTime() function) -->
+ <processDate>2005-12-13T14:13:28.443+01:00</processDate>
+ </xsl:copy>
+ </xsl:template>
+
+ <xsl:template match="*">
+ <xsl:copy>
+ <xsl:copy-of select="@*"/>
+ <xsl:apply-templates/>
+ </xsl:copy>
+ </xsl:template>
+
+ <xsl:template match="comment()|processing-instruction()">
+ <xsl:copy/>
+ </xsl:template>
+
+</xsl:stylesheet>
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/Proxy_Versioning_RequestTransform.xsl
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/Proxy_Versioning_WsdlTransform.xml
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/Proxy_Versioning_WsdlTransform.xml (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/Proxy_Versioning_WsdlTransform.xml 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,18 @@
+<?xml version="1.0"?>
+<smooks-resource-list
+ xmlns="http://www.milyn.org/xsd/smooks-1.1.xsd"
+ xmlns:g="http://www.milyn.org/xsd/smooks/groovy-1.1.xsd">
+
+ <g:groovy executeOnElement="element">
+ <g:script>
+ <!--
+ use(DOMCategory) {
+ if (element.'@name' == 'processDate') {
+ DomUtils.removeElement(element, false);
+ }
+ }
+ -->
+ </g:script>
+ </g:groovy>
+
+</smooks-resource-list>
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/Proxy_Versioning_WsdlTransform.xml
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/build.xml
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/build.xml (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/build.xml 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,94 @@
+<project name="Quickstart_webservice_proxy_versioning" default="deploy" basedir=".">
+
+ <description>
+ ${ant.project.name}
+ ${line.separator}
+ </description>
+
+ <property name="additional.deploys" value="Proxy_Versioning_WsdlTransform.xml Proxy_Versioning_RequestTransform.xsl"/>
+
+ <!-- Import the base Ant build script... -->
+ <import file="../conf/base-build.xml"/>
+
+ <property name="war.build.dir" location="${build.dir}/war/classes"/>
+
+ <target name="quickstart-specific-checks" depends="assert-ws-available"/>
+
+ <target name="quickstart-specific-assemblies" depends="makewar"/>
+
+ <target name="quickstart-specific-predeploys">
+ <copy todir="${org.jboss.esb.server.deploy.dir}"
+ file="build/predeploy/${ant.project.name}.war"/>
+ <sleep seconds="3"/>
+ </target>
+
+ <target name="quickstart-specific-undeploys">
+ <delete file="${org.jboss.esb.server.deploy.dir}/${ant.project.name}.war"/>
+ </target>
+
+ <target name="makewar" description="make war">
+ <!-- Compile... -->
+ <mkdir dir="${war.build.dir}" />
+ <javac srcdir="war/src" destdir="${war.build.dir}" debug="true">
+ <classpath>
+ <path refid="compile-classpath" />
+ <fileset dir="war/lib/ext" includes="*.jar" />
+ </classpath>
+ </javac>
+
+ <!-- War... -->
+ <mkdir dir="build/predeploy"/>
+ <war warfile="build/predeploy/${ant.project.name}.war"
+ webxml="${basedir}/war/resources/WEB-INF/web.xml">
+ <webinf dir="${basedir}/war/resources/WEB-INF">
+ <include name="jboss-web.xml"/>
+ </webinf>
+ <classes dir="${war.build.dir}" includes="**/*.class"/>
+ <fileset dir="${basedir}/war/view">
+ <include name="**/*"/>
+ </fileset>
+ <classes dir="${basedir}">
+ <include name="juddi.properties"/>
+ </classes>
+ </war>
+ </target>
+
+ <target name="quickstart-specific-clean">
+ <delete file="${basedir}/listener.log"/>
+ </target>
+
+ <target name="run">
+ <echo>standalone mode is not available for this quickstart.</echo>
+ </target>
+
+ <target name="runinternal" depends="compile">
+ <java fork="yes" classname="org.jboss.soa.esb.samples.quickstart.webservice_proxy_versioning.test.SendWSMessage" failonerror="true">
+ <arg value="${runtest.arg.url}"/>
+ <arg value="${runtest.arg.ver}"/>
+ <classpath refid="exec-classpath"/>
+ </java>
+ </target>
+
+ <target name="runws">
+ <echo>Calling JBossWS webservice directly.</echo>
+ <property name="runtest.arg.url" value="http://localhost:8080/Quickstart_webservice_proxy_versioning/InvoicingWS"/>
+ <property name="runtest.arg.ver" value="new"/>
+ <antcall target="runinternal"/>
+ </target>
+
+ <target name="runold">
+ <echo>Calling JBossWS webservice via JBossRemotingGatewayListener and SOAPProxy.</echo>
+ <property name="runtest.arg.url" value="http://localhost:9090"/>
+ <property name="runtest.arg.ver" value="old"/>
+ <antcall target="runinternal"/>
+ </target>
+ <target name="runtest" depends="runold"/>
+
+ <target name="runnew">
+ <echo>Calling JBossWS webservice via JBossRemotingGatewayListener and SOAPProxy.</echo>
+ <property name="runtest.arg.url" value="http://localhost:9999"/>
+ <property name="runtest.arg.ver" value="new"/>
+ <antcall target="runinternal"/>
+ </target>
+
+</project>
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/build.xml
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/deployment.xml
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/deployment.xml (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/deployment.xml 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,4 @@
+<jbossesb-deployment>
+ <depends>jboss.esb:deployment=soap.esb</depends>
+</jbossesb-deployment>
+
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/deployment.xml
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/jboss-esb.xml
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/jboss-esb.xml (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/jboss-esb.xml 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,85 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<jbossesb xmlns="http://anonsvn.labs.jboss.com/labs/jbossesb/trunk/product/etc/schemas/xml/jbossesb-1.1.0.xsd" parameterReloadSecs="5">
+
+ <providers>
+
+ <jbr-provider name="JBR-PROVIDER-OldVersion" protocol="http" host="localhost">
+ <jbr-bus busid="JBR-BUS-OldVersion" port="9090"/>
+ </jbr-provider>
+
+ <jbr-provider name="JBR-PROVIDER-NewVersion" protocol="http" host="localhost">
+ <jbr-bus busid="JBR-BUS-NewVersion" port="9999"/>
+ </jbr-provider>
+
+ </providers>
+
+ <services>
+
+ <service category="Proxy_Versioning" name="Proxy-OldVersion"
+ description="The old version of the WebService (legacy support)"
+ invmScope="GLOBAL" >
+ <listeners>
+ <jbr-listener name="JBR-GATEWAY-OldVersion"
+ busidref="JBR-BUS-OldVersion"
+ is-gateway="true"
+ />
+ </listeners>
+ <actions mep="RequestResponse">
+ <action name="echo-old-request"
+ class="org.jboss.soa.esb.actions.SystemPrintln">
+ <property name="message" value="Message before Transformation" />
+ </action>
+ <!-- we transform the OLD request to fit the NEW schema -->
+ <action name="proxy-transform-old-to-new"
+ class="org.jboss.soa.esb.actions.transformation.xslt.XsltAction">
+ <property name="templateFile" value="/Proxy_Versioning_RequestTransform.xsl"/>
+ <property name="failOnWarning" value="true"/>
+ <property name="resultType" value="STRING"/>
+ </action>
+ <action name="echo-new-request"
+ class="org.jboss.soa.esb.actions.SystemPrintln">
+ <property name="message" value="Message after Transformation but before SOAPProxy" />
+ </action>
+ <action name="proxy-invoke-new-version"
+ class="org.jboss.soa.esb.actions.soap.proxy.SOAPProxy">
+ <!-- this is the NEW endpoint, because we transformed the OLD request to fit it -->
+ <property name="wsdl" value="http://localhost:8080/Quickstart_webservice_proxy_versioning/InvoicingWS?wsdl"/>
+ <property name="wsdlTransform" value="/Proxy_Versioning_WsdlTransform.xml"/>
+ </action>
+ <action name="echo-response"
+ class="org.jboss.soa.esb.actions.SystemPrintln">
+ <property name="message" value="Message after SOAPProxy" />
+ </action>
+ <!-- we could transform the response here, if we needed to (but we don't) -->
+ </actions>
+ </service>
+
+ <service category="Proxy_Versioning" name="Proxy-NewVersion"
+ description="The new version of the WebService (latest and greatest)"
+ invmScope="GLOBAL" >
+ <listeners>
+ <jbr-listener name="JBR-GATEWAY-NewVersion"
+ busidref="JBR-BUS-NewVersion"
+ is-gateway="true"
+ />
+ </listeners>
+ <actions mep="RequestResponse">
+ <action name="echo-request"
+ class="org.jboss.soa.esb.actions.SystemPrintln">
+ <property name="message" value="Message before SOAPProxy" />
+ </action>
+ <action name="proxy-invoke-new-version"
+ class="org.jboss.soa.esb.actions.soap.proxy.SOAPProxy">
+ <!-- this is the NEW endpoint, of course -->
+ <property name="wsdl" value="http://localhost:8080/Quickstart_webservice_proxy_versioning/InvoicingWS?wsdl"/>
+ </action>
+ <action name="echo-response"
+ class="org.jboss.soa.esb.actions.SystemPrintln">
+ <property name="message" value="Message after SOAPProxy" />
+ </action>
+ </actions>
+ </service>
+
+ </services>
+
+</jbossesb>
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/jboss-esb.xml
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/log4j.xml
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/log4j.xml (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/log4j.xml 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
+
+<!-- ===================================================================== -->
+<!-- -->
+<!-- Log4j Configuration -->
+<!-- -->
+<!-- ===================================================================== -->
+
+<!-- $Id$ -->
+
+<!--
+ | For more configuration infromation and examples see the Jakarta Log4j
+ | owebsite: http://jakarta.apache.org/log4j
+ -->
+
+<log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/" debug="false">
+
+ <!-- ============================== -->
+ <!-- Append messages to the console -->
+ <!-- ============================== -->
+
+ <appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
+ <errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/>
+ <param name="Target" value="System.out"/>
+
+ <layout class="org.apache.log4j.PatternLayout">
+ <!-- The default pattern: Date Priority [Category] Message\n -->
+ <param name="ConversionPattern" value="%d{ABSOLUTE} %-5p [%t][%c{1}] %m%n"/>
+ </layout>
+ </appender>
+
+ <!-- ================================= -->
+ <!-- Preserve messages in a local file -->
+ <!-- ================================= -->
+
+ <!-- A size based file rolling appender -->
+ <appender name="FILE" class="org.jboss.logging.appender.RollingFileAppender">
+ <errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/>
+ <param name="File" value="./listener.log"/>
+ <param name="Append" value="false"/>
+ <param name="MaxFileSize" value="500KB"/>
+ <param name="MaxBackupIndex" value="1"/>
+
+ <layout class="org.apache.log4j.PatternLayout">
+ <param name="ConversionPattern" value="%d %-5p [%t][%c] %m%n"/>
+ </layout>
+ </appender>
+
+ <!-- ================ -->
+ <!-- Limit categories -->
+ <!-- ================ -->
+
+ <category name="org.jboss">
+ <priority value="WARN"/>
+ </category>
+ <category name="org.jboss.soa.esb">
+ <priority value="ERROR"/>
+ </category>
+ <category name="org.jboss.internal.soa.esb">
+ <priority value="ERROR"/>
+ </category>
+ <category name="org.apache">
+ <priority value="ERROR"/>
+ </category>
+ <category name="quickstart">
+ <priority value="INFO"/>
+ </category>
+ <!-- ======================= -->
+ <!-- Setup the Root category -->
+ <!-- ======================= -->
+
+ <root>
+ <appender-ref ref="CONSOLE"/>
+ <appender-ref ref="FILE"/>
+ </root>
+
+</log4j:configuration>
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/log4j.xml
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/readme.txt
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/readme.txt (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/readme.txt 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,163 @@
+Overview:
+=========
+ Versioning of proxied endpoints is an important aspect of an ESB.
+
+Running this quickstart:
+========================
+ Please refer to 'ant help-quickstarts' for prerequisites about the quickstarts
+ and a more detailed descripton of the different ways to run the quickstarts.
+
+To Run:
+===========================
+ 1. In a command terminal window in this folder ("Window1"), type 'ant deploy'.
+ - In your server console, you will see output like this in your server console:
+
+01:05:02,128 INFO [SOAPProxy] mapped soapaction [""] to binding [{http://webservice_proxy_versioning/invoicing}InvoicingBinding]
+01:05:02,128 INFO [SOAPProxy] mapped operation [{http://webservice_proxy_versioning/invoicing}processInvoice] to binding [{http://webservice_proxy_versioning/invoicing}InvoicingBinding]
+01:05:02,128 INFO [SOAPProxy] mapped binding [{http://webservice_proxy_versioning/invoicing}InvoicingBinding] to transport [org.jboss.soa.esb.actions.soap.proxy.HttpSOAPProxyTransport] with endpoint address: [http://localhost:8080/Quickstart_webservice_proxy_versioning/InvoicingWS]
+....
+01:05:02,158 INFO [SOAPProxy] mapped soapaction [""] to binding [{http://webservice_proxy_versioning/invoicing}InvoicingBinding]
+01:05:02,159 INFO [SOAPProxy] mapped operation [{http://webservice_proxy_versioning/invoicing}processInvoice] to binding [{http://webservice_proxy_versioning/invoicing}InvoicingBinding]
+01:05:02,159 INFO [SOAPProxy] mapped binding [{http://webservice_proxy_versioning/invoicing}InvoicingBinding] to transport [org.jboss.soa.esb.actions.soap.proxy.HttpSOAPProxyTransport] with endpoint address: [http://localhost:8080/Quickstart_webservice_proxy_versioning/InvoicingWS]
+
+ 2. Open another command terminal window in this folder ("Window2"), type
+ 'ant runtest'.
+
+ 3. Switch back to Application Server console to see the output from the ESB
+
+ 4. In this folder ("Window1"), type 'ant undeploy'.
+
+ 'runws' target description:
+ - This simply calls the target JBossWS webservice directly.
+ - The request url is: http://localhost:8080/Quickstart_webservice_proxy_versioning/InvoicingWS
+ - Running it will create output similar to the runnew output below.
+
+ 'runold' (alias 'runtest') target description:
+ - This will exercise the target webservice *via* the SOAPProxy, first going through a JBoss Remoting Gateway Listener
+ and having it's incoming SOAP request be *transformed* and having a <processDate> elemented added to the body!
+ - Note that the wsl is transformed as well (see "Project file descriptions" below)!
+ - The request url is: http://localhost:9090
+ - Running it will create output like this in the server console:
+
+01:05:59,535 INFO [STDOUT] Message before Transformation:
+01:05:59,535 INFO [STDOUT] [<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:inv="http://webservice_proxy_versioning/invoicing"><soapenv:Header/><soapenv:Body><inv:processInvoice><invoiceNumber>0123456789</invoiceNumber></inv:processInvoice></soapenv:Body></soapenv:Envelope>].
+01:05:59,543 INFO [STDOUT] Message after Transformation but before SOAPProxy:
+01:05:59,543 INFO [STDOUT] [<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:inv="http://webservice_proxy_versioning/invoicing">
+<soapenv:Header/>
+<soapenv:Body>
+<inv:processInvoice>
+<invoiceNumber>0123456789</invoiceNumber>
+<processDate>2005-12-13T14:13:28.443+01:00</processDate>
+</inv:processInvoice>
+</soapenv:Body>
+</soapenv:Envelope>
+].
+01:05:59,561 INFO [InvoicingWS] processInvoice called with invoiceNumber [0123456789] and processDate [Tue Dec 13 08:13:28 GMT-05:00 2005]
+01:05:59,565 INFO [STDOUT] Message after SOAPProxy:
+01:05:59,565 INFO [STDOUT] [<env:Envelope xmlns:env='http://schemas.xmlsoap.org/soap/envelope/'><env:Header></env:Header><env:Body><ns2:processInvoiceResponse xmlns:ns2="http://webservice_proxy_versioning/invoicing"><success>true</success></ns2:processInvoiceResponse></env:Body></env:Envelope>].
+
+ - And this in the client console:
+
+ [java] **** REQUEST URL: http://localhost:9090
+ [java] **** REQUEST BODY: <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:inv="http://webservice_proxy_versioning/invoicing"><soapenv:Header/><soapenv:Body><inv:processInvoice><invoiceNumber>0123456789</invoiceNumber></inv:processInvoice></soapenv:Body></soapenv:Envelope>
+ [java] 01:05:59,443 DEBUG [main][header] >> "POST / HTTP/1.1[\r][\n]"
+ [java] 01:05:59,464 DEBUG [main][header] >> "Content-Type: text/xml;charset=UTF-8[\r][\n]"
+ [java] 01:05:59,464 DEBUG [main][header] >> "SOAPAction: ""[\r][\n]"
+ [java] 01:05:59,465 DEBUG [main][header] >> "User-Agent: Jakarta Commons-HttpClient/3.0.1[\r][\n]"
+ [java] 01:05:59,465 DEBUG [main][header] >> "Host: localhost:9090[\r][\n]"
+ [java] 01:05:59,465 DEBUG [main][header] >> "Content-Length: 282[\r][\n]"
+ [java] 01:05:59,465 DEBUG [main][header] >> "[\r][\n]"
+ [java] 01:05:59,466 DEBUG [main][content] >> "<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:inv="http://webservice_proxy_versioning/invoicing"><soapenv:Header/><soapenv:Body><inv:processInvoice><invoiceNumber>0123456789</invoiceNumber></inv:processInvoice></soapenv:Body></soapenv:Envelope>"
+ [java] 01:05:59,574 DEBUG [main][header] << "HTTP/1.1 200 OK[\r][\n]"
+ [java] 01:05:59,577 DEBUG [main][header] << "Server: Apache-Coyote/1.1[\r][\n]"
+ [java] 01:05:59,577 DEBUG [main][header] << "X-Powered-By: Servlet 2.4; JBoss-4.2.3.GA (build: SVNTag=JBoss_4_2_3_GA date=200807181417)/JBossWeb-2.0[\r][\n]"
+ [java] 01:05:59,577 DEBUG [main][header] << "Date: Mon, 06 Jul 2009 06:05:59 GMT[\r][\n]"
+ [java] 01:05:59,577 DEBUG [main][header] << "Content-Type: text/xml;charset=UTF-8[\r][\n]"
+ [java] 01:05:59,578 DEBUG [main][header] << "Content-Length: 268[\r][\n]"
+ [java] **** RESPONSE CODE: 200
+ [java] 01:05:59,581 DEBUG [main][content] << "<env:Envelope xmlns:env='http://schemas.xmlsoap.org/soap/envelope/'><env:Header></env:Header><env:Body><ns2:processInvoiceResponse xmlns:ns2="http://webservice_proxy_versioning/invoicing"><success>true</success></ns2:processInvoiceResponse></env:Body></e"
+ [java] 01:05:59,581 DEBUG [main][content] << "nv:Envelope>"
+ [java] **** RESPONSE BODY: <env:Envelope xmlns:env='http://schemas.xmlsoap.org/soap/envelope/'><env:Header></env:Header><env:Body><ns2:processInvoiceResponse xmlns:ns2="http://webservice_proxy_versioning/invoicing"><success>true</success></ns2:processInvoiceResponse></env:Body></env:Envelope>
+
+ 'runnew' target description:
+ - This will exercise the target webservice *via* the SOAPProxy, first going through a JBoss Remoting Gateway Listener.
+ - Nothing interesting here; it is just like the webservice_proxy_basic quickstart.
+ - The request url is: http://localhost:9090
+ - Running it will create output like this in the server console:
+
+01:06:52,304 INFO [STDOUT] Message before SOAPProxy:
+01:06:52,304 INFO [STDOUT] [<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:inv="http://webservice_proxy_versioning/invoicing"><soapenv:Header/><soapenv:Body><inv:processInvoice><invoiceNumber>0123456789</invoiceNumber><processDate>2005-12-13T14:13:28.443+01:00</processDate></inv:processInvoice></soapenv:Body></soapenv:Envelope>].
+01:06:52,309 INFO [InvoicingWS] processInvoice called with invoiceNumber [0123456789] and processDate [Tue Dec 13 08:13:28 GMT-05:00 2005]
+01:06:52,311 INFO [STDOUT] Message after SOAPProxy:
+01:06:52,311 INFO [STDOUT] [<env:Envelope xmlns:env='http://schemas.xmlsoap.org/soap/envelope/'><env:Header></env:Header><env:Body><ns2:processInvoiceResponse xmlns:ns2="http://webservice_proxy_versioning/invoicing"><success>true</success></ns2:processInvoiceResponse></env:Body></env:Envelope>].
+
+ - And this in the client console:
+
+ [java] **** REQUEST URL: http://localhost:9999
+ [java] **** REQUEST BODY: <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:inv="http://webservice_proxy_versioning/invoicing"><soapenv:Header/><soapenv:Body><inv:processInvoice><invoiceNumber>0123456789</invoiceNumber><processDate>2005-12-13T14:13:28.443+01:00</processDate></inv:processInvoice></soapenv:Body></soapenv:Envelope>
+ [java] 01:06:52,210 DEBUG [main][header] >> "POST / HTTP/1.1[\r][\n]"
+ [java] 01:06:52,248 DEBUG [main][header] >> "Content-Type: text/xml;charset=UTF-8[\r][\n]"
+ [java] 01:06:52,249 DEBUG [main][header] >> "SOAPAction: ""[\r][\n]"
+ [java] 01:06:52,249 DEBUG [main][header] >> "User-Agent: Jakarta Commons-HttpClient/3.0.1[\r][\n]"
+ [java] 01:06:52,250 DEBUG [main][header] >> "Host: localhost:9999[\r][\n]"
+ [java] 01:06:52,250 DEBUG [main][header] >> "Content-Length: 338[\r][\n]"
+ [java] 01:06:52,250 DEBUG [main][header] >> "[\r][\n]"
+ [java] 01:06:52,251 DEBUG [main][content] >> "<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:inv="http://webservice_proxy_versioning/invoicing"><soapenv:Header/><soapenv:Body><inv:processInvoice><invoiceNumber>0123456789</invoiceNumber><processDate>2005-12-13T14:13:28.443+01:00</processDate></inv:processInvoice></soapenv:Body></soapenv:Envelope>"
+ [java] 01:06:52,312 DEBUG [main][header] << "HTTP/1.1 200 OK[\r][\n]"
+ [java] 01:06:52,314 DEBUG [main][header] << "Server: Apache-Coyote/1.1[\r][\n]"
+ [java] 01:06:52,314 DEBUG [main][header] << "X-Powered-By: Servlet 2.4; JBoss-4.2.3.GA (build: SVNTag=JBoss_4_2_3_GA date=200807181417)/JBossWeb-2.0[\r][\n]"
+ [java] 01:06:52,314 DEBUG [main][header] << "Date: Mon, 06 Jul 2009 06:06:52 GMT[\r][\n]"
+ [java] 01:06:52,314 DEBUG [main][header] << "Content-Type: text/xml;charset=UTF-8[\r][\n]"
+ [java] 01:06:52,314 DEBUG [main][header] << "Content-Length: 268[\r][\n]"
+ [java] **** RESPONSE CODE: 200
+ [java] 01:06:52,317 DEBUG [main][content] << "<env:Envelope xmlns:env='http://schemas.xmlsoap.org/soap/envelope/'><env:Header></env:Header><env:Body><ns2:processInvoiceResponse xmlns:ns2="http://webservice_proxy_versioning/invoicing"><success>true</success></ns2:processInvoiceResponse></env:Body></e"
+ [java] 01:06:52,318 DEBUG [main][content] << "nv:Envelope>"
+ [java] **** RESPONSE BODY: <env:Envelope xmlns:env='http://schemas.xmlsoap.org/soap/envelope/'><env:Header></env:Header><env:Body><ns2:processInvoiceResponse xmlns:ns2="http://webservice_proxy_versioning/invoicing"><success>true</success></ns2:processInvoiceResponse></env:Body></env:Envelope>
+
+Project file descriptions:
+==========================
+ jboss-esb.xml:
+ * the "Proxy_Versioning/Proxy-OldVersion" service's purpose is to
+ allow old webservice clients to continue using that old endpoint
+ without change. It uses an XsltAction to apply a transform on the
+ soap request (see Proxy_Versioning_RequestTransform.xsl below), and
+ also specifies:
+ - a wsdl to the new endpoint
+ - a wsdlTransform to transform the wsdl to what old clients are
+ expecting (see Proxy_Versioning_WsdlTransform.xml below).
+ * the "Proxy_Versioning/Proxy-NewVersion" service's purpose is to
+ simply allow new webservice clients to start using the new endpoint,
+ however still benefiting from the proxy abstracting the real endpoint
+ from them.
+
+ log4j.xml:
+ Needed to configure log4J used by the quickstart.
+
+ src/../SendWSMessage.java:
+ Sends a SOAP message to the target webservice endpoint (see "ant run*" above).
+
+ Proxy_Versioning_RequestTransform.xsl:
+ Tranforms the incoming SOAPRequest to the old service endpoint to it can be forwarded
+ along to the new service endpoint.
+ It uses Smooks to add the newly added <processDate> element.
+
+ Proxy_Versioning_WsdlTransform.xml:
+ Transforms the new service endpoing WSDL so it can be used in the old service endpoint.
+ It uses Smooks to remove the newly added <processDate> element.
+ http://localhost:8080/contract/contract.jsp?serviceCat=Proxy_Versioning&serviceName=Proxy-OldVersion&protocol=http
+
+ build.xml:
+ Targets and structure description:
+
+ * the runws task calls the
+ org.jboss.soa.esb.samples.quickstart.webservice_proxy_versioning.test.SendWSMessage class and
+ executes the real JBossWS webservice directly.
+
+ * the runold (also runtest) task calls the
+ org.jboss.soa.esb.samples.quickstart.webservice_proxy_versioning.test.SendWSMessage class and
+ executes the "Proxy_Versioning/Proxy-OldVersion" service (see jboss-esb.xml description above).
+
+ * the runnew task calls the
+ org.jboss.soa.esb.samples.quickstart.webservice_proxy_versioning.test.SendWSMessage class and
+ executes the "Proxy_Versioning/Proxy-NewVersion" service (see jboss-esb.xml description above).
+
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/readme.txt
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_versioning/test/SendWSMessage.java
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_versioning/test/SendWSMessage.java (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_versioning/test/SendWSMessage.java 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,98 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, JBoss Inc., and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+ * PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
+ * You should have received a copy of the GNU Lesser General Public License,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ *
+ * (C) 2005-2009
+ */
+package org.jboss.soa.esb.samples.quickstart.webservice_proxy_versioning.test;
+
+import java.io.InputStream;
+
+import org.apache.commons.httpclient.HttpClient;
+import org.apache.commons.httpclient.methods.PostMethod;
+import org.apache.commons.httpclient.methods.StringRequestEntity;
+import org.jboss.internal.soa.esb.util.StreamUtils;
+
+/**
+ * Sends a simple webservice request to the proxied webservice, printing both the request and the response to the console.
+ *
+ * @author dward at jboss.org
+ */
+public class SendWSMessage
+{
+
+ private static final String SOAP_PRE =
+ "<soapenv:Envelope xmlns:soapenv=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:inv=\"http://webservice_proxy_versioning/invoicing\">" +
+ "<soapenv:Header/>" +
+ "<soapenv:Body>" +
+ "<inv:processInvoice>" +
+ "<invoiceNumber>0123456789</invoiceNumber>";
+
+ private static final String SOAP_POST =
+ "</inv:processInvoice>" +
+ "</soapenv:Body>" +
+ "</soapenv:Envelope>";
+
+ // see product/samples/quickstarts/webservice_proxy_versioning/build.xml
+ public static void main(String... args) throws Exception
+ {
+ if (args.length < 2)
+ {
+ // for testing main method from Eclipse (build.xml passes these args in)
+ args = new String[2];
+ //args[0] = "http://localhost:8080/Quickstart_webservice_proxy_versioning/InvoicingWS"; // original ws ("ant runws")
+ args[0] = "http://localhost:9090"; // the old ws format ("ant runold" or "ant runtest")
+ //args[0] = "http://localhost:9999"; // the new ws format ("ant runnew")
+ args[1] = "old";
+ }
+
+ String url = args[0];
+ System.out.println("**** REQUEST URL: " + url);
+ PostMethod method = new PostMethod(url);
+ method.setRequestHeader("Content-Type", "text/xml;charset=UTF-8");
+
+ // this line should be used for better performance/interop but is not necessary
+ // http://www.w3.org/TR/2000/NOTE-SOAP-20000508/#_Toc478383528
+ // http://www.ws-i.org/Profiles/BasicProfile-1.1.html#SOAPAction_HTTP_Header
+ method.setRequestHeader("SOAPAction", "\"\"");
+
+ boolean old = "old".equals(args[1]);
+ String request = SOAP_PRE + (old ? "" : "<processDate>2005-12-13T14:13:28.443+01:00</processDate>") + SOAP_POST;
+ System.out.println("**** REQUEST BODY: " + request);
+ method.setRequestEntity( new StringRequestEntity(request) );
+
+ HttpClient client = new HttpClient();
+ InputStream response = null;
+ try
+ {
+ int code = client.executeMethod(method);
+ System.out.println("**** RESPONSE CODE: " + code);
+
+ response = method.getResponseBodyAsStream();
+ byte[] bytes = StreamUtils.readStream(response);
+ System.out.println("**** RESPONSE BODY: " + new String(bytes, method.getResponseCharSet()));
+ }
+ finally
+ {
+ method.releaseConnection();
+ if (response != null)
+ {
+ response.close();
+ }
+ }
+ }
+
+}
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_versioning/test/SendWSMessage.java
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/resources/WEB-INF/web.xml
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/resources/WEB-INF/web.xml (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/resources/WEB-INF/web.xml 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<web-app 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/web-app_2_4.xsd" version="2.4">
+
+ <servlet>
+ <servlet-name>InvoicingWS</servlet-name>
+ <servlet-class>org.jboss.soa.esb.samples.quickstart.webservice_proxy_versioning.InvoicingWS</servlet-class>
+ </servlet>
+
+ <servlet-mapping>
+ <servlet-name>InvoicingWS</servlet-name>
+ <url-pattern>/InvoicingWS</url-pattern>
+ </servlet-mapping>
+
+</web-app>
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/resources/WEB-INF/web.xml
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_versioning/InvoicingWS.java
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_versioning/InvoicingWS.java (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_versioning/InvoicingWS.java 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,55 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, JBoss Inc., and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+ * PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
+ * You should have received a copy of the GNU Lesser General Public License,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ *
+ * (C) 2005-2009
+ */
+package org.jboss.soa.esb.samples.quickstart.webservice_proxy_versioning;
+
+import java.util.Date;
+
+import javax.jws.WebMethod;
+import javax.jws.WebParam;
+import javax.jws.WebResult;
+import javax.jws.WebService;
+
+import org.apache.log4j.Logger;
+
+/**
+ * Simple rpc-style webservice that returns invoice processing success.
+ *
+ * @author dward at jboss.org
+ */
+ at WebService(name = "Invoicing", targetNamespace = "http://webservice_proxy_versioning/invoicing")
+public class InvoicingWS
+{
+
+ private static Logger logger = Logger.getLogger(InvoicingWS.class);
+
+ @WebMethod
+ @WebResult(name="success")
+ public Boolean processInvoice(
+ @WebParam(name="invoiceNumber") String invoiceNumber,
+ @WebParam(name="processDate") Date processDate )
+ {
+ if ( logger.isInfoEnabled() )
+ {
+ logger.info("processInvoice called with invoiceNumber [" + invoiceNumber + "] and processDate [" + processDate + "]");
+ }
+ return (processDate != null ? Boolean.TRUE : Boolean.FALSE);
+ }
+
+}
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/src/org/jboss/soa/esb/samples/quickstart/webservice_proxy_versioning/InvoicingWS.java
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Added: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/view/index.jsp
===================================================================
--- labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/view/index.jsp (rev 0)
+++ labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/view/index.jsp 2009-07-14 18:32:14 UTC (rev 28016)
@@ -0,0 +1,9 @@
+<html>
+ <body>
+ This is just a place holder.<br>
+ Verify the that the WS has been deployed by hitting
+ <a href="http://localhost:8080/jbossws">
+ http://localhost:8080/jbossws
+ </a>
+ </body>
+</html>
\ No newline at end of file
Property changes on: labs/jbossesb/trunk/product/samples/quickstarts/webservice_proxy_versioning/war/view/index.jsp
___________________________________________________________________
Name: svn:keywords
+ Id
Name: svn:eol-style
+ native
Modified: labs/jbossesb/trunk/product/services/soap/src/main/java/org/jboss/soa/esb/actions/soap/proxy/SOAPProxy.java
===================================================================
--- labs/jbossesb/trunk/product/services/soap/src/main/java/org/jboss/soa/esb/actions/soap/proxy/SOAPProxy.java 2009-07-14 18:12:35 UTC (rev 28015)
+++ labs/jbossesb/trunk/product/services/soap/src/main/java/org/jboss/soa/esb/actions/soap/proxy/SOAPProxy.java 2009-07-14 18:32:14 UTC (rev 28016)
@@ -66,13 +66,15 @@
* <li><b>wsdl</b> (required): The original wsdl {@link URL url} whose WS endpoint will get re-written and exposed as new wsdl from
* the ESB. Depending upon the <definitions><service><port><soap:address location attribute's protocol (for
* example "http"), a protocol-specific {@link SOAPProxyTransport} implementation is used.</li>
+ * <li><b>wsdlTransform</b> (optional): A <smooks-resource-list> xml config file allowing for flexible wsdl transformation.</li>
+ * <li><b>*</b> (optional): Any of the HttpRouter properties can be applied, if the wsdl specifies an http transport.</li>
* </ol>
- * For other possible configuration properties, see the specific {@link SOAPProxyTransport} implementations themselves.<p/>
+ * * For other possible configuration properties, see the specific {@link SOAPProxyTransport} implementations themselves.<p/>
*
* <i>Example:</i><br/>
* <pre>
- * <action name="wsproxy" class="org.jboss.soa.esb.actions.soap.proxy.SOAPProxy">
- * <property name="wsdl" value="http://127.0.0.1:8080/path/HelloWorldWebService?wsdl"/> <!-- required -->
+ * <action name="proxy" class="org.jboss.soa.esb.actions.soap.proxy.SOAPProxy">
+ * <property name="wsdl" value="http://localhost:8080/path/HelloWorldWebService?wsdl"/> <!-- required -->
* </action>
* </pre>
*
More information about the jboss-svn-commits
mailing list