Web Service Versioning
or how I learned to stop worrying and love UPA
SO - "If any microsoft speaker uses the word 'so,' everyone should respond 'What?'"
Doug significantly shortens his talk by 7 minutes by making us watch the recent infotainment commercial, Diversionary Tactics, in his and Don Box's .net show on Connected Systems. You can see the same if you don't mind the 80-240M download.
One of the guys in the skit has a brown leather jacket. I have the exact same jacket, procured from a thrift store in 96, though I am certain it is from the 70s.
Chris Sells "I take it back, I could see you at Burning Man."
Doug is a Lead Program Manager for Indigo
- indigo, AD, UDDI, msmq, system.messaging, remoting, wse, etc, etc
Versioning
The act of modifying an existing service
types of versioning
- backward compatible: v. 1.0 -> v 2.0
- forward compatible: v2.0 -> 1.0
Types of change
- breaking change -> not backward or forward compatible
- non-breaking change -> both compabilities
picture of v1 and v2 Person classes demonstrating compatibility
picture 2, if I add a new field, is it backward or forward compatible
adds a[n evil] schema validator - (which schema, btw)
Definition: Contract
A published agreement that details the capabilities of a piece of code
Types of contract:
- behavioral: all about the actions
- data: all about the data
General Guidance
be responsible for "The Program (the one program that everyone is writing, which isn't done yet)"
- Favor non-breaking changes wherever possible
Versioning is like security, if you don't think about it, you will pay
An easy guide, add, but don't remove
you may want to introduce breaking changes, and indigo will support it, but it is important to think about non-breaking changes early
Behavioral versioning options
1. Version by changing urls
2. Version by adding operations (cannot add outs or out, ins), because the client doesn't expect it.
3. Add new port type that has the same ops as previous port type (ctrl-C, ctrl-V extension)
TimE : If you go code->wsdl instead of contract first, the tools generate separate asmx files, so it isn't isomorphic
Data Contract Versioning guidance
1. Use anyType
<element name="Person" type="xsd:anyType" />
2. Use string
3. Open content model
(Martin [Gudgin] is a human schema validator.)
Doug speaking for us, "Doug, that sucks, no strong typing" (strong typing is for wimps)
4. Open content model + defined required fields
TIm Bray: For those of us doing point-point, do intermediary schema validators exist in the wild?"
DouglasP: could be in the middle, on the service, or on the client
Given this example (excluded), Martin, what is wrong: Martin: it's non-deterministic
Xml stack of record: infopath
5.
Comments