Home > 2010 Fall DPS907 > OData introduction

OData introduction

This post will introduce DPS907/WSA500 students to the Open Data Protocol (OData).

As stated in Monday’s notes, and adapted from the MSDN Library documentation:

Adapted from odata.org documentation: The Open Data Protocol (OData) enables the creation of HTTP-based data services, which allow resources identified using Uniform Resource Identifiers (URIs) and defined in an abstract data model, to be published and edited by Web clients using simple HTTP messages.

Note: The OData protocol, while an open standard, has not yet been widely adopted. It was developed by Microsoft, and given to the developer community. It is as cross-platform as it needs to be, and is vendor-neutral. Yes, it does specify URI formats and data/message formats, but so does every other RESTful API out there.

Later in the course, we may study the Google Data Protocol.


Working with OData – create and configure a WCF Data Service

As you have learned, creating a WCF Data Service is straightforward and easy to do. The resulting service works for GET operations, and can be edited to support other HTTP methods.

The key is the entity access rule. When we created our first service, we configured all entities to allow “read” access, which enables the GET method:

config.SetEntitySetAccessRule(“*”, EntitySetRights.AllRead);

To enable other methods, you must add more rules, and/or modify existing rules. The first argument is the entity name, and the second argument is one or more ( or = || ) rights from an enumeration.

The best how-to source is the Microsoft MSDN documentation.


Working with OData – using a browser and/or cURL tools

(more to come)

Consult the OData protocol operations documentation.

You will have to test, experiment, and learn.


Creating a GUI client (as required for Lab 2)

(will be demonstrated in class)


More to come

The lecture discussion will be added to these notes very soon.


Categories: 2010 Fall DPS907
  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: