CAMEL-10646: Add docs
Project: http://git-wip-us.apache.org/repos/asf/camel/repo Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/af22f502 Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/af22f502 Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/af22f502 Branch: refs/heads/master Commit: af22f502ec1b3dfcf47e4f55e79d7192abf3bfc5 Parents: de9cc25 Author: Claus Ibsen <davscl...@apache.org> Authored: Fri Dec 23 13:14:13 2016 +0100 Committer: Claus Ibsen <davscl...@apache.org> Committed: Fri Dec 23 13:14:13 2016 +0100 ---------------------------------------------------------------------- .../src/main/docs/jsonpath-language.adoc | 25 ++++++++++++++++++++ 1 file changed, 25 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/camel/blob/af22f502/components/camel-jsonpath/src/main/docs/jsonpath-language.adoc ---------------------------------------------------------------------- diff --git a/components/camel-jsonpath/src/main/docs/jsonpath-language.adoc b/components/camel-jsonpath/src/main/docs/jsonpath-language.adoc index 73327f3..11ffb57 100644 --- a/components/camel-jsonpath/src/main/docs/jsonpath-language.adoc +++ b/components/camel-jsonpath/src/main/docs/jsonpath-language.adoc @@ -81,6 +81,31 @@ Syntax See the https://code.google.com/p/json-path/[JSonPath] project page for further examples. +[[JSonPath-SupportedType]] +Supported message body types +~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +Camel JSonPath supports message body using the following types: + +{% raw %} +[width="100%",cols="3m,7",options="header"] +|======================================================================= +| Type | Comment +| File | Reading from files +| String | Plain strings +| Map | Message bodies as `java.util.Map` types +| List | Message bodies as `java.util.List` types +| POJO | *Optional* If Jackson is on the classpath, then camel-jsonpath + is able to use Jackson to read the message body as POJO and convert to `java.util.Map` + which is supported by JSonPath. For example you can add `camel-jackson` as dependency to include Jackson. +| InputStream | If none of the above types matches, then Camel will attempt to read the message body as an `java.io.InputStream`. +|======================================================================= +{% endraw %} + +If a message body is of unsupported type then an exception is thrown by default, however you +can configure JSonPath to suppress exceptions (see below) + + [[JSonPath-Suppressexceptions]] Suppress exceptions ~~~~~~~~~~~~~~~~~~~