All Downloads are FREE. Search and download functionalities are using the official Maven repository.

shared.callback-state-timeouts.sw.json Maven / Gradle / Ivy

The newest version!
{
  "id": "callback_state_timeouts",
  "version": "1.0",
  "name": "Callback State Timeouts",
  "expressionLang": "jsonpath",
  "description": "Callback State Timeouts Test",
  "start": "CallbackState",
  "events": [
    {
      "name": "callbackEvent",
      "source": "",
      "type": "callback_state_timeouts_event_type"
    }
  ],
  "errors": [
    {
      "name": "callbackError",
      "code": "java.io.IOException"
    }
  ],
  "functions": [
    {
      "name": "callbackFunction",
      "type": "rest",
      "operation": "classpath:specs/external-service.yaml#sendRequest"
    }
  ],
  "states": [
    {
      "name": "CallbackState",
      "type": "callback",
      "action": {
        "name": "callbackAction",
        "functionRef": {
          "refName": "callbackFunction",
          "arguments": {
            "query" : "$.query" 
          }
        }
      },
      "eventRef": "callbackEvent",
      "transition": "FinalizeSuccessful",
      "onErrors": [
        {
          "errorRef": "callbackError",
          "transition": "FinalizeWithError"
        }
      ],
      "timeouts": {
        "eventTimeout": "PT5S"
      }
    },
    {
      "name": "FinalizeSuccessful",
      "type": "inject",
      "data": {
        "lastExecutedState": "FinalizeSuccessful"
      },
      "end": true
    },
    {
      "name": "FinalizeWithError",
      "type": "inject",
      "data": {
        "lastExecutedState": "FinalizeWithError"
      },
      "end": true
    }
  ]
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy