Today I started to setup Continuous Integration (CI) with Team Foundation Server (TFS). Unfortunately, TFS does not support it out of the box; however, it does support functionality for you to hook-up into event sinks for comment server operations (Checkin, WorkItem assignment, etc). So, I Googled for "continuous integration team foundation" and ran into two really good posts by Jeff Atwood [post] and Daniel Cazzulino [post].
I particurlaly like solution that Jeff's post gives you, because he has added the page that kzu (Daniel) created and incorporated into his CI webservice. I wanted to take the solution even further by adding the automatic addition of a bug work item for any failed build. The bug work item will be assigned to the requester of the build (aka the person who performed the checkin). Also, the process sends out an email notification to the "developer group" for the project. Sound pretty easy, huh? Well, it is...once you find documentation for the TFS API.
You would think that MS would do a better job in providing good documentation for their biggest developer application platform? You thought wrong. The MSDN documentation is worthless! There are no good samples on MSDN for you to base your development. How do they expect people to take full advantage of the system?
I was fortunate to stumble into this post that gives a pretty nice overview of the WorkItem API. The coolest thing about the post is that it gives a nice overview of the COM interop problem you encounter while working with the work item storage cache. While searching for more detail on the COM interop problem, I stumbled into this other post that covers the configuration of the WorkItem Object Model (WI OM) within web applications. Unfortunately, after running through a couple of builds, I still ran into the COM interop issue within the web application. So, I need to flush out an alternate solution to this bug (From the sounds of it, this should be fixed with SP1 for .NET Framework 2.0).
tags: team foundation server, continuous integration, asp.net, .net, WorkItem Object Model, web service