cxf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sergey Beryozkin (JIRA)" <>
Subject [jira] [Commented] (CXF-6573) AccessToken doesn't serialize with snake-case
Date Tue, 08 Sep 2015 10:46:45 GMT


Sergey Beryozkin commented on CXF-6573:

I've experimented with JacksonJaxbJsonProvider, indeed, I can not set it up such that it ignores
a Map 'parameters' wrapper.
We do need to have that parameters extension at the model level as different token types,
not only 'bearer', have to be accommodated. I definitely know we can control it with CXF JSONProvider
but if it can not work with Jackson, then well, we won't worry about it to much - the existing
solution is good and can be further improved to avoid some possible clashes with Jackson (though
the possibility of such classes is only theoretical at this point given that I'm not sure
Jackson will ever change its Produces method from Wildcard to application/json).

If you do manage to make JacksonJaxbJsonProvider drop a 'parameters' wrapper, may using the
combination of JAXB type adapters and Jackson's own ObjectMapper, then please let me know
and I'll review the possibility of adding JAXB annotations to AccessToken   

> AccessToken doesn't serialize with snake-case
> ---------------------------------------------
>                 Key: CXF-6573
>                 URL:
>             Project: CXF
>          Issue Type: Wish
>          Components: JAX-RS Security
>    Affects Versions: 3.1.2
>            Reporter: Karl von Randow
>            Priority: Minor
> The class doesn't declare and JAXB
(or other) annotations to influence how it is serialized. So it uses the default serialization
style of the JAXB context.
> In my case this is camel case.
> This means that the AccessToken response from the AccessTokenService uses camel case.
The OAuth docs _appear_ (I'm not a scholar of them) to indicate that it should be snake case.
> Is that true? Is this a thing? Would it be something you'd consider, adding `@XmlElement(name
= "token_key")` annotations? That would be a breaking change for existing users...

This message was sent by Atlassian JIRA

View raw message