views:

352

answers:

1

I have just written a new version of a WCF web service and I want to make sure that I have not made any breaking changes with regard to Service and Data contracts.

Thinking back to my days as a VB6 Com Api developer I recall how easy it was to specify the previous release version of the component at compile time, and have the compiler check that binary compatibility is being maintained.

I envisage something similar called (hopefully) a “Contract Compatibility” check. It would use the metadata to perform a similar check to the one that the VB6 dev env did. This could be done as a separate build step that would execute a utility.

I am prepared to accept that there exists no such utility out there. If that is the case, does anyone have any ideas about how the algorithm to achieve this would look?

  1. Retrieve metadata from current live service version
  2. Retrieve meta data from new service version
  3. Check Service Contract and each Data Contract for compatibility. Only reporting breaking changes.

Step 3 seems like it would be complex but certainly automatable...

A: 

Nothing like that exists Andy but if you get something up and running whereby you have 2 DLLs (one old and one new), you could then use something like BitDiffer to compare them.

There was a project on Codeplex that helped with WCF releases, but I can't remember what it is called, sorry.

Good luck,

-Keith

Keith Elder