Description
A request with header
Content-Type: application/json;charset=UTF-8
will not match a method annotated with
@Consumes("application/json; charset=utf-8")
This is unfortunate since the former casing of "UTF-8" is used by several front-end frameworks, for instance Google's AngularJS (ngResource), and the latter casing is used several places by the Internet (w3.org for example).
The "bug" is located here:
org.apache.cxf.jaxrs.utils.JAXRSUtils#intersectMimeTypes(java.util.List<MediaType>, java.util.List<MediaType>, boolean, boolean)
if (value != null && !value.equals(entry.getValue())) {
should be
if (value != null && !value.equalsIgnoreCase(entry.getValue())) {