camel-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Claus Ibsen (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CAMEL-7619) Rest DSL - Add support for json/xml bindings
Date Tue, 22 Jul 2014 16:54:38 GMT

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

Claus Ibsen commented on CAMEL-7619:
------------------------------------

Got the first prototype that can map json/xml to a pojo using the rest dsl defined as
{code}
                // use the rest DSL to define the rest services
                rest("/users/")
                    .post("new").as(UserPojo.class)
                        .to("mock:input");
{code}

Notice the "as" in the route. May come up with a better name.

The current code checks the content-type and message body to see if its json or xml and maps
accordingly using jackson. Though we may allow users to configure this behavior so they can
control if it should always be json only or xml only etc. 

> Rest DSL - Add support for json/xml bindings
> --------------------------------------------
>
>                 Key: CAMEL-7619
>                 URL: https://issues.apache.org/jira/browse/CAMEL-7619
>             Project: Camel
>          Issue Type: Sub-task
>          Components: camel-core
>    Affects Versions: 2.14.0
>            Reporter: Claus Ibsen
>            Assignee: Claus Ibsen
>             Fix For: 2.14.0
>
>
> see parent ticket
> So we can plugin json bindings such as jackson etc.
> And for xml, we can plugin jaxb etc.



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Mime
View raw message