A few years ago, the world of distributed computing was surprised with an innovative proposal, based on standard techniques to describe interfaces to software components, methods for accessing such components by means of interoperable protocols and discovery of methods that enable the identification of important service providers. In addition, the proposal also included the independence of programming and/or operating systems languages. According to these provisions, the web services have been proposed.
A simple example is a web service that implements a search service on the Internet. This service is published on some server and the client can locate it through discovery methods.
The customer who wants information on a particular keyword sends a request to the service, informing the keyword of interest. The web service, in turn, returns a response to the client, containing information about the informed keyword. It is worth noting that programs, and non-human, access the web services.
As previously mentioned, Web services are nothing more than a new distributed computing technology. So what differentiates it from other to justify its proposal and use are the following points:
1) Independence of implementation and programming languages platform. This peculiarity is explained by use of XML, which is a standard language for data exchange.
2) HTTP use for messaging. The great advantage of using this standard lies in the issue of accessibility. For security reasons, many system administrators block access to their internal networks through firewalls, which also end up invalidating the use of technologies that do not use port 80 HTTP.
Furthermore, the portability of Web services has a price to pay. Obviously, transmiting data in XML format causes a much greater overhead, since as a meta-language, the volume of traffic increases, considering that not only the data will be traveling, but as well as the definitions of those data.
In practice, there are a number of steps that must be followed. Initially, the client must know where is the desired service. For this, it accesses a service that has the name and the location of various services. In web services, it uses the UDDI (Universal Description, Discovery and Integration), specially developed for organizing and web services registry.
After discovering the location of a service, the customer is faced with another question: how to access the services of this web service. For this, the client accesses his interface, which is described by WSDL (Web Service Description Language) standard language for describing services interface. Because it is a standard based on XML, the use of WSDL makes that the access to web service is independent of programming and of development of environments languages.
After reviewing the web service interface (specified in WSDL), the client invokes the desired service. In general, the invocation of a service involves passing messages between the client and the service. In Web services, this message passing is accomplished through the SOAP protocol (Simple Object Access Protocol), which specifies how to make requests to the server and how it should format your answers. In theory, other languages invocation services can be used. However, SOAP is widely used in web services, in particular for use as a transport protocol HTTP and SMTP.