Implementing an SAAJ-based Web Service

To see SAAJ in action, you will now examine a service example that interacts with the agency EJBs you saw earlier in the case study to list the jobs available at a particular location. The server consists of a servlet that uses SAAJ to receive and unpack the SOAP messages containing the location name and the request type. In response, the server will retrieve the job information and package it up as an XML response for the client.

Processing a SOAP Message Using SAAJ

The implementation for an SAAJ-based Web Service takes the form of an ordinary Java servlet. The servlet runs inside a servlet container and processes the SOAP message using the SAAJ API. HTTP-based SOAP messages are delivered to the doPost ...

Get Sams Teach Yourself J2EE™ in 21 Days, Second Edition now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.