Uploaded image for project: 'Kogito'
  1. Kogito
  2. KOGITO-7646

[KSW-Guides] Add JQ expression example of eventDataFilter

XMLWordPrintable

    • False
    • None
    • False
    • ---
    • ---

      Guide Kogito Serverless Workflow Guides > Core > jq expressions in Serverless Workflow mentions 3 areas of usage of jq expressions in Example of jq expressions in data filtering.

      But it provides examples just about 2, missing out the Event data filters option. Such an example is already available in kogito-examples in serverless-workflow-examples/serverless-workflow-callback-quarkus/src/main/resources/callback.sw.json as

       

          {
            "name": "waitForEvent",
            "type": "callback",
            "action": {
              "name": "publishAction",
              "eventRef": {
                "triggerEventRef": "resumeEvent",
                "data": "{move: \"This is the initial data in the model\"}"
              }
            },
            "eventRef": "waitEvent",
            "eventDataFilter": {
              "data": ".result",
              "toStateData": ".move"
            },
            "onErrors": [
              {
                "errorRef": "execution error",
                "end": true
              }
            ],
            "transition": "finish"
          }, 

      it would be nice to have this covered similarly to the other 2 cases.

       

          There are no Sub-Tasks for this issue.

              ftirados Francisco Javier Tirado Sarti
              jstastny@redhat.com Jan Stastny
              Jan Stastny Jan Stastny
              Jan Stastny Jan Stastny
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: