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] [Assigned] (CAMEL-10189) camel-jsonpath - Add support for simple functions
Date Sun, 31 Jul 2016 07:53:20 GMT

     [ https://issues.apache.org/jira/browse/CAMEL-10189?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Claus Ibsen reassigned CAMEL-10189:
-----------------------------------

    Assignee: Claus Ibsen

> camel-jsonpath - Add support for simple functions
> -------------------------------------------------
>
>                 Key: CAMEL-10189
>                 URL: https://issues.apache.org/jira/browse/CAMEL-10189
>             Project: Camel
>          Issue Type: Improvement
>          Components: camel-jsonpath
>            Reporter: Claus Ibsen
>            Assignee: Claus Ibsen
>
> See SO
> http://stackoverflow.com/questions/38609231/can-i-use-camel-simple-expression-inside-jsonpath-language
> We can roll our own predicates in jsonpath where you can use ? as the placeholder. The
trick would be to either inline the functions in the string, and then do our own pre-parsing
to replace those predicates to ?, eg
> {code}
> "$.person[?(@.role=='${headers.role}')]"
> {code}
> gets pre-parsed as
> {code}
> "$.person[?(@.role=='?')]"
> {code}
> And then we know that ${headers.role} is the simple funktion to execute as the predicate.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message