SOAP Web service overview
Let’s see some of the main components of SOAP web service
It stands for Universal Description, Discovery and Integration
It is a directory service which is kind of repository of all the web services.
All the web services have to be registered with the UDDI and make themselves available for the discovery.
So anyone who wants to use the service will go and search the UDDI and then start using that service.
Web service description language (WSDL)
It’s an XML file which describes the complete web service.
It includes the details like end point,port number,method names,arguments , data types,communication protocol,message format,security etc.
This is a standard provided by W3C consortium and widely accepted for web services description.
The WSDL file has to be published publicly so that it helps the consumers to understand the service and consume it.
WSDL contains below elements
It is a root element in WSDL file, it contains set of name space declarations which are used throughout the WSDL file.
Defines the data types used by the web service and they are specified by the XML schema.
Types can be defined in a separate XSD file and then XSD file can be imported in the WSDL.
The advantage of maintaining types in a separate XSD is that it can be reused across many WSDLs if required.
We just need to import the XSD in the WSDL file.
It is the data that is being exchanged between service providers and consumers.
It represents, how the request and response should be.
We need information like what protocol the web service is bound to and what is the message format it is using.
So this information is bound to web service (specifically interface) using binding element in WSDL.
Describes the action to be performed by the web service, it also contains the request and response for that action.
It describes the end point of the service, which is the address where the service is available.
It describes the address of the web service in the network along with the associated protocol and messaging format.
Lets understand Stub and Skeleton
In any client service communication, there will be lower level components which actually helps the communication by performing some steps.
At client side, this low level component is called stub.
At server side, this low level component is called skeleton.
Client communicate with the stub, stub then invokes the actual service.
And at the server side, skeleton receives the request, understands it and then passes it to the actual service.
Simple Object Access Protocol is a XML specification for web services message format and its communication over the network.
So SOAP basically describes message format and the transport method of a web service.
It allows the web service to communicate using HTTP and XML
It encodes the messages in XML and hence it is more secure.