[ 
https://issues.apache.org/jira/browse/CXF-7186?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15756142#comment-15756142
 ] 

ASF GitHub Bot commented on CXF-7186:
-------------------------------------

GitHub user SanjinTulac opened a pull request:

    https://github.com/apache/cxf/pull/216

    Fixed CXF-7186: Aegis DataBinding ignores JAXB annotations on a field

    Please pull my fix for CXF-7186 in 2.7.x-fixes branch.
    
    Regards

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/SanjinTulac/cxf 2.7.x-fixes

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/cxf/pull/216.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #216
    
----
commit 7370e9ff599f6aa8ea6597bb2d13820555b82ff1
Author: Sanjin Tulač <[email protected]>
Date:   2016-12-17T02:14:01Z

    Fixed CXF-7186: Aegis DataBinding ignores JAXB annotations on a field

----


> Aegis DataBinding ignores JAXB annotations on a field
> -----------------------------------------------------
>
>                 Key: CXF-7186
>                 URL: https://issues.apache.org/jira/browse/CXF-7186
>             Project: CXF
>          Issue Type: Bug
>          Components: Aegis Databinding
>    Affects Versions: 2.7.18
>            Reporter: Sanjin Tulac
>
> I've been trying to use CXF with Aegis DataBinding to host a web service that 
> needs to be called by a 3rd party, using 3rd party's XML schema.
> It turns out that 3rd party XML schema has a naming convention that element 
> names start with upper case. wsdl2java correctly placed JAXB XMLElement 
> annotations on the fields in the generated POJOs, But at run-time, Aegis 
> DataBinding ignores these JAXB annotations on the fields, which causes the 
> XML from 3rd party to be ignored, instead of converted to the generated POJOs.
> I've identified the culprit to be 
> org.apache.cxf.aegist.type.AnnotatedTypeInfo class, whose method createQName 
> only looks for annotations on the getter methods, but ignores annotations on 
> fields.
> I can see that this defect stems from the attempt to support both Aegis and 
> JAXB annotations: former expect annotations on the getter methods, but latter 
> however, even though quite similar, expect annotations on the field.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to