Shouldn't the default formatters be selected last?

Topics: Web Api
Jun 14, 2011 at 1:36 AM

Last night I noticed that any formatter that I specify in the configuration is appended to the end of the MediaTypeFormatterCollection instance. This is after the four default formatters. This caused my formatter, which was handling application/xml, not not get selected. Instead, the instance of XmlMediaTypeFormatter was being selected.

-Mike

Jun 14, 2011 at 2:05 AM

This has been suggested and I believe they are considering changing that behaviour.  I definitely agree it seems more logical that way.