Tuesday, June 18, 2013

Team Foundation Server 2010, Team Foundation Server 2012 and Team Foundation Service supports OData

Yes! The title means it, literally!

Now we could connect and query Team Foundation Server and Team Foundation Service work items and many more using OData! Using OData means we are using URLs to directly query.

OData quick background

OData has been around and it’s one of the cool openness initiatives from Microsoft. Originally named as Astoria, then WCF Data Service, now it’s called OData.

It’s simply a specification and libraries to produce data to be visible as URL, and also the consumer of the URLs.

The official website for OData is: http://www.odata.org/

In there, you’ll find numerous library supports for many platforms/OS, also as the server (OData producer) and the client (also called OData consumer). These producer and consumer really fits the nature of OData as web services, therefore it can be seen as open web API to access data.

These are current libraries and OS supports:


What about the real customers/users of OData? There are many producers today, and one of them is the famous Nerd Dinner. I call it famous, because it’s often used as samples of OData usages from Microsoft.

There was Netflix, but Netflix has ceased OData support. Here’s the announcement: http://developer.netflix.com/blog/read/Changes_to_the_Public_API_Program

The use of OData in Team Foundation Server and Team Foundation Service

To use OData on both TFS (the server and the service, what have you), we need to have library supports in the form of Nuget package and also tooling support.

The tooling support is available to download at: http://www.microsoft.com/en-us/download/details.aspx?id=39373

I will not dive into the detail of how to set up OData for TFS, as there are resources from Microsoft to have!

To get started, let’s visit this Brian Keller blog entry: http://blogs.msdn.com/b/briankel/archive/2013/01/07/odata-service-for-team-foundation-server-v2.aspx

This is the official Technet Wiki: http://social.technet.microsoft.com/wiki/contents/articles/15039.odata-service-for-team-foundation-server-v2.aspx

This is the video explanation from Brian Keller: http://channel9.msdn.com/Blogs/briankel/OData-Service-for-Team-Foundation-Server-2010

TFS on the cloud has provided simple OData documentation: https://tfsodata.visualstudio.com/

Now, download the “OData Service for Team Foundation Server v2” libraries for Visual Studio at this link: http://www.microsoft.com/en-us/download/details.aspx?id=36230

Then you'll set to have OData for TFS!

In the libraries above, you’ll see OData for TFS in action as Windows Store app:


Enjoy and happy coding!

No comments:

Post a Comment