ASP.NET,C#.NET,VB.NET,JQuery,JavaScript,Gridview,SQL Server,Ajax,jQuery Plugins,jQuery UI,SSRS,XML,HTML,jQuery demos,code snippet examples.

Breaking News

  1. Home
  2. Web Service
  3. Web Service

Web Service

Web service is a way of data exchanging between computer systems over the network. Its help us to transfer information between different device or software systems. Today web service is an important part in the World Wide Web (WWW). This article describes an introduction to web service and its features. Summary of the article:
  • What is Web Service?
  • Features of Web Service
  • Example of Web Service
  • Advantages of Web service
  • Disadvantages of Web service
What is Web Service?
Web Service is a mechanism to communicate between two or more electrical devices over the internet. It is a software system designed to support machine to machine communications through a network. It is device/system independent, language independent. Broadly speaking, a web service is applications which obtains the information from its own server (using its own language) and distribute the same information in a general format or language that is understandable by the client who requested the information. Then, the client converts the Information’s received from the Web service in its own format or language and then uses it accordingly.  HTTP, XML are the main elements of web-service. There are some other terms used in web-services like SOAP, WSDL, REST, WSDL, etc.
Like other traditional client/server systems, web service does not provide any graphical user interface for the users. Data are transferred through a programmatic interface across a network. It allows organizations to communicate data without enough knowledge of each other’s IT systems behind the firewall.
Features of Web Service
Web service has some features. Some features are given bellow:
  • It uses HTTP.
  • It is only used in web applications.
  • Its unhandled exceptions are returned to the clients as SOAP fault.
  • It uses XmlSerializer.
  • It is accessed through HTTP.
  • It can be hosted in the IIS.
Example of Web Service
Some famous and commonly used web services are Weather service, Currency converter, Stock market reports updates. A sample web service written in C# language is given bellow:
[WebService]
public class TestWebService : System.Web.Services.WebService
{
    [WebMethod]
    public string Test(string msg)
    {
        return msg;
    }
}
Let us discuss about the codes. This sample web service “TestWebService” has only one method “Test” which will return string type message. We can write or customize the codes according to our requirements.
Advantages of Web service
Web service provides lot of advantages. Some benefits of web services are given bellow:
  • Web service provides the functionality of Interoperability. It is the most import benefits of Web service. It allows dissimilar applications to talk to each other and share information’s and services between them. For example: PHP or C# application can talk to java web services and vice versa. Web service makes an application platform and language independent.
  • Web service offers low cost communication service. For communication it uses SOAP over HTTP protocol. We can use our existing low cost internet for implementing Web Services. That’s why it is less costly compared to other solutions like EDI/B2B.
  • Web Services uses standardized protocol for the communication. For that it can provides us many advantages like: wide range of choices, cost reduction, quality improvement, etc.
  • Today different companies are using different technologies like: B2B, EDI, EAI, B2B, Portals etc. Web service supports all these technologies. That’s why any company can use their existing technology with others technologies. This saves the investment cost.
  • Web services are self describing. So, anyone can easily include it with their application and can start the operations. Don’t need to develop new applications. This reduces the development cost and time.
Disadvantages of Web service
Web service is a good solution for some conditions. It has some limitations. The drawbacks of web services are given bellow:
  • Sometimes web service may provide poor performance compared to others distributed system like: RMI and CORBA.
The Web service plays an important role in distribution system. It is now becoming a standalone technology that can provide numerous benefits for our business. We can perform CRUD operations by using web service.

No comments