Thursday, 2 May 2013

Web Services

What is Web service?
  • Web services are client and server applications that communicate over the World Wide Web's(www) HyperText Transfer Protocol(HTTP)

  • As described by the World Wide Web consortium,  web services provide a standard means of  interoperating between software applications  running on a variety of platforms  and frameworks. 
There are two major categories of web services
  1.     SOAP Web Service
  2.     RESTful Web Service
1.Soap Web Service

Simple Object Access Protocol (SOAP) is a standard protocol specification for message exchange based on XML. Communication between the web service and client happens using XML messages. SOAP defines the rules for communication like what are all the tags that should be used in XML and their meaning.

2.RESTful Web Service

RESTful web service uses architectures that use HTTP or similar protocols by restricting the interface to use standard operations like GET, POST, PUT, DELETE for HTTP. RESTful is easier to develop. 

 WSDL

One major component of a web service is Web Services Description Language (WSDL). It is an xml file that describes the web service technically in a machine readable format. That is, using this WSDL file we can understand things like,
  •     Port / Endpoint – URL of the web service (using which we should access it)
  •     Input message format
  •     Output message format
  •     Security protocol that needs to be followed (like https)
  •     Which protocol the web service uses