I was asked to share a list of best practices I wrote for data contracts and data members so here it is:
Next time: Using Call Context Initializers for Cleanup
What are the consequences of adding enum members to a DataContract between versions? What bad things result from reordering data members?
How can I directly craft the XML content that goes into a fault detail? Getting control over the detail
Hi Jeff,
Adding or removing enum members is a breaking change because unlike adding or removing data members, there's no concept of a default value or extensibility hook to handle unknown enum values.
Reordering data members breaks parsers that assume a particular sequence of elements in a complex type. In most cases it's relatively easy to avoid this even when changing a contract by explicitly setting the Order on the attribute.