Creating a Web Service to catch SOAP Messages

Hi

Can somebody please help me with this? I want to create a simple Web Service that listens for and can receive soap messages. I have a client program that sends an attachment in a soap message using SAAJ, and i want to receive it at the web service and extract the attachment. I know how to get the attachment out of the message once I've received it, but how do I actually receive the message?

[410 byte] By [jderham] at [2007-9-30 22:29:50]
# 1

You can use JAXM framework. You can create you own web service endpoint (based on servlet) in such a way:

import javax.xml.messaging; //Package that represents JAXM API

//Import all other nessesary packages

public class MyClass extends JAXMServlet implements ReqRespListener

{

SOAPMessage onMessage(SOAPMessage incomingMessage)

{

// Here is all the code

return outgoingMessage;

}

}

for more information on building messaging-based web services see the article "Java Web Services Developer Pack, Part 2": http://java.sun.com/developer/technicalArticles/WebServices/WSPack2/

Avenarius at 2007-7-7 12:53:11 > top of Java-index,Enterprise & Remote Computing,Enterprise Technologies...