Uploaded image for project: 'Camel'
  1. Camel
  2. CAMEL-10702

camel-jsonpath - Allow to define predicates even easier

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.19.0
    • Component/s: camel-jsonpath
    • Labels:
      None
    • Estimated Complexity:
      Unknown

      Description

      When using jsonpath for predicates the syntax can be a bit complex to understand and learn for even the simplest things.

      So having to do

                              .when().jsonpath("$.store.book[?(@.price < ${header.cheap})]")
      

      We can try to let Camel be smart and help you with a easy syntax when you have one operator and in predicate mode, so this can be just

                              .when().jsonpath("store.book.price < ${header.cheap}")
      

      Then camel-jsonpath will parse this and build the complexer jsonpath syntax on your behalf.

      Not having to remember the complexities of [?@.] and other hard to remember symbols to just say a simple predicate if X < Y etc.

        Attachments

          Activity

            People

            • Assignee:
              davsclaus Claus Ibsen
              Reporter:
              davsclaus Claus Ibsen
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: