Printing Flexible Message Headers

When a message header supports multiple representations, which version is used when the message header is printed?

A message header is a piece of data about the message that’s carried on the wire somewhere apart from the message contents. When using an enveloped message format like SOAP, there’s typically an explicit container for message headers and rules for what those message headers should look like. For other message formats, the message header may look different depending on the type of data that the message header represents and how the message header is transmitted. The same message header may have a different way of being expressed on the wire depending on the format of the message in which the header is contained.

If the message header is printed together with a message, then the message header obviously should just use the same format as was used by the message. However, since message headers are independent objects, you can pull out a message header on its own and try to look at it. When you do that, the message header is queried for all of the message formats that it could be used with, and one of those message formats needs to be picked.

Here’s the order of preference for picking among the available message formats:

  1. SOAP 1.2 with WS-Addressing 1.0
  2. SOAP 1.2 with WS-Addressing August 2004
  3. SOAP 1.1 with WS-Addressing 1.0
  4. SOAP 1.1 with WS-Addressing August 2004
  5. SOAP 1.2 without addressing
  6. SOAP 1.1 without addressing
  7. No envelope or addressing

Next time: Understanding MustUnderstand

Comments (1)

  1. In the article about serialization conflicts , one of the points mentioned was that CollectionDataContract