camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gary Kennedy <>
Subject Re: Setting rest response json directly
Date Wed, 05 Nov 2014 23:23:08 GMT
I'm using blueprint, but yes, it does not work.

        <cml:simple>{ "exception": "${exception.message}" }</cml:simple>

Produces response content of:
    "{ \"error\": \"${exception.message}\" }"

Instead of:
    { "error": "${exception.message}" }

I'm using the servlet/rest config, ie:
        <restConfiguration component="servlet" bindingMode="json"/>
        <rest consumes="application/json" produces="application/json">
                    < !-- lots of magic -->
                        < !-- more magic -->
                            <simple>{ "error": "${exception.message}"

(Sorry. I should have included this snippet in the first email)


View this message in context:
Sent from the Camel - Users mailing list archive at

View raw message