Wednesday, April 27, 2016

Web Services


What is a Web Service
  • Web Services are used for developing an Interoperable applications and it make use of Open standard and protocols like xml,Http and SOAP.Since Web services make use of open and well known protocols an application built in any platform can communicate with web service.
  • For example an application built in JAVA Platform can communicate with web service developed using .Net platform and Vice versa.
What is a WebMethod attribute
  • Web Method:If we want to expose a method to the client as a part of Web service then we need to decorate a method with WebMethod attribute.
What is a WSDL
  • WSDL stands for Web service description language and it is used for describing Web service and it is written in XML format.
  • It contains the web service methods which are exposed to client.
  • It also contains the information about the method input parameters,input parameters data types and a Return type of a method.
What are WebMethod attributes properties in a Web Service
  • Description:To specify a description for a Web service we make use of Description property which is in WebMethod attribute.
  • MessageName:If we have two or more methods with same name but difference in Signature then we make use of MessageName property.
  • Cache Duration:If we want to cache the output of the Web service for a specific period of duration then we make use Cache Duration attribute.
  • EnableSession:If we want to make use of Session object in Web Service then we make use of EnableSession Property.
How can you make sure that only authorized users can access the web service
  • We make use of <authorization tag to make sure that only authorized users can access the web services.This tag allows or denies the access to web services based on their roles.
What is Webmethod overloading in Web service
  • WebMethod overloading means having the method with same name but difference in signature is Webmethod Overloading.
  • We make use of Messagename property of Webmethod attribute to channge the method names.
How can you prevent web service from unauthorized access
  • Web services can be prevented from unauthorized users by using
    1.Encryption and message based security
    2.Using authentication and accessing web services
What is SOAP
  • SOAP: Its full form is Simple object access protocol which allows us to communicate between applications developed in different platform via network.
What do you mean by Interoperability in Web service

  • Web service allows various application to communicate with each other and share the data among themselves.
  • For example an application developed in Java platform can communicate with web service which is developed in .Net platform and Vice versa which makes an application platform and technology independent is Interoperability.

No comments:

Post a Comment