cxf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "David J. M. Karlsen (JIRA)" <>
Subject [jira] Created: (CXF-3175) Unmarshalling does not follow JAXB rules.
Date Wed, 08 Dec 2010 19:45:01 GMT
Unmarshalling does not follow JAXB rules.

                 Key: CXF-3175
             Project: CXF
          Issue Type: Bug
          Components: JAXB Databinding
    Affects Versions: 2.3.1
            Reporter: David J. M. Karlsen
            Priority: Blocker

I have a soapheader element which is declared as:
    <xsd:complexType name="EDBHeaderType">
            <xsd:element name="SourceApplication" type="xsd:string">

The JAXB2 generated code (through the cxf-codegen maven plugin will be:
@XmlType(name = "EDBHeaderType", propOrder = {
public class EDBHeaderType {

    @XmlElement(name = "SourceApplication", required = true)
    protected String sourceApplication;

which is OK, BUT - then I get this on service invocation from a client:
Caused by: javax.xml.bind.UnmarshalException: unexpected element (uri:"",
local:"SourceApplication"). Expected elements are <{<{}sourceApplication>

Check the casing! It expects lowercase elements, although they are declared uppercase. This
is not correct.
If I change it to lowercase it will in fact pass validation (but not adhere to the schema
which declared it).

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message