[jboss-svn-commits] JBL Code SVN: r23576 - in labs/jbossesb/branches/JBESB_4_4_GA_CP/product: rosetta/src/org/jboss/internal/soa/esb/util and 13 other directories.
jboss-svn-commits at lists.jboss.org
jboss-svn-commits at lists.jboss.org
Fri Oct 24 06:29:14 EDT 2008
Author: tfennelly
Date: 2008-10-24 06:29:13 -0400 (Fri, 24 Oct 2008)
New Revision: 23576
Added:
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/rosetta/src/org/jboss/internal/soa/esb/util/NullWriter.java
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/rosetta/src/org/jboss/internal/soa/esb/webservice/ESBResponseFilter.java
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/build.xml
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/deployment.xml
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/error-soap-message.xml
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/fault.xsd
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/jbm-queue-service.xml
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/jbmq-queue-service.xml
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/jboss-esb.xml
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/jbossesb-properties.xml
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/jndi.properties
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/juddi.properties
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/lib/
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/listener.log
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/log4j.xml
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/readme.txt
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/request.xsd
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/soap-userpass-message.xml
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/.classpath
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/.project
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/org/
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/org/jboss/
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/org/jboss/soa/
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/org/jboss/soa/esb/
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/org/jboss/soa/esb/samples/
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/org/jboss/soa/esb/samples/quickstart/
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/org/jboss/soa/esb/samples/quickstart/publishAsWebservice/
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/org/jboss/soa/esb/samples/quickstart/publishAsWebservice/ESBWSListenerAction.java
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/org/jboss/soa/esb/samples/quickstart/publishAsWebservice/test/
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/org/jboss/soa/esb/samples/quickstart/publishAsWebservice/test/SOAPTest.java
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/org/jboss/soa/esb/samples/quickstart/publishAsWebservice/test/SendEsbMessage.java
Modified:
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/rosetta/build.xml
labs/jbossesb/branches/JBESB_4_4_GA_CP/product/rosetta/src/org/jboss/soa/esb/listeners/config/JBoss4ESBDeployer.java
Log:
EBWS One way MEP does not conform to standard: https://jira.jboss.org/jira/browse/JBESB-2089
Modified: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/rosetta/build.xml
===================================================================
--- labs/jbossesb/branches/JBESB_4_4_GA_CP/product/rosetta/build.xml 2008-10-24 10:03:12 UTC (rev 23575)
+++ labs/jbossesb/branches/JBESB_4_4_GA_CP/product/rosetta/build.xml 2008-10-24 10:29:13 UTC (rev 23576)
@@ -92,6 +92,7 @@
>
<fileset dir="${org.jboss.esb.rosetta.src.dir}" includes="**/*.groovy"/>
<fileset dir="${org.jboss.esb.rosetta.src.dir}" includes="**/*.properties"/>
+ <fileset dir="${org.jboss.esb.rosetta.src.dir}" includes="**/*.ftl"/>
<fileset dir="${org.jboss.esb.rosetta.src.dir}" includes="org/jboss/soa/esb/services/security/auth/ws/smooks-ws-security.xml"/>
</jar>
Added: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/rosetta/src/org/jboss/internal/soa/esb/util/NullWriter.java
===================================================================
--- labs/jbossesb/branches/JBESB_4_4_GA_CP/product/rosetta/src/org/jboss/internal/soa/esb/util/NullWriter.java (rev 0)
+++ labs/jbossesb/branches/JBESB_4_4_GA_CP/product/rosetta/src/org/jboss/internal/soa/esb/util/NullWriter.java 2008-10-24 10:29:13 UTC (rev 23576)
@@ -0,0 +1,84 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, 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-2008, JBoss Inc.
+ */
+package org.jboss.internal.soa.esb.util;
+
+import java.io.Writer;
+import java.io.IOException;
+
+/**
+ * Null {@link Writer}.
+ *
+ * @author <a href="mailto:tom.fennelly at jboss.com">tom.fennelly at jboss.com</a>
+ */
+public class NullWriter extends Writer {
+
+ public NullWriter() {
+ super();
+ }
+
+ public NullWriter(Object lock) {
+ super(lock);
+ }
+
+ public void write() throws IOException {
+
+ }
+
+ public void write(int c) throws IOException {
+ write();
+ }
+
+ public void write(char cbuf[]) throws IOException {
+ write();
+ }
+
+ public void write(String str) throws IOException {
+ write();
+ }
+
+ public void write(String str, int off, int len) throws IOException {
+ write();
+ }
+
+ public Writer append(CharSequence csq) throws IOException {
+ write();
+ return this;
+ }
+
+ public Writer append(CharSequence csq, int start, int end) throws IOException {
+ write();
+ return this;
+ }
+
+ public Writer append(char c) throws IOException {
+ write();
+ return this;
+ }
+
+ public void write(char cbuf[], int off, int len) throws IOException {
+ write();
+ }
+
+ public void flush() throws IOException {
+ }
+
+ public void close() throws IOException {
+ }
+}
Property changes on: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/rosetta/src/org/jboss/internal/soa/esb/util/NullWriter.java
___________________________________________________________________
Name: svn:eol-style
+ native
Added: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/rosetta/src/org/jboss/internal/soa/esb/webservice/ESBResponseFilter.java
===================================================================
--- labs/jbossesb/branches/JBESB_4_4_GA_CP/product/rosetta/src/org/jboss/internal/soa/esb/webservice/ESBResponseFilter.java (rev 0)
+++ labs/jbossesb/branches/JBESB_4_4_GA_CP/product/rosetta/src/org/jboss/internal/soa/esb/webservice/ESBResponseFilter.java 2008-10-24 10:29:13 UTC (rev 23576)
@@ -0,0 +1,88 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, 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-2008, JBoss Inc.
+ */
+package org.jboss.internal.soa.esb.webservice;
+
+import org.jboss.internal.soa.esb.util.NullWriter;
+
+import javax.servlet.*;
+import javax.servlet.http.HttpServletResponseWrapper;
+import javax.servlet.http.HttpServletResponse;
+import java.io.IOException;
+import java.io.PrintWriter;
+
+/**
+ * Webservice response filter.
+ *
+ * @author <a href="mailto:tom.fennelly at jboss.com">tom.fennelly at jboss.com</a>
+ */
+public class ESBResponseFilter implements Filter {
+
+ private boolean isOneWay = false;
+
+ public void init(FilterConfig filterConfig) throws ServletException {
+ String oneWayConfig = filterConfig.getInitParameter("OneWay");
+ isOneWay = "true".equalsIgnoreCase(oneWayConfig);
+ }
+
+ public void doFilter(ServletRequest servletRequest, ServletResponse servletResponse, FilterChain filterChain) throws IOException, ServletException {
+ if(isOneWay) {
+ filterChain.doFilter(servletRequest, new OneWayResponseWrapper((HttpServletResponse) servletResponse));
+ servletResponse.setContentType("text/xml");
+ servletResponse.setContentLength(0);
+ } else {
+ filterChain.doFilter(servletRequest, servletResponse);
+ }
+ }
+
+ public void destroy() {
+ }
+
+ /**
+ * OneWay response wrapper.
+ * <p/>
+ * Filters out the response i.e. ensures that the response body is empty.
+ */
+ private class OneWayResponseWrapper extends HttpServletResponseWrapper {
+
+ public OneWayResponseWrapper(HttpServletResponse httpServletResponse) {
+ super(httpServletResponse);
+ }
+
+ public PrintWriter getWriter() throws IOException {
+ return new PrintWriter(new NullWriter());
+ }
+
+ public ServletOutputStream getOutputStream() throws IOException {
+ return new NullServletOutputStream();
+ }
+ }
+
+ /**
+ * Null {@link ServletOutputStream}.
+ */
+ private class NullServletOutputStream extends ServletOutputStream {
+ public void write(int b) throws IOException {
+ }
+ public void write(byte b[]) throws IOException {
+ }
+ public void write(byte b[], int off, int len) throws IOException {
+ }
+ }
+}
Property changes on: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/rosetta/src/org/jboss/internal/soa/esb/webservice/ESBResponseFilter.java
___________________________________________________________________
Name: svn:eol-style
+ native
Modified: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/rosetta/src/org/jboss/soa/esb/listeners/config/JBoss4ESBDeployer.java
===================================================================
--- labs/jbossesb/branches/JBESB_4_4_GA_CP/product/rosetta/src/org/jboss/soa/esb/listeners/config/JBoss4ESBDeployer.java 2008-10-24 10:03:12 UTC (rev 23575)
+++ labs/jbossesb/branches/JBESB_4_4_GA_CP/product/rosetta/src/org/jboss/soa/esb/listeners/config/JBoss4ESBDeployer.java 2008-10-24 10:29:13 UTC (rev 23576)
@@ -49,10 +49,7 @@
import org.jboss.deployment.SubDeployerSupport;
import org.jboss.internal.soa.esb.publish.ContractReferencePublisher;
import org.jboss.internal.soa.esb.util.XMLHelper;
-import org.jboss.internal.soa.esb.webservice.ESBContractGenerator;
-import org.jboss.internal.soa.esb.webservice.ESBServiceContractPublisher;
-import org.jboss.internal.soa.esb.webservice.ESBServiceEndpointInfo;
-import org.jboss.internal.soa.esb.webservice.JAXWSProviderClassGenerator;
+import org.jboss.internal.soa.esb.webservice.*;
import org.jboss.logging.Logger;
import org.jboss.metadata.MetaData;
import org.jboss.metadata.XmlFileLoader;
@@ -61,6 +58,7 @@
import org.jboss.mx.util.ObjectNameConverter;
import org.jboss.soa.esb.lifecycle.LifecycleResourceManager;
import org.jboss.soa.esb.listeners.config.xbeanmodel.JbossesbDocument;
+import org.jboss.soa.esb.listeners.config.xbeanmodel.MepType;
import org.jboss.soa.esb.listeners.config.xbeanmodel.ActionDocument.Action;
import org.jboss.soa.esb.listeners.config.xbeanmodel.ActionsDocument.Actions;
import org.jboss.soa.esb.listeners.config.xbeanmodel.JbossesbDocument.Jbossesb;
@@ -489,8 +487,10 @@
if (endpointServices.size() > 0)
{
- final StringWriter servletDefinition = new StringWriter() ;
- final StringWriter servletMapping = new StringWriter() ;
+ final StringWriter filterDefinitions = new StringWriter() ;
+ final StringWriter filterMappings = new StringWriter() ;
+ final StringWriter servletDefinitions = new StringWriter() ;
+ final StringWriter servletMappings = new StringWriter() ;
final ByteArrayOutputStream baos = new ByteArrayOutputStream() ;
final ZipOutputStream zos = new ZipOutputStream(baos) ;
@@ -501,6 +501,7 @@
for(Service service: endpointServices)
{
+ final MepType.Enum mep = service.getActions().getMep() ;
final ESBServiceEndpointInfo serviceInfo = new ESBServiceEndpointInfo(service) ;
final String wsdl = ESBContractGenerator.generateWSDL(service, serviceInfo) ;
addFile(zos, serviceInfo.getWSDLFileName(), wsdl) ;
@@ -509,19 +510,41 @@
service.getName(), serviceInfo) ;
final String wsClassName = serviceInfo.getClassName().replace('.', '/') + ".class" ;
addFile(zos, "WEB-INF/classes/" + wsClassName, wsClass) ;
+
+ // Filter...
+ // At the moment we only need the filter to overcome a bug in JBossWS re In-Only endpoints, so
+ // we only include for one way services...
+ if(mep == MepType.ONE_WAY) {
+ String filterName = serviceInfo.getServletName() + "_Filter";
+
+ filterDefinitions.append("<filter><filter-name>") ;
+ filterDefinitions.append(filterName) ;
+ filterDefinitions.append("</filter-name><filter-class>") ;
+ filterDefinitions.append(ESBResponseFilter.class.getName()) ;
+ filterDefinitions.append("</filter-class>") ;
+ filterDefinitions.append("<init-param><param-name>OneWay</param-name><param-value>true</param-value></init-param>") ;
+ filterDefinitions.append("</filter>") ;
+
+ filterMappings.append("<filter-mapping><filter-name>") ;
+ filterMappings.append(filterName) ;
+ filterMappings.append("</filter-name><servlet-name>") ;
+ filterMappings.append(serviceInfo.getServletName()) ;
+ filterMappings.append("</servlet-name></filter-mapping>") ;
+ }
+
+ // Servlet....
+ servletDefinitions.append("<servlet><servlet-name>") ;
+ servletDefinitions.append(serviceInfo.getServletName()) ;
+ servletDefinitions.append("</servlet-name><servlet-class>") ;
+ servletDefinitions.append(serviceInfo.getClassName()) ;
+ servletDefinitions.append("</servlet-class></servlet>") ;
- servletDefinition.append("<servlet><servlet-name>") ;
- servletDefinition.append(serviceInfo.getServletName()) ;
- servletDefinition.append("</servlet-name><servlet-class>") ;
- servletDefinition.append(serviceInfo.getClassName()) ;
- servletDefinition.append("</servlet-class></servlet>") ;
+ servletMappings.append("<servlet-mapping><servlet-name>") ;
+ servletMappings.append(serviceInfo.getServletName()) ;
+ servletMappings.append("</servlet-name><url-pattern>") ;
+ servletMappings.append(serviceInfo.getServletPath()) ;
+ servletMappings.append("</url-pattern></servlet-mapping>") ;
- servletMapping.append("<servlet-mapping><servlet-name>") ;
- servletMapping.append(serviceInfo.getServletName()) ;
- servletMapping.append("</servlet-name><url-pattern>") ;
- servletMapping.append(serviceInfo.getServletPath()) ;
- servletMapping.append("</url-pattern></servlet-mapping>") ;
-
final org.jboss.soa.esb.Service esbService = new org.jboss.soa.esb.Service(service.getCategory(), service.getName()) ;
final ContractReferencePublisher publisher = new ESBServiceContractPublisher(esbService, service.getDescription(), serviceInfo.getServletName()) ;
publishers.add(publisher) ;
@@ -530,8 +553,10 @@
final StringWriter webXml = new StringWriter() ;
webXml.append("<web-app xmlns=\"http://java.sun.com/xml/ns/j2ee\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"") ;
webXml.append(" xsi:schemaLocation=\"http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd\" version=\"2.4\">") ;
- webXml.append(servletDefinition.getBuffer()) ;
- webXml.append(servletMapping.getBuffer()) ;
+ webXml.append(filterDefinitions.getBuffer()) ;
+ webXml.append(filterMappings.getBuffer()) ;
+ webXml.append(servletDefinitions.getBuffer()) ;
+ webXml.append(servletMappings.getBuffer()) ;
webXml.append("</web-app>") ;
addFile(zos, "WEB-INF/web.xml", webXml.toString()) ;
Added: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/build.xml
===================================================================
--- labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/build.xml (rev 0)
+++ labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/build.xml 2008-10-24 10:29:13 UTC (rev 23576)
@@ -0,0 +1,45 @@
+<project name="Quickstart_publish_as_webservice_inonly" default="run" basedir=".">
+
+ <description>
+ ${ant.project.name}
+ ${line.separator}
+ </description>
+
+ <!-- additional deploys -->
+ <property name="additional.deploys" value="*.xsd"/>
+
+ <!-- Import the base Ant build script... -->
+ <import file="../conf/base-build.xml"/>
+ <target name="runtest" depends="compile" description="sends soap message to published web service">
+ <echo>Send soap message to published web service and receive reponse</echo>
+ <java fork="yes" classname="org.jboss.soa.esb.samples.quickstart.publishAsWebservice.test.SOAPTest" failonerror="true">
+ <arg value="soap-userpass-message.xml"/>
+ <classpath refid="exec-classpath"/>
+ </java>
+ <echo/>
+ <echo/>
+ <echo>Send soap message to published web service and receive soap fault message</echo>
+ <java fork="yes" classname="org.jboss.soa.esb.samples.quickstart.publishAsWebservice.test.SOAPTest" failonerror="true">
+ <arg value="error-soap-message.xml"/>
+ <classpath refid="exec-classpath"/>
+ </java>
+ </target>
+
+ <target name="sendesb" depends="compile" description="send esb Message to esb service">
+ <echo>Send esb message to esb service and get response</echo>
+ <java fork="yes" classname="org.jboss.soa.esb.samples.quickstart.publishAsWebservice.test.SendEsbMessage" failonerror="true">
+ <arg value="ESBServiceSample"/> <!-- service category -->
+ <arg value="HelloWorldPubService"/> <!-- service name -->
+ <arg value="HelloWorld"/> <!-- Message text -->
+ <classpath refid="exec-classpath"/>
+ </java>
+ <echo>Send esb message to esb service and get error</echo>
+ <java fork="yes" classname="org.jboss.soa.esb.samples.quickstart.publishAsWebservice.test.SendEsbMessage" failonerror="true">
+ <arg value="ESBServiceSample"/> <!-- service category -->
+ <arg value="HelloWorldPubService"/> <!-- service name -->
+ <arg value="Error"/> <!-- Message text -->
+ <classpath refid="exec-classpath"/>
+ </java>
+
+ </target>
+</project>
Property changes on: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/build.xml
___________________________________________________________________
Name: svn:mime-type
+ text/xml
Name: svn:eol-style
+ native
Added: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/deployment.xml
===================================================================
--- labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/deployment.xml (rev 0)
+++ labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/deployment.xml 2008-10-24 10:29:13 UTC (rev 23576)
@@ -0,0 +1,5 @@
+<jbossesb-deployment>
+ <depends>jboss.esb:deployment=soap.esb</depends>
+ <depends>jboss.esb.quickstart.destination:service=Queue,name=quickstart_publish_as_webservice_inonly_Request_esb</depends>
+ <depends>jboss.esb.quickstart.destination:service=Queue,name=quickstart_publish_as_webservice_inonly_Request_esb_reply</depends>
+</jbossesb-deployment>
Property changes on: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/deployment.xml
___________________________________________________________________
Name: svn:mime-type
+ text/xml
Name: svn:eol-style
+ native
Added: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/error-soap-message.xml
===================================================================
--- labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/error-soap-message.xml (rev 0)
+++ labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/error-soap-message.xml 2008-10-24 10:29:13 UTC (rev 23576)
@@ -0,0 +1,9 @@
+<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:say="http://www.jboss.org/sayHi">
+ <soap:Body>
+ <say:sayHi><say:arg0>Error</say:arg0></say:sayHi>
+ </soap:Body>
+
+</soap:Envelope>
Property changes on: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/error-soap-message.xml
___________________________________________________________________
Name: svn:mime-type
+ text/xml
Name: svn:eol-style
+ native
Added: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/fault.xsd
===================================================================
--- labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/fault.xsd (rev 0)
+++ labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/fault.xsd 2008-10-24 10:29:13 UTC (rev 23576)
@@ -0,0 +1,9 @@
+<xs:schema version="1.0" targetNamespace="http://www.jboss.org/sayHi" xmlns:x1="http://www.jboss.org/sayHi" xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified">
+ <xs:element name="sayFault" type="x1:fault"/>
+ <xs:complexType name="fault">
+ <xs:sequence>
+ <xs:element name="code" type="xs:string"/>
+ <xs:element name="faultString" type="xs:string"/>
+ </xs:sequence>
+ </xs:complexType>
+</xs:schema>
\ No newline at end of file
Property changes on: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/fault.xsd
___________________________________________________________________
Name: svn:mime-type
+ text/xml
Name: svn:eol-style
+ native
Added: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/jbm-queue-service.xml
===================================================================
--- labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/jbm-queue-service.xml (rev 0)
+++ labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/jbm-queue-service.xml 2008-10-24 10:29:13 UTC (rev 23576)
@@ -0,0 +1,15 @@
+<?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_publish_as_webservice_inonly_Request_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_publish_as_webservice_inonly_Request_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/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/jbm-queue-service.xml
___________________________________________________________________
Name: svn:mime-type
+ text/xml
Name: svn:eol-style
+ native
Added: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/jbmq-queue-service.xml
===================================================================
--- labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/jbmq-queue-service.xml (rev 0)
+++ labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/jbmq-queue-service.xml 2008-10-24 10:29:13 UTC (rev 23576)
@@ -0,0 +1,15 @@
+<?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_publish_as_webservice_inonly_Request_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_publish_as_webservice_inonly_Request_esb_reply">
+ <depends optional-attribute-name="DestinationManager">
+ jboss.mq:service=DestinationManager
+ </depends>
+ </mbean>
+</server>
Property changes on: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/jbmq-queue-service.xml
___________________________________________________________________
Name: svn:mime-type
+ text/xml
Name: svn:eol-style
+ native
Added: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/jboss-esb.xml
===================================================================
--- labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/jboss-esb.xml (rev 0)
+++ labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/jboss-esb.xml 2008-10-24 10:29:13 UTC (rev 23576)
@@ -0,0 +1,34 @@
+<?xml version = "1.0" encoding = "UTF-8"?>
+<jbossesb xmlns="http://anonsvn.labs.jboss.com/labs/jbossesb/trunk/product/etc/schemas/xml/jbossesb-1.0.1.xsd" parameterReloadSecs="5">
+
+ <providers>
+ <jms-provider name="JBossMQ" connection-factory="ConnectionFactory">
+ <jms-bus busid="quickstartEsbChannel">
+ <jms-message-filter
+ dest-type="QUEUE"
+ dest-name="queue/quickstart_publish_as_webservice_inonly_Request_esb"
+ selector="serviceName='HelloWorldPubService'"
+ />
+ </jms-bus>
+
+ </jms-provider>
+ </providers>
+
+ <services>
+ <service
+ category="ESBServiceSample"
+ name="HelloWorldPubService"
+ description="Hello world ESB Service">
+ <listeners>
+ <jms-listener name="helloWorld"
+ busidref="quickstartEsbChannel"
+ maxThreads="1"
+ />
+ </listeners>
+ <actions mep="OneWay" inXsd="/request.xsd" faultXsd="/fault.xsd" >
+ <action name="action" class="org.jboss.soa.esb.samples.quickstart.publishAsWebservice.ESBWSListenerAction" process="displayMessage"/>
+ </actions>
+ </service>
+ </services>
+
+</jbossesb>
Property changes on: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/jboss-esb.xml
___________________________________________________________________
Name: svn:mime-type
+ text/xml
Name: svn:eol-style
+ native
Added: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/jbossesb-properties.xml
===================================================================
--- labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/jbossesb-properties.xml (rev 0)
+++ labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/jbossesb-properties.xml 2008-10-24 10:29:13 UTC (rev 23576)
@@ -0,0 +1,86 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<!--
+ 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-2006,
+ @author JBoss Inc.
+-->
+<!-- $Id: jbossesb-unittest-properties.xml $ -->
+<!--
+ These options are described in the JBossESB manual.
+ Defaults are provided here for convenience only.
+
+ Please read through this file prior to using the system, and consider
+ updating the specified entries.
+-->
+<esb
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:noNamespaceSchemaLocation="jbossesb-1_0.xsd">
+ <properties name="core">
+ <property name="org.jboss.soa.esb.jndi.server.type" value="jboss"/>
+ <property name="org.jboss.soa.esb.jndi.server.url" value="localhost"/>
+ <property name="org.jboss.soa.esb.persistence.connection.factory" value="org.jboss.internal.soa.esb.persistence.format.MessageStoreFactoryImpl"/>
+ <property name="jboss.esb.invm.scope.default" value="NONE"/>
+ </properties>
+ <properties name="registry">
+ <property name="org.jboss.soa.esb.registry.queryManagerURI"
+ value="jnp://localhost:1099/InquiryService?org.apache.juddi.registry.rmi.Inquiry#inquire"/>
+ <property name="org.jboss.soa.esb.registry.lifeCycleManagerURI"
+ value="jnp://localhost:1099/PublishService?org.apache.juddi.registry.rmi.Publish#publish" />
+ <property name="org.jboss.soa.esb.registry.implementationClass"
+ value="org.jboss.internal.soa.esb.services.registry.JAXRRegistryImpl"/>
+ <property name="org.jboss.soa.esb.registry.factoryClass"
+ value="org.apache.ws.scout.registry.ConnectionFactoryImpl"/>
+ <property name="org.jboss.soa.esb.registry.user"
+ value="jbossesb"/>
+ <property name="org.jboss.soa.esb.registry.password"
+ value="password"/>
+ <!-- the following parameter is scout specific to set the type of communication between scout and the UDDI (embedded, rmi, soap) -->
+ <property name="org.jboss.soa.esb.scout.proxy.transportClass"
+ value="org.apache.ws.scout.transport.RMITransport"/>
+ </properties>
+ <properties name="transports" depends="core">
+ <property name="org.jboss.soa.esb.mail.smtp.host" value="localhost"/>
+ <property name="org.jboss.soa.esb.mail.smtp.user" value="jbossesb"/>
+ <property name="org.jboss.soa.esb.mail.smtp.password" value=""/>
+ <property name="org.jboss.soa.esb.mail.smtp.port" value="25"/>
+ </properties>
+ <properties name="connection">
+ <property name="min-pool-size" value="5"/>
+ <property name="max-pool=size" value="10"/>
+ <property name="blocking-timeout-millis" value="5000"/>
+ <property name="abandoned-connection-timeout" value="10000"/>
+ <property name="abandoned-connection-time-interval" value="30000"/>
+ </properties>
+ <properties name="dbstore">
+ <property name="org.jboss.soa.esb.persistence.db.connection.url" value="jdbc:hsqldb:hsql://localhost:9001/"/>
+ <property name="org.jboss.soa.esb.persistence.db.jdbc.driver" value="org.hsqldb.jdbcDriver"/>
+ <property name="org.jboss.soa.esb.persistence.db.user" value="sa"/>
+ <property name="org.jboss.soa.esb.persistence.db.pwd" value=""/>
+ <property name="org.jboss.soa.esb.persistence.db.pool.initial.size" value="2"/>
+ <property name="org.jboss.soa.esb.persistence.db.pool.min.size" value="2"/>
+ <property name="org.jboss.soa.esb.persistence.db.pool.max.size" value="5"/>
+ <!--table managed by pool to test for valid connections - created by pool automatically -->
+ <property name="org.jboss.soa.esb.persistence.db.pool.test.table" value="pooltest"/>
+ <!-- # of milliseconds to timeout waiting for a connection from pool -->
+ <property name="org.jboss.soa.esb.persistence.db.pool.timeout.millis" value="5000"/>
+ <property name="org.jboss.soa.esb.persistence.db.conn.manager" value="org.jboss.internal.soa.esb.persistence.manager.StandaloneConnectionManager"/>
+ </properties>
+ <properties name="messagerouting">
+ <property name="org.jboss.soa.esb.routing.cbrClass" value="org.jboss.internal.soa.esb.services.routing.cbr.JBossRulesRouter"/>
+ </properties>
+</esb>
Property changes on: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/jbossesb-properties.xml
___________________________________________________________________
Name: svn:mime-type
+ text/xml
Name: svn:eol-style
+ native
Added: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/jndi.properties
===================================================================
--- labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/jndi.properties (rev 0)
+++ labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/jndi.properties 2008-10-24 10:29:13 UTC (rev 23576)
@@ -0,0 +1,5 @@
+java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory
+java.naming.provider.url=jnp://localhost:1099
+java.naming.factory.url.pkgs=org.jboss.naming
+java.naming.factory.url.pkgs=org.jnp.interfaces
+
Property changes on: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/jndi.properties
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Name: svn:eol-style
+ native
Added: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/juddi.properties
===================================================================
--- labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/juddi.properties (rev 0)
+++ labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/juddi.properties 2008-10-24 10:29:13 UTC (rev 23576)
@@ -0,0 +1,69 @@
+# jUDDI Registry Properties (used by RegistryServer)
+# see http://www.juddi.org for more information
+
+# The UDDI Operator Name
+juddi.operatorName = jUDDI.org
+
+# The i18n locale default codes
+juddi.i18n.languageCode = en
+juddi.i18n.countryCode = US
+
+# The UDDI DiscoveryURL Prefix
+juddi.discoveryURL = http://localhost:8080/juddi/uddiget.jsp?
+
+# The UDDI Operator Contact Email Address
+juddi.operatorEmailAddress = admin at juddi.org
+
+# The maximum name size and maximum number
+# of name elements allows in several of the
+# FindXxxx and SaveXxxx UDDI functions.
+juddi.maxNameLength=255
+juddi.maxNameElementsAllowed=5
+
+# The maximum number of UDDI artifacts allowed
+# per publisher. A value of '-1' indicates any
+# number of artifacts is valid (These values can be
+# overridden at the individual publisher level).
+juddi.maxBusinessesPerPublisher=25
+juddi.maxServicesPerBusiness=20
+juddi.maxBindingsPerService=10
+juddi.maxTModelsPerPublisher=100
+
+# jUDDI Authentication module to use
+juddi.auth = org.apache.juddi.auth.DefaultAuthenticator
+
+# jUDDI DataStore module currently to use
+juddi.dataStore = org.apache.juddi.datastore.jdbc.JDBCDataStore
+
+# use a dataSource (if set to false a direct
+# jdbc connection will be used.
+juddi.isUseDataSource=false
+juddi.jdbcDriver=com.mysql.jdbc.Driver
+juddi.jdbcUrl=jdbc:mysql://localhost:3306/juddi
+juddi.jdbcUsername=root
+juddi.jdbcPassword=admin
+# jUDDI DataSource to use
+# juddi.dataSource=java:comp/env/jdbc/MySqlDS
+
+# jUDDI UUIDGen implementation to use
+juddi.uuidgen = org.apache.juddi.uuidgen.DefaultUUIDGen
+
+# jUDDI Cryptor implementation to use
+juddi.cryptor = org.apache.juddi.cryptor.DefaultCryptor
+
+# jUDDI Validator to use
+juddi.validator=org.apache.juddi.validator.DefaultValidator
+
+# jUDDI Proxy Properties (used by RegistryProxy)
+juddi.proxy.adminURL = http://localhost:8080/juddi/admin
+juddi.proxy.inquiryURL = http://localhost:8080/juddi/inquiry
+juddi.proxy.publishURL = http://localhost:8080/juddi/publish
+juddi.proxy.transportClass = org.apache.juddi.proxy.AxisTransport
+juddi.proxy.securityProvider = com.sun.net.ssl.internal.ssl.Provider
+juddi.proxy.protocolHandler = com.sun.net.ssl.internal.www.protocol
+
+# JNDI settings (used by RMITransport)
+java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory
+java.naming.provider.url=jnp://localhost:1099
+java.naming.factory.url.pkgs=org.jboss.naming
+
Property changes on: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/juddi.properties
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Name: svn:eol-style
+ native
Added: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/listener.log
===================================================================
--- labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/listener.log (rev 0)
+++ labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/listener.log 2008-10-24 10:29:13 UTC (rev 23576)
@@ -0,0 +1,20 @@
+2008-10-24 10:08:10,203 DEBUG [main][httpclient.wire.header] >> "POST /Quickstart_publish_as_webservice_inonly/ESBServiceSample/HelloWorldPubService?wsdl HTTP/1.1[\r][\n]"
+2008-10-24 10:08:10,218 DEBUG [main][httpclient.wire.header] >> "User-Agent: Jakarta Commons-HttpClient/3.0.1[\r][\n]"
+2008-10-24 10:08:10,218 DEBUG [main][httpclient.wire.header] >> "Host: 127.0.0.1:8080[\r][\n]"
+2008-10-24 10:08:10,218 DEBUG [main][httpclient.wire.header] >> "Content-Length: 324[\r][\n]"
+2008-10-24 10:08:10,218 DEBUG [main][httpclient.wire.header] >> "[\r][\n]"
+2008-10-24 10:08:10,218 DEBUG [main][httpclient.wire.content] >> "<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" [\n]"
+2008-10-24 10:08:10,218 DEBUG [main][httpclient.wire.content] >> "[0x9][0x9][0x9]xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" [\n]"
+2008-10-24 10:08:10,218 DEBUG [main][httpclient.wire.content] >> "[0x9][0x9][0x9]xmlns:xsd="http://www.w3.org/2001/XMLSchema"[\n]"
+2008-10-24 10:08:10,218 DEBUG [main][httpclient.wire.content] >> "[0x9][0x9][0x9]xmlns:say="http://www.jboss.org/sayHi">[\n]"
+2008-10-24 10:08:10,234 DEBUG [main][httpclient.wire.content] >> " <soap:Body>[\n]"
+2008-10-24 10:08:10,234 DEBUG [main][httpclient.wire.content] >> " <say:sayHi><say:arg0>Error</say:arg0></say:sayHi>[\n]"
+2008-10-24 10:08:10,234 DEBUG [main][httpclient.wire.content] >> " </soap:Body>[\n]"
+2008-10-24 10:08:10,234 DEBUG [main][httpclient.wire.content] >> "[\n]"
+2008-10-24 10:08:10,234 DEBUG [main][httpclient.wire.content] >> "</soap:Envelope> [\n]"
+2008-10-24 10:08:10,281 DEBUG [main][httpclient.wire.header] << "HTTP/1.1 200 OK[\r][\n]"
+2008-10-24 10:08:10,281 DEBUG [main][httpclient.wire.header] << "Server: Apache-Coyote/1.1[\r][\n]"
+2008-10-24 10:08:10,281 DEBUG [main][httpclient.wire.header] << "X-Powered-By: Servlet 2.4; JBoss-4.2.2.GA (build: SVNTag=JBoss_4_2_2_GA date=200710221139)/Tomcat-5.5[\r][\n]"
+2008-10-24 10:08:10,281 DEBUG [main][httpclient.wire.header] << "Content-Type: text/xml;charset=UTF-8[\r][\n]"
+2008-10-24 10:08:10,281 DEBUG [main][httpclient.wire.header] << "Content-Length: 0[\r][\n]"
+2008-10-24 10:08:10,281 DEBUG [main][httpclient.wire.header] << "Date: Fri, 24 Oct 2008 09:08:10 GMT[\r][\n]"
Added: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/log4j.xml
===================================================================
--- labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/log4j.xml (rev 0)
+++ labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/log4j.xml 2008-10-24 10:29:13 UTC (rev 23576)
@@ -0,0 +1,79 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
+
+<!-- ===================================================================== -->
+<!-- -->
+<!-- Log4j Configuration -->
+<!-- -->
+<!-- ===================================================================== -->
+
+<!-- $Id: log4j.xml,v 1.26.2.5 2005/09/15 09:31:02 dimitris Exp $ -->
+
+<!--
+ | 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"/>
+ <param name="Threshold" value="INFO"/>
+
+ <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="DEBUG"/>
+ </category>
+ <!-- ======================= -->
+ <!-- Setup the Root category -->
+ <!-- ======================= -->
+
+ <root>
+ <appender-ref ref="CONSOLE"/>
+ <appender-ref ref="FILE"/>
+ </root>
+
+</log4j:configuration>
Property changes on: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/log4j.xml
___________________________________________________________________
Name: svn:mime-type
+ text/xml
Name: svn:eol-style
+ native
Added: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/readme.txt
===================================================================
--- labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/readme.txt (rev 0)
+++ labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/readme.txt 2008-10-24 10:29:13 UTC (rev 23576)
@@ -0,0 +1,33 @@
+Overview:
+=========
+ The purpose of the publish_as_webservice_inonly quickstart sample is to demonstrate how to
+ publish an OneWay (In-Only) esb service as a web service.
+
+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 '.esb' archive mode:
+===========================
+ 1. In a command terminal window in this folder ("Window1"), type 'ant deploy'.
+ 2. Open another command terminal window in this folder ("Window2"), type
+ 'ant runtest'.
+ 3. Open another command terminal window in this folder ("Window2"), type
+ 'ant sendesb'.
+ 4. In this folder ("Window1"), type 'ant undeploy'.
+
+To Run from Soapui:
+===========================
+ 1. Use the following URL: 'http://127.0.0.1:8080/Quickstart_publish_as_webservice_inonly/ESBServiceSample/HelloWorldPubService?wsdl'.
+ 2. Copy the contents of soap-userpass-message.xml.
+ 3. Exceute the web service call from soapui.
+
+======================================
+ 1. runtest ant target
+ This target will call the SOAPTest client twice, first call will be with a valid SOAP message
+ and the second call will generate a SOAPFault to be retured.
+
+ 2. sendesb ant target
+ This target will call the SendEsbMessage twice. The first call will be with a valid message body content
+ and the second will generate a FaultMessageException.
Added: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/request.xsd
===================================================================
--- labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/request.xsd (rev 0)
+++ labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/request.xsd 2008-10-24 10:29:13 UTC (rev 23576)
@@ -0,0 +1,8 @@
+<xs:schema version="1.0" targetNamespace="http://www.jboss.org/sayHi" xmlns:x1="http://www.jboss.org/sayHi" xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified">
+ <xs:element name="sayHi" type="x1:sayHi"/>
+ <xs:complexType name="sayHi">
+ <xs:sequence>
+ <xs:element name="arg0" type="xs:string" minOccurs="1"/>
+ </xs:sequence>
+ </xs:complexType>
+</xs:schema>
Property changes on: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/request.xsd
___________________________________________________________________
Name: svn:mime-type
+ text/xml
Name: svn:eol-style
+ native
Added: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/soap-userpass-message.xml
===================================================================
--- labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/soap-userpass-message.xml (rev 0)
+++ labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/soap-userpass-message.xml 2008-10-24 10:29:13 UTC (rev 23576)
@@ -0,0 +1,11 @@
+<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:say="http://www.jboss.org/sayHi">
+ <soap:Body>
+ <say:sayHi>
+ <say:arg0>HelloWorld</say:arg0>
+ </say:sayHi>"
+ </soap:Body>
+
+</soap:Envelope>
Property changes on: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/soap-userpass-message.xml
___________________________________________________________________
Name: svn:mime-type
+ text/xml
Name: svn:eol-style
+ native
Added: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/.classpath
===================================================================
--- labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/.classpath (rev 0)
+++ labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/.classpath 2008-10-24 10:29:13 UTC (rev 23576)
@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="src" path=""/>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+ <classpathentry kind="output" path=""/>
+</classpath>
Added: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/.project
===================================================================
--- labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/.project (rev 0)
+++ labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/.project 2008-10-24 10:29:13 UTC (rev 23576)
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>pubservice-sample</name>
+ <comment></comment>
+ <projects>
+ </projects>
+ <buildSpec>
+ <buildCommand>
+ <name>org.eclipse.jdt.core.javabuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>org.eclipse.jdt.core.javanature</nature>
+ </natures>
+</projectDescription>
Added: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/org/jboss/soa/esb/samples/quickstart/publishAsWebservice/ESBWSListenerAction.java
===================================================================
--- labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/org/jboss/soa/esb/samples/quickstart/publishAsWebservice/ESBWSListenerAction.java (rev 0)
+++ labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/org/jboss/soa/esb/samples/quickstart/publishAsWebservice/ESBWSListenerAction.java 2008-10-24 10:29:13 UTC (rev 23576)
@@ -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-2006,
+ * @author JBoss Inc.
+ */
+package org.jboss.soa.esb.samples.quickstart.publishAsWebservice;
+
+import javax.xml.namespace.QName;
+
+import org.jboss.soa.esb.actions.AbstractActionLifecycle;
+import org.jboss.soa.esb.actions.ActionProcessingDetailFaultException;
+import org.jboss.soa.esb.helpers.ConfigTree;
+import org.jboss.soa.esb.message.Message;
+
+public class ESBWSListenerAction extends AbstractActionLifecycle
+{
+ protected ConfigTree _config;
+
+ public ESBWSListenerAction(ConfigTree config)
+ {
+ _config = config;
+ }
+
+ public Message displayMessage(Message message) throws Exception
+ {
+ final String request = (String)message.getBody().get() ;
+ if (request.contains("Error")) {
+ final String detail = "<say:sayFault xmlns:say=\"http://www.jboss.org/sayHi\"><say:code>" +
+ "myErrorCode" + "</say:code><say:faultString>" + "myDescription" +
+ "</say:faultString></say:sayFault>" ;
+ throw new ActionProcessingDetailFaultException(new QName("http://www.jboss.org/sayHi", "myErrorCode"), "myDescription", detail) ;
+ }
+
+ System.out.println("Received request: " + request) ;
+ final String responseMsg = "<say:sayHiResponse xmlns:say=\"http://www.jboss.org/sayHi\"><say:arg0>" +
+ "Response from ESB Service" + "</say:arg0></say:sayHiResponse>" ;
+ message.getBody().add(responseMsg);
+ return message;
+ }
+}
Property changes on: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/org/jboss/soa/esb/samples/quickstart/publishAsWebservice/ESBWSListenerAction.java
___________________________________________________________________
Name: svn:eol-style
+ native
Added: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/org/jboss/soa/esb/samples/quickstart/publishAsWebservice/test/SOAPTest.java
===================================================================
--- labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/org/jboss/soa/esb/samples/quickstart/publishAsWebservice/test/SOAPTest.java (rev 0)
+++ labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/org/jboss/soa/esb/samples/quickstart/publishAsWebservice/test/SOAPTest.java 2008-10-24 10:29:13 UTC (rev 23576)
@@ -0,0 +1,58 @@
+/*
+ * 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-2006,
+ * @author JBoss Inc.
+ */
+package org.jboss.soa.esb.samples.quickstart.publishAsWebservice.test;
+import java.io.IOException;
+import java.io.UnsupportedEncodingException;
+
+import org.apache.commons.httpclient.HttpClient;
+import org.apache.commons.httpclient.HttpException;
+import org.apache.commons.httpclient.methods.PostMethod;
+import org.apache.commons.httpclient.methods.StringRequestEntity;
+import org.jboss.internal.soa.esb.util.StreamUtils;
+import org.jboss.soa.esb.ConfigurationException;
+
+public class SOAPTest {
+
+ public static void main(String args[]) throws ConfigurationException, UnsupportedEncodingException {
+
+ final String soap = StreamUtils.getResourceAsString(args[0], "UTF-8");
+ HttpClient client = new HttpClient();
+ PostMethod postMethod = new PostMethod(
+ "http://127.0.0.1:8080/Quickstart_publish_as_webservice_inonly/ESBServiceSample/HelloWorldPubService?wsdl");
+
+ StringRequestEntity requestEntity = new StringRequestEntity(soap);
+ postMethod.setRequestEntity(requestEntity);
+ try {
+ client.executeMethod(postMethod);
+ System.out.println("Response from web service");
+ System.out.println("[" + postMethod.getResponseBodyAsString() + "]");
+ } catch (HttpException e) {
+ // TODO Auto-generated catch block
+ e.printStackTrace();
+ } catch (IOException e) {
+ // TODO Auto-generated catch block
+ e.printStackTrace();
+ }
+ System.exit(0);
+
+ }
+
+}
Property changes on: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/org/jboss/soa/esb/samples/quickstart/publishAsWebservice/test/SOAPTest.java
___________________________________________________________________
Name: svn:eol-style
+ native
Added: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/org/jboss/soa/esb/samples/quickstart/publishAsWebservice/test/SendEsbMessage.java
===================================================================
--- labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/org/jboss/soa/esb/samples/quickstart/publishAsWebservice/test/SendEsbMessage.java (rev 0)
+++ labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/org/jboss/soa/esb/samples/quickstart/publishAsWebservice/test/SendEsbMessage.java 2008-10-24 10:29:13 UTC (rev 23576)
@@ -0,0 +1,74 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY 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 along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.jboss.soa.esb.samples.quickstart.publishAsWebservice.test;
+
+import java.util.Set;
+import java.io.Serializable;
+import java.util.HashSet;
+import org.jboss.soa.esb.services.security.auth.AuthenticationRequestImpl;
+import org.jboss.soa.esb.message.Message;
+import org.jboss.soa.esb.message.format.MessageFactory;
+import org.jboss.soa.esb.services.security.SecurityService;
+import org.jboss.soa.esb.services.security.auth.AuthenticationRequest;
+import org.jboss.soa.esb.services.security.principals.User;
+import org.jboss.soa.esb.client.ServiceInvoker;
+import org.jboss.soa.esb.couriers.FaultMessageException;
+import org.jboss.soa.esb.services.security.PublicCryptoUtil;
+
+/**
+ * Standalone class with to send ESB messages to a 'known' [category,name].
+ * <p/> arg0 - service category
+ * <br/>arg1 - service name
+ * <br/>arg2 - Text of message to send
+ *
+ * @author <a href="mailto:schifest at heuristica.com.ar">schifest at heuristica.com.ar</a>
+ * @since Version 4.0
+ *
+ */
+public class SendEsbMessage
+{
+ public static void main(String args[]) throws Exception
+ {
+// Setting the ConnectionFactory such that it will use scout
+ System.setProperty("javax.xml.registry.ConnectionFactoryClass","org.apache.ws.scout.registry.ConnectionFactoryImpl");
+
+ if (args.length < 3)
+ {
+ System.out.println("Usage SendEsbMessage <category> <name> <text to send>");
+ }
+ Message esbMessage = MessageFactory.getInstance().getMessage();
+
+ final String message = "<say:sayHi xmlns:say=\"http://www.jboss.org/sayHi\"><say:arg0>" + args[2] + "</say:arg0></say:sayHi>" ;
+ esbMessage.getBody().add(message);
+
+ ServiceInvoker invoker = new ServiceInvoker(args[0], args[1]);
+
+ Message response = null;
+ try {
+ invoker.deliverAsync(esbMessage);
+ }catch(Exception ex) {
+ ex.printStackTrace();
+ }
+ System.exit(0);
+ }
+}
Property changes on: labs/jbossesb/branches/JBESB_4_4_GA_CP/product/samples/quickstarts/publish_as_webservice_inonly/src/org/jboss/soa/esb/samples/quickstart/publishAsWebservice/test/SendEsbMessage.java
___________________________________________________________________
Name: svn:eol-style
+ native
More information about the jboss-svn-commits
mailing list