media type compatibility

From: Bill Burke <>
Date: Wed, 09 Apr 2008 11:30:33 -0400

Consider this resource:

public String get();

Is it compatible with the content-type of "application/xml;schema=foo"?

My thinking is that it is not compatible. Why?

Consider this example:

Accept: application/xml;schema=foo;q=1.0, application/xml;schema=bar;q=0.5

Content-type: application/xml;schema=stuff

The resource:

public class MyESB {

    public String method1() {}

    public String method2() {}

 From the current spec implementation(if i understand the rules
correctly) with this request, method1 will be matched because the Accept
precedence and my application will fail as the XML document sent will be
incompatible with method 1.

Bill Burke
JBoss, a division of Red Hat