Introduction to WCF Data Services

Introduction to WCF Data Services



WCF Data Services (formerly known as ADO.NET Data Services and codename is “Astoria”) is a platform for what Microsoft calls Data Services. This is a component of the .NET Framework that enables you to create services that use the OData (Open Data Protocol) to expose and consume data over the web or intranet by using the semantics of Representational State Transfer (REST). So first let’s see what this OData really is.

OData(Open Data Protocol)

The Open Data Protocol is a Web protocol for querying and updating data. OData does this by applying and building upon Web technologies such as HTTP, Atom Publishing Protocol (AtomPub) and JSON to provide access to information from a variety of applications, services, and stores. OData is being used to expose and access information from a variety of sources including, but not limited to, relational databases, file systems, content management systems and traditional Web sites.

What happens in OData is Servers hosts data and Clients can consume/manipulate or update these data. The end point on the server is also known as a Service. The protocol is HTTP based and we can use standard HTTP verbs of GET, PUT, POST, and DELETE to interact with the service. The data is send between the Server and Client using Atom Publishing Protocol (AtomPub - a set of standards for exchanging and updating data as XML) and JavaScript Object Notation(JSON - a text based data exchange format used extensively in AJAX application) and as plain XML. Among these three, AtomPub is the default format. Since the protocol is HTTP based, any application written in any programming language which has HTTP stack can communicate with this service.

WCF Data Service + oData

Now how WCF Data Services and OData comes together is WCF Data Services uses the OData protocol for addressing and updating resources. In this way, you can access these services from any client that supports OData. WCF Data Services also includes a set of client libraries, one for general .NET Framework client applications and another specifically for Silverlight-based applications. These client libraries provide an object-based programming model when you access an OData feed from environments such as the .NET Framework and Silverlight.

Data Service Providers

As I mentioned before WCF Data Services exposes data through a service. Now comes a question what type of data can be exposed and what are the data sources/providers which are available in WCF Data Services.

WCF Data Services supports multiple provider models for exposing data as an Open Data Protocol (OData) feed which are as follows. I am highlighting the main three of them.

  1. Entity Framework Provider
  2. Reflection Provider
  3. Custom Provider
  4. Streaming Provider
  5. Action Provider

So this is kind of an Introduction to WCF Data Services. Hoping to write some wikis about each providers in WCF Data Services.

Please leave feedback in the comments.

Leave a Comment
  • Please add 1 and 6 and type the answer here:
  • Post
Wiki - Revision Comment List(Revision Comment)
Sort by: Published Date | Most Recent | Most Useful
Page 1 of 1 (4 items)
Wikis - Comment List
Sort by: Published Date | Most Recent | Most Useful
Posting comments is temporarily disabled until 10:00am PST on Saturday, December 14th. Thank you for your patience.
  • Jaliya Udagedara edited Revision 1. Comment: updated

  • Maheshkumar S Tiwari edited Revision 3. Comment: Added TOC and formatting

  • Maheshkumar S Tiwari edited Revision 4. Comment: Added Tag

  • Ed Price - MSFT edited Revision 5. Comment: tags; 3rd person voice

Page 1 of 1 (4 items)