Introduction

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 host 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 sent 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 applications) 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 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. Here we highlight 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 provider in WCF Data Services.

Please leave feedback in the comments.