Skip to content

Commit 6ba32e2

Browse files
author
Tihomir Surdilovic
committed
update to schedule def cron
Signed-off-by: Tihomir Surdilovic <[email protected]>
1 parent 036c7b1 commit 6ba32e2

File tree

6 files changed

+30
-6
lines changed

6 files changed

+30
-6
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
{
2+
"type": "object",
3+
"javaType": "io.serverlessworkflow.api.cron.Cron",
4+
"description": "Schedule cron definition",
5+
"properties": {
6+
"expression": {
7+
"type": "string",
8+
"description": "Repeating interval (cron expression) describing when the workflow instance should be created"
9+
},
10+
"validUntil": {
11+
"type": "string",
12+
"description": "Specific date and time (ISO 8601 format) when the cron expression invocation is no longer valid"
13+
}
14+
},
15+
"required": [
16+
"expression"
17+
]
18+
}

api/src/main/resources/schema/schedule/schedule.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@
88
"description": "Time interval (ISO 8601 format) describing when the workflow starting state is active"
99
},
1010
"cron": {
11-
"type": "string",
12-
"description": "Repeating interval (cron expression) describing when the workflow starting state should be triggered"
11+
"description": "Schedule cron definition",
12+
"$ref": "../cron/crondef.json"
1313
},
1414
"directInvoke": {
1515
"description": "Define if workflow instances can be created outside of the defined interval/cron",

api/src/test/resources/examples/periodicinboxcheck.json

+3-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,9 @@
1919
"type": "operation",
2020
"start": {
2121
"schedule": {
22-
"cron": "0 0/15 * * * ?"
22+
"cron": {
23+
"expression": "0 0/15 * * * ?"
24+
}
2325
}
2426
},
2527
"actionMode": "sequential",

api/src/test/resources/examples/periodicinboxcheck.yml

+2-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,8 @@ states:
1212
type: operation
1313
start:
1414
schedule:
15-
cron: 0 0/15 * * * ?
15+
cron:
16+
expression: 0 0/15 * * * ?
1617
actionMode: sequential
1718
actions:
1819
- functionRef:

diagram/src/test/resources/examples/periodicinboxcheck.json

+3-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,9 @@
1919
"type": "operation",
2020
"start": {
2121
"schedule": {
22-
"cron": "0 0/15 * * * ?"
22+
"cron": {
23+
"expression": "0 0/15 * * * ?"
24+
}
2325
}
2426
},
2527
"actionMode": "sequential",

diagram/src/test/resources/examples/periodicinboxcheck.yml

+2-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,8 @@ states:
1212
type: operation
1313
start:
1414
schedule:
15-
cron: 0 0/15 * * * ?
15+
cron:
16+
expression: 0 0/15 * * * ?
1617
actionMode: sequential
1718
actions:
1819
- functionRef:

0 commit comments

Comments
 (0)