InfoCenter Home > 4.8.1.2.2: Building a SOAP clientCreating clients to access the SOAP services published in WebSphere Application Server is a straightfoward process. The Apache SOAP implementation, integrated with WebSphere Application Server, contains a client API to assist in SOAP client application development. The SOAP API documentation is available in WebSphere Application Server's javadoc. These are the steps for creating a client that interacts with a SOAP RPC service:
Interacting with a "document-oriented" SOAP service requires you to use lower-level Apache SOAP API calls. You must first construct an "Envelope" object which contains the contents of the message (including the body and any headers) that you wish to send. Then create a "Message" object where you invoke the send() method to perform the actual transmission. To create a secure SOAP service, do the following:
Your code may look like the following example: EnvelopeEditor editor= new PluggableEnvelopeEditor(new InputSource(conf), home); SOAPTransport transport = new FilterTransport(editor, new SOAPHTTPConnection()); call.setSOAPTransport(transport);The characteristics of the secure session are specified by the configuration file, "conf." See article Securing SOAP services for more information on creating secure Web services. See article 4.8.1.2.2.1: Accessing enterprise beans through SOAP for information on calling an EJB service. Since the SOAP API is a standard for Web services, any clients that you create to access the WebSphere Application Server SOAP services can also run in different implementations. See the related information links for an enablement scenario. |
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|