JBossWS SVN: r8205 - in stack/native/branches/dlofthouse/JBWS-2319/modules: testsuite/native-tests/scripts and 1 other directories.
by jbossws-commits@lists.jboss.org
Author: darran.lofthouse(a)jboss.com
Date: 2008-09-23 12:55:10 -0400 (Tue, 23 Sep 2008)
New Revision: 8205
Added:
stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/JBWS2319TestCase.java
stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/SOAPHandler.java
Removed:
stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/JBWS2285TestCase.java
stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/LogicalHandler.java
Modified:
stack/native/branches/dlofthouse/JBWS-2319/modules/core/src/main/java/org/jboss/ws/core/soap/NodeImpl.java
stack/native/branches/dlofthouse/JBWS-2319/modules/core/src/main/java/org/jboss/ws/core/soap/SOAPBodyImpl.java
stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/scripts/build-jars-jaxws.xml
stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/EndpointImpl.java
stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/server-handlers.xml
Log:
Test changes and the fix.
Modified: stack/native/branches/dlofthouse/JBWS-2319/modules/core/src/main/java/org/jboss/ws/core/soap/NodeImpl.java
===================================================================
--- stack/native/branches/dlofthouse/JBWS-2319/modules/core/src/main/java/org/jboss/ws/core/soap/NodeImpl.java 2008-09-23 14:11:17 UTC (rev 8204)
+++ stack/native/branches/dlofthouse/JBWS-2319/modules/core/src/main/java/org/jboss/ws/core/soap/NodeImpl.java 2008-09-23 16:55:10 UTC (rev 8205)
@@ -46,13 +46,13 @@
/**
* A representation of a node (element) in an XML document.
- * This interface extnends the standard DOM Node interface with methods for getting and setting the value of a node,
+ * This interface extends the standard DOM Node interface with methods for getting and setting the value of a node,
* for getting and setting the parent of a node, and for removing a node.
*
* When creating a DOM2 tree the objects maintained by the tree are <code>org.w3c.dom.Node</code> objects
* and not <code>javax.xml.soap.Node</code> objects.
* <p/>
- * This implementation schields the client from the the underlying DOM2 tree, returning <code>javax.xml.soap.Node</code>
+ * This implementation shields the client from the the underlying DOM2 tree, returning <code>javax.xml.soap.Node</code>
* objects.
*
* @author Thomas.Diesler(a)jboss.org
Modified: stack/native/branches/dlofthouse/JBWS-2319/modules/core/src/main/java/org/jboss/ws/core/soap/SOAPBodyImpl.java
===================================================================
--- stack/native/branches/dlofthouse/JBWS-2319/modules/core/src/main/java/org/jboss/ws/core/soap/SOAPBodyImpl.java 2008-09-23 14:11:17 UTC (rev 8204)
+++ stack/native/branches/dlofthouse/JBWS-2319/modules/core/src/main/java/org/jboss/ws/core/soap/SOAPBodyImpl.java 2008-09-23 16:55:10 UTC (rev 8205)
@@ -66,7 +66,7 @@
public SOAPElement addChildElement(SOAPElement child) throws SOAPException
{
log.trace("addChildElement: " + child.getElementName());
-
+
if ((child instanceof SOAPBodyElement) == false)
child = convertToBodyElement(child);
@@ -192,7 +192,7 @@
}
return bodyElement;
}
-
+
public Node appendChild(Node newChild) throws DOMException
{
log.trace("appendChild: " + newChild.getNodeName());
@@ -236,22 +236,33 @@
Iterator childElements = getChildElements();
+ SOAPElementImpl childElement = null;
+
+ while (childElements.hasNext() == true)
+ {
+ Object current = childElements.next();
+ if (current instanceof SOAPElementImpl)
+ childElement = (SOAPElementImpl)current;
+ }
+
// zero child elements?
- if (!childElements.hasNext())
+ if (childElement == null)
throw new SOAPException("Cannot find SOAPBodyElement");
- SOAPElementImpl childElement = (SOAPElementImpl)childElements.next();
-
// more than one child element?
- if (childElements.hasNext())
- throw new SOAPException("Multiple SOAPBodyElement");
+ while (childElements.hasNext() == true)
+ {
+ Object current = childElements.next();
+ if (current instanceof SOAPElementImpl)
+ throw new SOAPException("Multiple SOAPBodyElement");
+ }
if (childElement instanceof SOAPContentElement)
{
// cause expansion to DOM
SOAPContentElement contentElement = (SOAPContentElement)childElement;
// TODO change visibility of SOAPContentElement.expandToDOM() to package?
- contentElement.getPayload();
+ contentElement.hasChildNodes();
}
// child SOAPElement is removed as part of this process
Modified: stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/scripts/build-jars-jaxws.xml
===================================================================
--- stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/scripts/build-jars-jaxws.xml 2008-09-23 14:11:17 UTC (rev 8204)
+++ stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/scripts/build-jars-jaxws.xml 2008-09-23 16:55:10 UTC (rev 8205)
@@ -372,6 +372,18 @@
<include name="jboss-web.xml"/>
</webinf>
</war>
+
+ <!-- jaxws-jbws2319 -->
+ <war warfile="${tests.output.dir}/test-libs/jaxws-jbws2319.war" webxml="${tests.output.dir}/test-resources/jaxws/jbws2319/WEB-INF/web.xml">
+ <classes dir="${tests.output.dir}/test-classes">
+ <include name="org/jboss/test/ws/jaxws/jbws2319/*.class"/>
+ <exclude name="org/jboss/test/ws/jaxws/jbws2319/JBWS2285TestCase.class"/>
+ <include name="org/jboss/test/ws/jaxws/jbws2319/server-handlers.xml"/>
+ </classes>
+ <webinf dir="${tests.output.dir}/test-resources/jaxws/jbws2319/WEB-INF">
+ <include name="jboss-web.xml"/>
+ </webinf>
+ </war>
<!-- jaxws-webserviceref -->
<war warfile="${tests.output.dir}/test-libs/jaxws-webserviceref.war" webxml="${tests.output.dir}/test-resources/jaxws/webserviceref/WEB-INF/web.xml">
Modified: stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/EndpointImpl.java
===================================================================
--- stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/EndpointImpl.java 2008-09-23 14:11:17 UTC (rev 8204)
+++ stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/EndpointImpl.java 2008-09-23 16:55:10 UTC (rev 8205)
@@ -24,19 +24,23 @@
import javax.jws.HandlerChain;
import javax.jws.WebService;
+import org.jboss.logging.Logger;
+
/**
* Test Endpoint implementation.
*
* @author darran.lofthouse(a)jboss.com
* @since 23rd September 2008
*/
-@WebService(name = "Endpoint", targetNamespace = "http://ws.jboss.org/jbws2285", endpointInterface = "org.jboss.test.ws.jaxws.jbws2319.Endpoint")
+@WebService(name = "Endpoint", targetNamespace = "http://ws.jboss.org/jbws2319", endpointInterface = "org.jboss.test.ws.jaxws.jbws2319.Endpoint")
@HandlerChain(file = "server-handlers.xml")
public class EndpointImpl implements Endpoint
{
+ private static final Logger log = Logger.getLogger(EndpointImpl.class);
public String echo(final String message)
{
+ log.info("Value to echo '" + message + "'");
return message;
}
Deleted: stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/JBWS2285TestCase.java
===================================================================
--- stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/JBWS2285TestCase.java 2008-09-23 14:11:17 UTC (rev 8204)
+++ stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/JBWS2285TestCase.java 2008-09-23 16:55:10 UTC (rev 8205)
@@ -1,121 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source.
- * Copyright 2008, Red Hat Middleware LLC, and individual contributors
- * as indicated by the @author tags. See the copyright.txt file 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.test.ws.jaxws.jbws2319;
-
-import java.io.IOException;
-import java.net.URL;
-import java.util.Iterator;
-
-import javax.xml.namespace.QName;
-import javax.xml.soap.MessageFactory;
-import javax.xml.soap.SOAPBody;
-import javax.xml.soap.SOAPConnection;
-import javax.xml.soap.SOAPConnectionFactory;
-import javax.xml.soap.SOAPEnvelope;
-import javax.xml.soap.SOAPException;
-import javax.xml.soap.SOAPMessage;
-import javax.xml.ws.Service;
-
-import junit.framework.Test;
-
-import org.jboss.ws.core.soap.NodeImpl;
-import org.jboss.wsf.test.JBossWSTest;
-import org.jboss.wsf.test.JBossWSTestSetup;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-
-/**
- * [JBWS-2319] ClassCastException: org.jboss.ws.core.soap.TextImpl
- * in SOAPBody.extractContentAsDocument();
- *
- * @author darran.lofthouse(a)jboss.com
- * @since 23rd September 2008
- * @see https://jira.jboss.org/jira/browse/JBWS-2319
- */
-public class JBWS2285TestCase extends JBossWSTest
-{
-
- public final String TARGET_ENDPOINT_ADDRESS = "http://" + getServerHost() + ":8080/jaxws-jbws2285/";
-
- private static Endpoint port;
-
- public static Test suite() throws Exception
- {
- return new JBossWSTestSetup(JBWS2285TestCase.class, "jaxws-jbws2285.war");
- }
-
- public void setUp() throws Exception
- {
- super.setUp();
- URL wsdlURL = new URL(TARGET_ENDPOINT_ADDRESS + "?wsdl");
- QName serviceName = new QName("http://ws.jboss.org/jbws2285", "EndpointImplService");
-
- Service service = Service.create(wsdlURL, serviceName);
- port = service.getPort(Endpoint.class);
- }
-
- public void testCall() throws Exception
- {
- final String message = "Hello!!";
- String response = port.echo(message);
-
- // The logical handler should have replaced the incoming String.
- assertEquals("XXX", response);
- }
-
- public void testSOAPConnection() throws Exception
- {
- SOAPMessage reqMsg = getRequestMessage();
- URL epURL = new URL(TARGET_ENDPOINT_ADDRESS);
- SOAPConnection con = SOAPConnectionFactory.newInstance().createConnection();
- SOAPMessage resMsg = con.call(reqMsg, epURL);
- SOAPEnvelope resEnv = resMsg.getSOAPPart().getEnvelope();
-
- String response = "";
-
- SOAPBody body = resEnv.getBody();
- Iterator it = body.getChildElements(new QName("http://ws.jboss.org/jbws2285", "echoResponse"));
- Node node = (Node)it.next();
- NodeList nodes = node.getChildNodes();
- for (int i = 0; i < nodes.getLength(); i++)
- {
- Node current = nodes.item(i);
- if (current.getNodeName().equals("return"))
- {
- response = ((NodeImpl)current).getValue();
- }
- }
-
- // The logical handler should have replaced the incoming String.
- assertEquals("XXX", response);
- }
-
- private SOAPMessage getRequestMessage() throws SOAPException, IOException
- {
- URL reqMessage = getResourceFile("jaxws/jbws2285/request-message.xml").toURL();
- MessageFactory msgFactory = MessageFactory.newInstance();
-
- SOAPMessage reqMsg = msgFactory.createMessage(null, reqMessage.openStream());
- return reqMsg;
- }
-
-}
Copied: stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/JBWS2319TestCase.java (from rev 8203, stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/JBWS2285TestCase.java)
===================================================================
--- stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/JBWS2319TestCase.java (rev 0)
+++ stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/JBWS2319TestCase.java 2008-09-23 16:55:10 UTC (rev 8205)
@@ -0,0 +1,121 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file 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.test.ws.jaxws.jbws2319;
+
+import java.io.IOException;
+import java.net.URL;
+import java.util.Iterator;
+
+import javax.xml.namespace.QName;
+import javax.xml.soap.MessageFactory;
+import javax.xml.soap.SOAPBody;
+import javax.xml.soap.SOAPConnection;
+import javax.xml.soap.SOAPConnectionFactory;
+import javax.xml.soap.SOAPEnvelope;
+import javax.xml.soap.SOAPException;
+import javax.xml.soap.SOAPMessage;
+import javax.xml.ws.Service;
+
+import junit.framework.Test;
+
+import org.jboss.ws.core.soap.NodeImpl;
+import org.jboss.wsf.test.JBossWSTest;
+import org.jboss.wsf.test.JBossWSTestSetup;
+import org.w3c.dom.Node;
+import org.w3c.dom.NodeList;
+
+/**
+ * [JBWS-2319] ClassCastException: org.jboss.ws.core.soap.TextImpl
+ * in SOAPBody.extractContentAsDocument();
+ *
+ * @author darran.lofthouse(a)jboss.com
+ * @since 23rd September 2008
+ * @see https://jira.jboss.org/jira/browse/JBWS-2319
+ */
+public class JBWS2319TestCase extends JBossWSTest
+{
+
+ public final String TARGET_ENDPOINT_ADDRESS = "http://" + getServerHost() + ":8080/jaxws-jbws2319/";
+
+ private static Endpoint port;
+
+ public static Test suite() throws Exception
+ {
+ return new JBossWSTestSetup(JBWS2319TestCase.class, "jaxws-jbws2319.war");
+ }
+
+ public void setUp() throws Exception
+ {
+ super.setUp();
+ URL wsdlURL = new URL(TARGET_ENDPOINT_ADDRESS + "?wsdl");
+ QName serviceName = new QName("http://ws.jboss.org/jbws2319", "EndpointImplService");
+
+ Service service = Service.create(wsdlURL, serviceName);
+ port = service.getPort(Endpoint.class);
+ }
+
+ public void testCall() throws Exception
+ {
+ final String message = "Hello!!";
+ String response = port.echo(message);
+
+ // The logical handler should have replaced the incoming String.
+ assertEquals("XXX", response);
+ }
+
+ public void testSOAPConnection() throws Exception
+ {
+ SOAPMessage reqMsg = getRequestMessage();
+ URL epURL = new URL(TARGET_ENDPOINT_ADDRESS);
+ SOAPConnection con = SOAPConnectionFactory.newInstance().createConnection();
+ SOAPMessage resMsg = con.call(reqMsg, epURL);
+ SOAPEnvelope resEnv = resMsg.getSOAPPart().getEnvelope();
+
+ String response = "";
+
+ SOAPBody body = resEnv.getBody();
+ Iterator it = body.getChildElements(new QName("http://ws.jboss.org/jbws2319", "echoResponse"));
+ Node node = (Node)it.next();
+ NodeList nodes = node.getChildNodes();
+ for (int i = 0; i < nodes.getLength(); i++)
+ {
+ Node current = nodes.item(i);
+ if (current.getNodeName().equals("return"))
+ {
+ response = ((NodeImpl)current).getValue();
+ }
+ }
+
+ // The logical handler should have replaced the incoming String.
+ assertEquals("XXX", response);
+ }
+
+ private SOAPMessage getRequestMessage() throws SOAPException, IOException
+ {
+ URL reqMessage = getResourceFile("jaxws/jbws2319/request-message.xml").toURL();
+ MessageFactory msgFactory = MessageFactory.newInstance();
+
+ SOAPMessage reqMsg = msgFactory.createMessage(null, reqMessage.openStream());
+ return reqMsg;
+ }
+
+}
Deleted: stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/LogicalHandler.java
===================================================================
--- stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/LogicalHandler.java 2008-09-23 14:11:17 UTC (rev 8204)
+++ stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/LogicalHandler.java 2008-09-23 16:55:10 UTC (rev 8205)
@@ -1,80 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source.
- * Copyright 2008, Red Hat Middleware LLC, and individual contributors
- * as indicated by the @author tags. See the copyright.txt file 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.test.ws.jaxws.jbws2319;
-
-import javax.xml.transform.dom.DOMSource;
-import javax.xml.ws.LogicalMessage;
-import javax.xml.ws.handler.LogicalMessageContext;
-import javax.xml.ws.handler.MessageContext;
-
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-import org.jboss.logging.Logger;
-import org.jboss.ws.WSException;
-import org.jboss.wsf.common.DOMWriter;
-import org.jboss.wsf.test.GenericLogicalHandler;
-
-/**
- * Logical handler implementation.
- *
- * @author darran.lofthouse(a)jboss.com
- * @since 23rd September 2008
- */
-public class LogicalHandler extends GenericLogicalHandler
-{
-
- private static final Logger log = Logger.getLogger(LogicalHandler.class);
-
- @Override
- protected boolean handleInbound(final MessageContext msgContext)
- {
- log.info("handleInbound()");
-
- LogicalMessageContext lmc = (LogicalMessageContext)msgContext;
- LogicalMessage message = lmc.getMessage();
-
- Object payload = message.getPayload();
-
- if (payload instanceof DOMSource == false)
- {
- throw new WSException("Test requires DOMSource payload");
- }
-
- DOMSource domPayload = (DOMSource)payload;
- Node node = domPayload.getNode();
-
- NodeList nodes = node.getChildNodes();
- for (int i = 0; i < nodes.getLength(); i++)
- {
- Node current = nodes.item(i);
- if ("arg0".equals(current.getLocalName()))
- {
- current.setTextContent("XXX");
- }
- }
-
- log.info(DOMWriter.printNode(node, false));
-
- return true;
- }
-
-}
Copied: stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/SOAPHandler.java (from rev 8203, stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/LogicalHandler.java)
===================================================================
--- stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/SOAPHandler.java (rev 0)
+++ stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/SOAPHandler.java 2008-09-23 16:55:10 UTC (rev 8205)
@@ -0,0 +1,99 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file 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.test.ws.jaxws.jbws2319;
+
+import javax.xml.soap.SOAPBody;
+import javax.xml.soap.SOAPElementFactory;
+import javax.xml.soap.SOAPException;
+import javax.xml.soap.SOAPMessage;
+import javax.xml.ws.handler.LogicalMessageContext;
+import javax.xml.ws.handler.MessageContext;
+import javax.xml.ws.handler.soap.SOAPMessageContext;
+
+import org.jboss.logging.Logger;
+import org.jboss.ws.WSException;
+import org.jboss.wsf.common.DOMWriter;
+import org.jboss.wsf.common.handler.GenericSOAPHandler;
+import org.w3c.dom.Document;
+import org.w3c.dom.Node;
+import org.w3c.dom.NodeList;
+
+/**
+ * Logical handler implementation.
+ *
+ * @author darran.lofthouse(a)jboss.com
+ * @since 23rd September 2008
+ */
+public class SOAPHandler extends GenericSOAPHandler<LogicalMessageContext>
+{
+
+ private static final Logger log = Logger.getLogger(SOAPHandler.class);
+
+ @Override
+ protected boolean handleInbound(final MessageContext msgContext)
+ {
+ log.info("handleInbound()");
+
+ try
+ {
+ SOAPMessageContext smc = (SOAPMessageContext)msgContext;
+ SOAPMessage message = smc.getMessage();
+
+ SOAPBody body = message.getSOAPBody();
+ Document document = body.extractContentAsDocument();
+ Node node = document;
+
+ log.info(DOMWriter.printNode(node, false));
+
+ NodeList nodes = node.getChildNodes();
+ for (int i = 0; i < nodes.getLength(); i++)
+ {
+ Node current = nodes.item(i);
+
+ NodeList childNodes = current.getChildNodes();
+ for (int j = 0; j < childNodes.getLength(); j++)
+ {
+ Node currentChildNode = childNodes.item(j);
+ if ("arg0".equals(currentChildNode.getLocalName()))
+ {
+ log.info("Replacing " + currentChildNode.getTextContent() + " with XXX");
+ currentChildNode.setTextContent("XXX");
+ }
+ }
+ }
+
+ log.info(DOMWriter.printNode(node, false));
+
+ // Add document back as removed by call to 'extractContentAsDocument()'
+ body.addDocument(document);
+ message.saveChanges();
+ }
+ catch (SOAPException e)
+ {
+ throw new WSException("Error in Handler", e);
+ }
+
+ log.info("Finished");
+ return true;
+ }
+
+}
Modified: stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/server-handlers.xml
===================================================================
--- stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/server-handlers.xml 2008-09-23 14:11:17 UTC (rev 8204)
+++ stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/server-handlers.xml 2008-09-23 16:55:10 UTC (rev 8205)
@@ -7,8 +7,8 @@
<handler-chain>
<handler>
- <handler-name> LogicalServerHandler </handler-name>
- <handler-class> org.jboss.test.ws.jaxws.jbws2319.LogicalHandler </handler-class>
+ <handler-name> SOAPServerHandler </handler-name>
+ <handler-class> org.jboss.test.ws.jaxws.jbws2319.SOAPHandler </handler-class>
</handler>
</handler-chain>
15 years, 8 months
JBossWS SVN: r8204 - framework/trunk/hudson.
by jbossws-commits@lists.jboss.org
Author: richard.opalka(a)jboss.com
Date: 2008-09-23 10:11:17 -0400 (Tue, 23 Sep 2008)
New Revision: 8204
Modified:
framework/trunk/hudson/ant.properties.example
Log:
we moved from jbws.dyndns.org to jbossws.jboss.org
Modified: framework/trunk/hudson/ant.properties.example
===================================================================
--- framework/trunk/hudson/ant.properties.example 2008-09-23 14:10:57 UTC (rev 8203)
+++ framework/trunk/hudson/ant.properties.example 2008-09-23 14:11:17 UTC (rev 8204)
@@ -10,38 +10,39 @@
jboss.bind.address=localhost
# JDK settings
+java.home.jdk15=/usr/java/jdk1.5
java.home.jdk16=/usr/java/jdk1.6
# Hudson QA Environment
hudson.username=changeme
hudson.password=changeme
-hudson.root=/usr/share/java/workspace
-hudson.host=jbws.dyndns.org
+hudson.root=/data/workspace
+hudson.host=jbossws.jboss.org
hudson.admin.port=8150
hudson.http.port=8180
-hudson.native.url=https://svn.jboss.org/repos/jbossws/stack/native/trunk
-hudson.metro.url=https://svn.jboss.org/repos/jbossws/stack/metro/trunk
-hudson.cxf.url=https://svn.jboss.org/repos/jbossws/stack/cxf/trunk
+hudson.native.url=http://anonsvn.jboss.org/repos/jbossws/stack/native/trunk
+hudson.metro.url=http://anonsvn.jboss.org/repos/jbossws/stack/metro/trunk
+hudson.cxf.url=http://anonsvn.jboss.org/repos/jbossws/stack/cxf/trunk
-hudson.jboss422.url=https://svn.jboss.org/repos/jbossas/tags/JBoss_4_2_2_GA
+hudson.jboss422.url=http://anonsvn.jboss.org/repos/jbossas/tags/JBoss_4_2_2_GA
hudson.jboss422.build=jboss-4.2.2.GA
hudson.jboss422.rev=HEAD
-hudson.jboss423.url=https://svn.jboss.org/repos/jbossas/tags/JBoss_4_2_3_GA
+hudson.jboss423.url=http://anonsvn.jboss.org/repos/jbossas/tags/JBoss_4_2_3_GA
hudson.jboss423.build=jboss-4.2.3.GA
hudson.jboss423.rev=HEAD
-hudson.jboss424.url=https://svn.jboss.org/repos/jbossas/branches/Branch_4_2
+hudson.jboss424.url=http://anonsvn.jboss.org/repos/jbossas/branches/Branch_4_2
hudson.jboss424.build=jboss-4.2.4.GA
hudson.jboss424.rev=HEAD
-hudson.jboss500.url=https://svn.jboss.org/repos/jbossas/tags/JBoss_5_0_0_CR2
+hudson.jboss500.url=http://anonsvn.jboss.org/repos/jbossas/tags/JBoss_5_0_0_CR2
hudson.jboss500.build=jboss-5.0.0.CR2
hudson.jboss500.rev=HEAD
-hudson.jboss501.url=https://svn.jboss.org/repos/jbossas/trunk
+hudson.jboss501.url=http://anonsvn.jboss.org/repos/jbossas/trunk
hudson.jboss501.build=jboss-5.0.0.GA
hudson.jboss501.rev=HEAD
15 years, 8 months
JBossWS SVN: r8203 - in stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test: java/org/jboss/test/ws/jaxws/jbws2319 and 3 other directories.
by jbossws-commits@lists.jboss.org
Author: darran.lofthouse(a)jboss.com
Date: 2008-09-23 10:10:57 -0400 (Tue, 23 Sep 2008)
New Revision: 8203
Added:
stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/
stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/resources/jaxws/jbws2319/
Modified:
stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/Endpoint.java
stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/EndpointImpl.java
stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/JBWS2285TestCase.java
stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/LogicalHandler.java
stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/server-handlers.xml
stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/resources/jaxws/jbws2319/WEB-INF/jboss-web.xml
stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/resources/jaxws/jbws2319/WEB-INF/web.xml
stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/resources/jaxws/jbws2319/request-message.xml
Log:
Branch an existing test to write this test.
Copied: stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319 (from rev 8201, stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2285)
Modified: stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/Endpoint.java
===================================================================
--- stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2285/Endpoint.java 2008-09-23 13:28:21 UTC (rev 8201)
+++ stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/Endpoint.java 2008-09-23 14:10:57 UTC (rev 8203)
@@ -1,6 +1,6 @@
/*
* JBoss, Home of Professional Open Source.
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*
@@ -19,7 +19,7 @@
* 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.test.ws.jaxws.jbws2285;
+package org.jboss.test.ws.jaxws.jbws2319;
import javax.jws.WebService;
@@ -27,9 +27,9 @@
* Test Endpoint.
*
* @author darran.lofthouse(a)jboss.com
- * @since 19th August 2008
+ * @since 23rd September 2008
*/
-@WebService(name = "Endpoint", targetNamespace = "http://ws.jboss.org/jbws2285")
+@WebService(name = "Endpoint", targetNamespace = "http://ws.jboss.org/jbws2319")
public interface Endpoint
{
Modified: stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/EndpointImpl.java
===================================================================
--- stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2285/EndpointImpl.java 2008-09-23 13:28:21 UTC (rev 8201)
+++ stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/EndpointImpl.java 2008-09-23 14:10:57 UTC (rev 8203)
@@ -1,6 +1,6 @@
/*
* JBoss, Home of Professional Open Source.
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*
@@ -19,7 +19,7 @@
* 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.test.ws.jaxws.jbws2285;
+package org.jboss.test.ws.jaxws.jbws2319;
import javax.jws.HandlerChain;
import javax.jws.WebService;
@@ -28,9 +28,9 @@
* Test Endpoint implementation.
*
* @author darran.lofthouse(a)jboss.com
- * @since 19th August 2008
+ * @since 23rd September 2008
*/
-@WebService(name = "Endpoint", targetNamespace = "http://ws.jboss.org/jbws2285", endpointInterface = "org.jboss.test.ws.jaxws.jbws2285.Endpoint")
+@WebService(name = "Endpoint", targetNamespace = "http://ws.jboss.org/jbws2285", endpointInterface = "org.jboss.test.ws.jaxws.jbws2319.Endpoint")
@HandlerChain(file = "server-handlers.xml")
public class EndpointImpl implements Endpoint
{
Modified: stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/JBWS2285TestCase.java
===================================================================
--- stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2285/JBWS2285TestCase.java 2008-09-23 13:28:21 UTC (rev 8201)
+++ stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/JBWS2285TestCase.java 2008-09-23 14:10:57 UTC (rev 8203)
@@ -1,6 +1,6 @@
/*
* JBoss, Home of Professional Open Source.
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*
@@ -19,10 +19,8 @@
* 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.test.ws.jaxws.jbws2285;
+package org.jboss.test.ws.jaxws.jbws2319;
-import java.io.ByteArrayInputStream;
-import java.io.File;
import java.io.IOException;
import java.net.URL;
import java.util.Iterator;
@@ -46,12 +44,12 @@
import org.w3c.dom.NodeList;
/**
- * [JBWS-2285] ClassCastException: org.jboss.ws.core.soap.TextImpl
- * in LogicalMessageImpl.getPayload.
+ * [JBWS-2319] ClassCastException: org.jboss.ws.core.soap.TextImpl
+ * in SOAPBody.extractContentAsDocument();
*
* @author darran.lofthouse(a)jboss.com
- * @since 19th August 2008
- * @see https://jira.jboss.org/jira/browse/JBWS-2285
+ * @since 23rd September 2008
+ * @see https://jira.jboss.org/jira/browse/JBWS-2319
*/
public class JBWS2285TestCase extends JBossWSTest
{
Modified: stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/LogicalHandler.java
===================================================================
--- stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2285/LogicalHandler.java 2008-09-23 13:28:21 UTC (rev 8201)
+++ stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/LogicalHandler.java 2008-09-23 14:10:57 UTC (rev 8203)
@@ -1,6 +1,6 @@
/*
* JBoss, Home of Professional Open Source.
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*
@@ -19,7 +19,7 @@
* 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.test.ws.jaxws.jbws2285;
+package org.jboss.test.ws.jaxws.jbws2319;
import javax.xml.transform.dom.DOMSource;
import javax.xml.ws.LogicalMessage;
@@ -37,7 +37,7 @@
* Logical handler implementation.
*
* @author darran.lofthouse(a)jboss.com
- * @since 19th August 2008
+ * @since 23rd September 2008
*/
public class LogicalHandler extends GenericLogicalHandler
{
Modified: stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/server-handlers.xml
===================================================================
--- stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2285/server-handlers.xml 2008-09-23 13:28:21 UTC (rev 8201)
+++ stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/java/org/jboss/test/ws/jaxws/jbws2319/server-handlers.xml 2008-09-23 14:10:57 UTC (rev 8203)
@@ -8,7 +8,7 @@
<handler-chain>
<handler>
<handler-name> LogicalServerHandler </handler-name>
- <handler-class> org.jboss.test.ws.jaxws.jbws2285.LogicalHandler </handler-class>
+ <handler-class> org.jboss.test.ws.jaxws.jbws2319.LogicalHandler </handler-class>
</handler>
</handler-chain>
Copied: stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/resources/jaxws/jbws2319 (from rev 8201, stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/resources/jaxws/jbws2285)
Modified: stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/resources/jaxws/jbws2319/WEB-INF/jboss-web.xml
===================================================================
--- stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/resources/jaxws/jbws2285/WEB-INF/jboss-web.xml 2008-09-23 13:28:21 UTC (rev 8201)
+++ stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/resources/jaxws/jbws2319/WEB-INF/jboss-web.xml 2008-09-23 14:10:57 UTC (rev 8203)
@@ -3,5 +3,5 @@
<!DOCTYPE jboss-web PUBLIC "-//JBoss//DTD Web Application 2.4//EN" "http://www.jboss.org/j2ee/dtd/jboss-web_4_0.dtd">
<jboss-web>
- <context-root>/jaxws-jbws2285</context-root>
+ <context-root>/jaxws-jbws2319</context-root>
</jboss-web>
\ No newline at end of file
Modified: stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/resources/jaxws/jbws2319/WEB-INF/web.xml
===================================================================
--- stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/resources/jaxws/jbws2285/WEB-INF/web.xml 2008-09-23 13:28:21 UTC (rev 8201)
+++ stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/resources/jaxws/jbws2319/WEB-INF/web.xml 2008-09-23 14:10:57 UTC (rev 8203)
@@ -5,7 +5,7 @@
<servlet>
<servlet-name>Endpoint</servlet-name>
- <servlet-class>org.jboss.test.ws.jaxws.jbws2285.EndpointImpl</servlet-class>
+ <servlet-class>org.jboss.test.ws.jaxws.jbws2319.EndpointImpl</servlet-class>
</servlet>
<servlet-mapping>
Modified: stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/resources/jaxws/jbws2319/request-message.xml
===================================================================
--- stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/resources/jaxws/jbws2285/request-message.xml 2008-09-23 13:28:21 UTC (rev 8201)
+++ stack/native/branches/dlofthouse/JBWS-2319/modules/testsuite/native-tests/src/test/resources/jaxws/jbws2319/request-message.xml 2008-09-23 14:10:57 UTC (rev 8203)
@@ -1,4 +1,4 @@
-<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:jbw="http://ws.jboss.org/jbws2285">
+<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:jbw="http://ws.jboss.org/jbws2319">
<soapenv:Header/>
<soapenv:Body>
<jbw:echo>
15 years, 8 months
JBossWS SVN: r8202 - framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/smoke/tools.
by jbossws-commits@lists.jboss.org
Author: alessio.soldano(a)jboss.com
Date: 2008-09-23 09:56:39 -0400 (Tue, 23 Sep 2008)
New Revision: 8202
Modified:
framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/smoke/tools/WSConsumerPlugin.java
Log:
[JBWS-1772] Re-enabling test & removing fixme
Modified: framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/smoke/tools/WSConsumerPlugin.java
===================================================================
--- framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/smoke/tools/WSConsumerPlugin.java 2008-09-23 13:28:21 UTC (rev 8201)
+++ framework/trunk/testsuite/test/java/org/jboss/test/ws/jaxws/smoke/tools/WSConsumerPlugin.java 2008-09-23 13:56:39 UTC (rev 8202)
@@ -235,11 +235,9 @@
System.out.println(messageOut);
System.out.println("--- End captured output --");
- System.out.println("FIXME [JBWS-1772] WSConsume output is not correctly redirected");
-
- /*assertTrue("Tools output not correctly redirected",
+ assertTrue("Tools output not correctly redirected",
messageOut.indexOf("org/jboss/test/ws/tools/testMessageStream/EndpointInterface.java")!=-1
- );*/
+ );
}
/**
15 years, 8 months
JBossWS SVN: r8201 - stack/native/branches/dlofthouse.
by jbossws-commits@lists.jboss.org
Author: darran.lofthouse(a)jboss.com
Date: 2008-09-23 09:28:21 -0400 (Tue, 23 Sep 2008)
New Revision: 8201
Added:
stack/native/branches/dlofthouse/JBWS-2319/
Log:
Branch to test code changes.
Copied: stack/native/branches/dlofthouse/JBWS-2319 (from rev 8200, stack/native/trunk)
15 years, 8 months
JBossWS SVN: r8200 - in stack/native/branches/dlofthouse/JBWS-2304/modules/core/src/main/java/org/jboss: ws/core/soap and 1 other directories.
by jbossws-commits@lists.jboss.org
Author: darran.lofthouse(a)jboss.com
Date: 2008-09-23 09:21:48 -0400 (Tue, 23 Sep 2008)
New Revision: 8200
Modified:
stack/native/branches/dlofthouse/JBWS-2304/modules/core/src/main/java/org/jboss/ws/core/jaxws/handler/MessageContextJAXWS.java
stack/native/branches/dlofthouse/JBWS-2304/modules/core/src/main/java/org/jboss/ws/core/soap/MessageContextAssociation.java
stack/native/branches/dlofthouse/JBWS-2304/modules/core/src/main/java/org/jboss/wsf/stack/jbws/RequestHandlerImpl.java
Log:
Clear thread locals when MessageContextAssociation is empty.
Modified: stack/native/branches/dlofthouse/JBWS-2304/modules/core/src/main/java/org/jboss/ws/core/jaxws/handler/MessageContextJAXWS.java
===================================================================
--- stack/native/branches/dlofthouse/JBWS-2304/modules/core/src/main/java/org/jboss/ws/core/jaxws/handler/MessageContextJAXWS.java 2008-09-23 13:19:46 UTC (rev 8199)
+++ stack/native/branches/dlofthouse/JBWS-2304/modules/core/src/main/java/org/jboss/ws/core/jaxws/handler/MessageContextJAXWS.java 2008-09-23 13:21:48 UTC (rev 8200)
@@ -106,7 +106,7 @@
if (outbound == null)
throw new IllegalStateException("Cannot find property: " + MessageContext.MESSAGE_OUTBOUND_PROPERTY);
- MessageContextAssociation.popMessageContext();
+ MessageContextAssociation.popMessageContext(false);
SOAPMessageContextJAXWS resContext = new SOAPMessageContextJAXWS(reqContext);
resContext.setSOAPMessage(null);
Modified: stack/native/branches/dlofthouse/JBWS-2304/modules/core/src/main/java/org/jboss/ws/core/soap/MessageContextAssociation.java
===================================================================
--- stack/native/branches/dlofthouse/JBWS-2304/modules/core/src/main/java/org/jboss/ws/core/soap/MessageContextAssociation.java 2008-09-23 13:19:46 UTC (rev 8199)
+++ stack/native/branches/dlofthouse/JBWS-2304/modules/core/src/main/java/org/jboss/ws/core/soap/MessageContextAssociation.java 2008-09-23 13:21:48 UTC (rev 8200)
@@ -26,6 +26,7 @@
import org.jboss.logging.Logger;
import org.jboss.ws.core.CommonMessageContext;
import org.jboss.ws.core.utils.ThreadLocalAssociation;
+import org.jboss.wsf.common.DOMUtils;
/**
* A thread local association with the current message context
@@ -37,11 +38,11 @@
{
// provide logging
private static Logger log = Logger.getLogger(MessageContextAssociation.class);
-
public static void pushMessageContext(CommonMessageContext msgContext)
{
- if(log.isDebugEnabled()) log.debug("pushMessageContext: " + msgContext + " (Thread " +Thread.currentThread().getName()+ ")");
+ if (log.isDebugEnabled())
+ log.debug("pushMessageContext: " + msgContext + " (Thread " + Thread.currentThread().getName() + ")");
Stack<CommonMessageContext> stack = ThreadLocalAssociation.localMsgContextAssoc().get();
if (stack == null)
{
@@ -64,13 +65,24 @@
public static CommonMessageContext popMessageContext()
{
+ return popMessageContext(true);
+ }
+
+ public static CommonMessageContext popMessageContext(boolean clearDOMIfEmpty)
+ {
CommonMessageContext msgContext = null;
Stack<CommonMessageContext> stack = ThreadLocalAssociation.localMsgContextAssoc().get();
if (stack != null && stack.isEmpty() == false)
{
msgContext = stack.pop();
+ if (stack.isEmpty() == true && clearDOMIfEmpty == true)
+ {
+ DOMUtils.clearThreadLocals();
+ }
}
- if(log.isDebugEnabled()) log.debug("popMessageContext: " + msgContext +" (Thread " +Thread.currentThread().getName()+ ")");
+ if (log.isDebugEnabled())
+ log.debug("popMessageContext: " + msgContext + " (Thread " + Thread.currentThread().getName() + ")");
return msgContext;
}
+
}
Modified: stack/native/branches/dlofthouse/JBWS-2304/modules/core/src/main/java/org/jboss/wsf/stack/jbws/RequestHandlerImpl.java
===================================================================
--- stack/native/branches/dlofthouse/JBWS-2304/modules/core/src/main/java/org/jboss/wsf/stack/jbws/RequestHandlerImpl.java 2008-09-23 13:19:46 UTC (rev 8199)
+++ stack/native/branches/dlofthouse/JBWS-2304/modules/core/src/main/java/org/jboss/wsf/stack/jbws/RequestHandlerImpl.java 2008-09-23 13:21:48 UTC (rev 8200)
@@ -346,7 +346,6 @@
// clear thread local storage
ThreadLocalAssociation.clear();
- DOMUtils.clearThreadLocals();
}
}
15 years, 8 months
JBossWS SVN: r8199 - stack/native/branches/dlofthouse.
by jbossws-commits@lists.jboss.org
Author: darran.lofthouse(a)jboss.com
Date: 2008-09-23 09:19:46 -0400 (Tue, 23 Sep 2008)
New Revision: 8199
Added:
stack/native/branches/dlofthouse/JBWS-2304/
Log:
Branch to test code changes.
Copied: stack/native/branches/dlofthouse/JBWS-2304 (from rev 8198, stack/native/trunk)
15 years, 8 months
JBossWS SVN: r8198 - framework/trunk/testsuite/test/java/org/jboss/test/ws/management/recording.
by jbossws-commits@lists.jboss.org
Author: alessio.soldano(a)jboss.com
Date: 2008-09-22 06:49:42 -0400 (Mon, 22 Sep 2008)
New Revision: 8198
Modified:
framework/trunk/testsuite/test/java/org/jboss/test/ws/management/recording/MemoryBufferRecorderTestCase.java
Log:
Fixing MemoryBufferRecorderTestCase hudson failure
Modified: framework/trunk/testsuite/test/java/org/jboss/test/ws/management/recording/MemoryBufferRecorderTestCase.java
===================================================================
--- framework/trunk/testsuite/test/java/org/jboss/test/ws/management/recording/MemoryBufferRecorderTestCase.java 2008-09-19 16:15:19 UTC (rev 8197)
+++ framework/trunk/testsuite/test/java/org/jboss/test/ws/management/recording/MemoryBufferRecorderTestCase.java 2008-09-22 10:49:42 UTC (rev 8198)
@@ -178,7 +178,10 @@
setRecording(true);
OperationFilter operationFilter = new OperationFilter(new QName(targetNS, "echo1"));
- HostFilter hostFilter = new HostFilter("localhost".equals(getServerHost()) ? "127.0.0.1" : getServerHost(), false); //destination
+ LinkedList<String> l = new LinkedList<String>();
+ l.add("localhost");
+ l.add("127.0.0.1");
+ HostFilter hostFilter = new HostFilter(l,false); //destination
RecordFilter[] filters = new RecordFilter[] {operationFilter, hostFilter};
Map<String, List<Record>> startRecords = (Map<String, List<Record>>)server.invoke(oname, "getMatchingRecords", new Object[] { filters }, new String[] { filters.getClass().getName() });
15 years, 8 months
JBossWS SVN: r8197 - framework/trunk/hudson/hudson-home/jobs/Maven-Repository-Clean.
by jbossws-commits@lists.jboss.org
Author: alessio.soldano(a)jboss.com
Date: 2008-09-19 12:15:19 -0400 (Fri, 19 Sep 2008)
New Revision: 8197
Modified:
framework/trunk/hudson/hudson-home/jobs/Maven-Repository-Clean/config.xml
Log:
[JBWS-2310] Fixing job: the hudson user is used to run hudson
Modified: framework/trunk/hudson/hudson-home/jobs/Maven-Repository-Clean/config.xml
===================================================================
--- framework/trunk/hudson/hudson-home/jobs/Maven-Repository-Clean/config.xml 2008-09-19 14:34:48 UTC (rev 8196)
+++ framework/trunk/hudson/hudson-home/jobs/Maven-Repository-Clean/config.xml 2008-09-19 16:15:19 UTC (rev 8197)
@@ -10,8 +10,7 @@
USER=`whoami`
-if [ $USER = "root" ]; then
- rm -rf /root/.m2/repository
+if [ $USER = "hudson" ]; then
rm -rf /data/maven-repos/hudson/repository
else
rm -rf /home/$USER/.m2/repository
15 years, 8 months
JBossWS SVN: r8196 - in framework/trunk/hudson/hudson-home/jobs: Native-Source-Distro-AS-4.2.2-JDK6 and 8 other directories.
by jbossws-commits@lists.jboss.org
Author: richard.opalka(a)jboss.com
Date: 2008-09-19 10:34:48 -0400 (Fri, 19 Sep 2008)
New Revision: 8196
Modified:
framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-4.2.2-JDK6/config.xml
framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-4.2.2/config.xml
framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-4.2.3-JDK6/config.xml
framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-4.2.3/config.xml
framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-4.2.4-JDK6/config.xml
framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-4.2.4/config.xml
framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-5.0.0-JDK6/config.xml
framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-5.0.0/config.xml
framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-5.0.1-JDK6/config.xml
framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-5.0.1/config.xml
Log:
[JBWS-2286] fix native source distribution issue
Modified: framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-4.2.2/config.xml
===================================================================
--- framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-4.2.2/config.xml 2008-09-19 12:52:07 UTC (rev 8195)
+++ framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-4.2.2/config.xml 2008-09-19 14:34:48 UTC (rev 8196)
@@ -36,6 +36,7 @@
rm -rf jbossws-native-src-dist
unzip jbossws-native-src-dist.zip
cd jbossws-native-src-dist
+cp profiles.xml.example profiles.xml
ant $ENVIRONMENT deploy-jboss422
# remove obsolete logs
Modified: framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-4.2.2-JDK6/config.xml
===================================================================
--- framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-4.2.2-JDK6/config.xml 2008-09-19 12:52:07 UTC (rev 8195)
+++ framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-4.2.2-JDK6/config.xml 2008-09-19 14:34:48 UTC (rev 8196)
@@ -46,6 +46,7 @@
rm -rf jbossws-native-src-dist
unzip jbossws-native-src-dist.zip
cd jbossws-native-src-dist
+cp profiles.xml.example profiles.xml
ant $ENVIRONMENT deploy-jboss422
# remove obsolete logs
Modified: framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-4.2.3/config.xml
===================================================================
--- framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-4.2.3/config.xml 2008-09-19 12:52:07 UTC (rev 8195)
+++ framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-4.2.3/config.xml 2008-09-19 14:34:48 UTC (rev 8196)
@@ -36,6 +36,7 @@
rm -rf jbossws-native-src-dist
unzip jbossws-native-src-dist.zip
cd jbossws-native-src-dist
+cp profiles.xml.example profiles.xml
ant $ENVIRONMENT deploy-jboss423
# remove obsolete logs
Modified: framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-4.2.3-JDK6/config.xml
===================================================================
--- framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-4.2.3-JDK6/config.xml 2008-09-19 12:52:07 UTC (rev 8195)
+++ framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-4.2.3-JDK6/config.xml 2008-09-19 14:34:48 UTC (rev 8196)
@@ -46,6 +46,7 @@
rm -rf jbossws-native-src-dist
unzip jbossws-native-src-dist.zip
cd jbossws-native-src-dist
+cp profiles.xml.example profiles.xml
ant $ENVIRONMENT deploy-jboss423
# remove obsolete logs
Modified: framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-4.2.4/config.xml
===================================================================
--- framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-4.2.4/config.xml 2008-09-19 12:52:07 UTC (rev 8195)
+++ framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-4.2.4/config.xml 2008-09-19 14:34:48 UTC (rev 8196)
@@ -36,6 +36,7 @@
rm -rf jbossws-native-src-dist
unzip jbossws-native-src-dist.zip
cd jbossws-native-src-dist
+cp profiles.xml.example profiles.xml
ant $ENVIRONMENT deploy-jboss424
# remove obsolete logs
Modified: framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-4.2.4-JDK6/config.xml
===================================================================
--- framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-4.2.4-JDK6/config.xml 2008-09-19 12:52:07 UTC (rev 8195)
+++ framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-4.2.4-JDK6/config.xml 2008-09-19 14:34:48 UTC (rev 8196)
@@ -46,6 +46,7 @@
rm -rf jbossws-native-src-dist
unzip jbossws-native-src-dist.zip
cd jbossws-native-src-dist
+cp profiles.xml.example profiles.xml
ant $ENVIRONMENT deploy-jboss424
# remove obsolete logs
Modified: framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-5.0.0/config.xml
===================================================================
--- framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-5.0.0/config.xml 2008-09-19 12:52:07 UTC (rev 8195)
+++ framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-5.0.0/config.xml 2008-09-19 14:34:48 UTC (rev 8196)
@@ -36,6 +36,7 @@
rm -rf jbossws-native-src-dist
unzip jbossws-native-src-dist.zip
cd jbossws-native-src-dist
+cp profiles.xml.example profiles.xml
ant $ENVIRONMENT deploy-jboss500
# remove obsolete logs
Modified: framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-5.0.0-JDK6/config.xml
===================================================================
--- framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-5.0.0-JDK6/config.xml 2008-09-19 12:52:07 UTC (rev 8195)
+++ framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-5.0.0-JDK6/config.xml 2008-09-19 14:34:48 UTC (rev 8196)
@@ -46,6 +46,7 @@
rm -rf jbossws-native-src-dist
unzip jbossws-native-src-dist.zip
cd jbossws-native-src-dist
+cp profiles.xml.example profiles.xml
ant $ENVIRONMENT deploy-jboss500
# remove obsolete logs
Modified: framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-5.0.1/config.xml
===================================================================
--- framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-5.0.1/config.xml 2008-09-19 12:52:07 UTC (rev 8195)
+++ framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-5.0.1/config.xml 2008-09-19 14:34:48 UTC (rev 8196)
@@ -36,6 +36,7 @@
rm -rf jbossws-native-src-dist
unzip jbossws-native-src-dist.zip
cd jbossws-native-src-dist
+cp profiles.xml.example profiles.xml
ant $ENVIRONMENT deploy-jboss501
# remove obsolete logs
Modified: framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-5.0.1-JDK6/config.xml
===================================================================
--- framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-5.0.1-JDK6/config.xml 2008-09-19 12:52:07 UTC (rev 8195)
+++ framework/trunk/hudson/hudson-home/jobs/Native-Source-Distro-AS-5.0.1-JDK6/config.xml 2008-09-19 14:34:48 UTC (rev 8196)
@@ -46,6 +46,7 @@
rm -rf jbossws-native-src-dist
unzip jbossws-native-src-dist.zip
cd jbossws-native-src-dist
+cp profiles.xml.example profiles.xml
ant $ENVIRONMENT deploy-jboss501
# remove obsolete logs
15 years, 8 months