domhanak commented on code in PR #2042:
URL: 
https://github.com/apache/incubator-kie-kogito-examples/pull/2042#discussion_r1914601253


##########
serverless-operator-examples/serverless-workflow-get-random-catfact/workflow.sw.json:
##########
@@ -0,0 +1,79 @@
+{
+  "id": "getCatFactInformation",
+  "version": "1.0",
+  "specVersion": "0.8.0",
+  "name": "Get cat fact",
+  "description": "Description",
+  "start": "GreetOrCatFact",
+   "functions": [
+      {
+         "name": "getCatFact",
+         "operation": "specs/catfacts.json#getRandomFact"
+      },
+      {
+        "name": "sysOutFunction",
+        "type": "custom",
+        "operation": "sysout"
+      }
+   ],
+  "states": [
+    {
+      "name": "GreetOrCatFact",
+      "type": "switch",
+      "dataConditions": [
+        {
+          "condition": "${ .fact == \"random\"}",
+          "transition": "GetRandomFact"
+        }
+      ],
+      "timeouts": {
+        "stateExecTimeout": "P4D",
+        "eventTimeout" : "P4D"
+      },
+      "defaultCondition": {
+        "transition": "GetOneStaticFact"
+      }
+    },
+    {
+      "name": "GetOneStaticFact",
+      "type": "inject",
+      "data": {
+        "message": "Cats are very cute"
+      },
+      "transition": "PrintTheFact"
+    },
+    {
+      "name": "GetRandomFact",
+      "type": "operation",
+      "actions": [
+        {
+          "name": "getRandomFact",
+          "functionRef": {
+              "refName": "getCatFact"
+          }
+        }
+      ],
+      "transition": "PrintTheFact",
+      "timeouts": {

Review Comment:
   @wmedvede adding more context, iirc we even updated the swf editor to 
support this



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to