Developing SOAP Web service using Apache CXF

About Niraj Singh

In last post I walked through the steps for developing a simple RESTFull service using apache CXF.  In this post I will be talking about developing SOAP web service using CXF. Before moving forward let us understand few of the concepts/elements which makes up a SOAP web service

SOAP or Simple Object Access Protocol 

SOAP is a protocol for exchanging XML-based messages over the network using application protocols like http, smtp, etc as carrier. SOAP message comprises of a SOAP envelope. The envelope can be broken into a header and a body. Header contains context related definitions like security while the body contains actual application data. A typical SOAP message looks like

<?xml version="1.0"?><soap:Envelope xmlns:soap="http://www.w3.org/2003/05/soap-envelope">  <soap:Header>  </soap:Header>  <soap:Body>    <m:GetStockPrice xmlns:m="http://www.example.org/stock">      <m:StockName>IBM</m:StockName>    </m:GetStockPrice>  </soap:Body></soap:Envelope>

Source : http://www.javacodegeeks.com/2013/06/developing-soap-web-service-using-apache-cxf.html

Back to Top