Web Services
WCF
WCF REST
Web API
- Web services are soap based and return data in xml format.
- It supports http protocols only.
- Web services can be consumed by any client that understand xml but it not open source.
- Web services can be hosted on IIS only.
WCF
- WCF services are also soap based and return data in xml format.
- WCF supports various protocols like TCP, HTTP, HTTPS, Named Pipes,MSMQ.
- WCF services can be consumed by any client that understand xml but it not open source.
- WCF services can be hosted on the IIS, within the application or by using window service.
WCF REST
- We have to enable webHttpBindings for WCF Rest service.
- It supports HTTP GET and HTTP POST verbs by [WebGet] and [WebInvoke] attributes.
- We have to do some configuration in IIS to enable these HTTP verbs to request for that particular verb in the .svc file.
- The URI template must be specifies for passing data through parameters using a WebGet.
- It Supports XML,JSON and ATOM data format.
Web API
- Web API is a easy and simple way for building HTTP services.
- Web API is an open source to build rest ful services over the Dot net framework.
- Web API uses full features of HTTP like URI, request /response header, caching ,versioning, various content formats etc.
- Web API can be hosted on the IIS or within the application.
- Web API is a light weight architecture and very good for the smart phones in the low bandwidth also.
- Response send by the Web API can be formatted by the MediaTypeFormatter into JSON,XML or any format we want to add as mediaTypeFormatter.
No comments:
Post a Comment