camel-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Aki Yoshida <elak...@gmail.com>
Subject Usefulness of the current Map or List to String conversion in Camel
Date Mon, 24 Aug 2015 11:54:47 GMT
Hi,
Currently, the default conversion from Map or List to String is based
on the JDK's default serialization. So, if you have a map having
entries "name"="peach", "taste"="sweet", you get

{name=peach, taste=sweet}

This representation is somewhat useless except for the logging
purpose. This format does not handle special characters and it is not
interoperable. So, I am wondering if we can instead use JSONObject's
default serialization so that you will get instead

{"name":"peach","taste":"sweet"}

This string is interoperable and can be easily processed.

If this conversion works directly (we could make it enabled or
disabled using a property), I think that will be very practical for
generic map and list objects.

Comments appreciated.

regards, aki

Mime
View raw message