[seam-commits] Seam SVN: r14008 - in branches/community/Seam_2_2: examples/seambay/resources/org and 6 other directories.
seam-commits at lists.jboss.org
seam-commits at lists.jboss.org
Thu Jan 20 11:10:15 EST 2011
Author: manaRH
Date: 2011-01-20 11:10:13 -0500 (Thu, 20 Jan 2011)
New Revision: 14008
Added:
branches/community/Seam_2_2/examples/seambay/resources/org/
branches/community/Seam_2_2/examples/seambay/resources/org/jboss/
branches/community/Seam_2_2/examples/seambay/resources/org/jboss/seam/
branches/community/Seam_2_2/examples/seambay/resources/org/jboss/seam/example/
branches/community/Seam_2_2/examples/seambay/resources/org/jboss/seam/example/seambay/
branches/community/Seam_2_2/examples/seambay/resources/org/jboss/seam/example/seambay/soap-handlers.xml
Modified:
branches/community/Seam_2_2/examples/seambay/src/org/jboss/seam/example/seambay/AuctionService.java
branches/community/Seam_2_2/src/main/org/jboss/seam/webservice/SOAPRequestHandler.java
Log:
JBSEAM-4685 - added soap handler for standard jaxws
Added: branches/community/Seam_2_2/examples/seambay/resources/org/jboss/seam/example/seambay/soap-handlers.xml
===================================================================
--- branches/community/Seam_2_2/examples/seambay/resources/org/jboss/seam/example/seambay/soap-handlers.xml (rev 0)
+++ branches/community/Seam_2_2/examples/seambay/resources/org/jboss/seam/example/seambay/soap-handlers.xml 2011-01-20 16:10:13 UTC (rev 14008)
@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<handler-chains xmlns="http://java.sun.com/xml/ns/javaee">
+ <handler-chain>
+ <handler>
+ <handler-name>SOAP Request Handler</handler-name>
+ <handler-class>org.jboss.seam.webservice.SOAPRequestHandler</handler-class>
+ </handler>
+ </handler-chain>
+</handler-chains>
+
Property changes on: branches/community/Seam_2_2/examples/seambay/resources/org/jboss/seam/example/seambay/soap-handlers.xml
___________________________________________________________________
Name: svn:executable
+ *
Modified: branches/community/Seam_2_2/examples/seambay/src/org/jboss/seam/example/seambay/AuctionService.java
===================================================================
--- branches/community/Seam_2_2/examples/seambay/src/org/jboss/seam/example/seambay/AuctionService.java 2011-01-20 09:15:33 UTC (rev 14007)
+++ branches/community/Seam_2_2/examples/seambay/src/org/jboss/seam/example/seambay/AuctionService.java 2011-01-20 16:10:13 UTC (rev 14008)
@@ -3,6 +3,7 @@
import java.util.List;
import javax.ejb.Stateless;
+import javax.jws.HandlerChain;
import javax.jws.WebMethod;
import javax.jws.WebService;
@@ -14,6 +15,7 @@
@Stateless
@Name("auctionService")
@WebService(name = "AuctionService")
+ at HandlerChain(file = "soap-handlers.xml")
public class AuctionService implements AuctionServiceRemote
{
@WebMethod
Modified: branches/community/Seam_2_2/src/main/org/jboss/seam/webservice/SOAPRequestHandler.java
===================================================================
--- branches/community/Seam_2_2/src/main/org/jboss/seam/webservice/SOAPRequestHandler.java 2011-01-20 09:15:33 UTC (rev 14007)
+++ branches/community/Seam_2_2/src/main/org/jboss/seam/webservice/SOAPRequestHandler.java 2011-01-20 16:10:13 UTC (rev 14008)
@@ -7,6 +7,7 @@
import javax.servlet.http.HttpServletRequest;
import javax.xml.namespace.QName;
import javax.xml.soap.SOAPElement;
+import javax.xml.soap.SOAPEnvelope;
import javax.xml.soap.SOAPException;
import javax.xml.soap.SOAPHeader;
import javax.xml.ws.handler.MessageContext;
@@ -111,6 +112,14 @@
element.addTextNode(conversationId);
smc.getMessage().saveChanges();
}
+ else
+ {
+ SOAPEnvelope envelope = smc.getMessage().getSOAPPart().getEnvelope();
+ header = envelope.addHeader();
+ SOAPElement element = header.addChildElement(CIDQN);
+ element.addTextNode(conversationId);
+ smc.getMessage().saveChanges();
+ }
}
Manager.instance().endRequest( new ServletRequestSessionMap(request) );
More information about the seam-commits
mailing list