You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: dashjoin-docs/docs/developer-reference.md
+36Lines changed: 36 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1049,6 +1049,42 @@ This sample data is used to edit the mapping.
1049
1049
Note that Receive always appends the new data like the Ignore mode in the ETL case. The difference is that there
1050
1050
is no expression that fetches data. Instead, the data is passed via the API call.
1051
1051
1052
+
### Scheduling
1053
+
1054
+
Functions can be scheduled to run periodically. Using Dashjoin Studio, you can either set an interval or a cron schedule.
1055
+
Use cron if your jobs should run based on a calendar, every weeknight at 2am, for instance. Use intervals for
1056
+
simple schedules like: run every hour.
1057
+
1058
+
When a function is run by the scheduler, it uses the role "scheduler". Therefore, make sure that the function roles include this role.
1059
+
Consider the following example that runs an invoke function every hour (note that the function is run without input parameter):
1060
+
1061
+
```
1062
+
{
1063
+
"ID": "interval",
1064
+
"djClassName": "org.dashjoin.function.Invoke",
1065
+
"expression": "...",
1066
+
"every": "1h",
1067
+
"roles": [
1068
+
"scheduler"
1069
+
]
1070
+
}
1071
+
```
1072
+
1073
+
Please refer to this [documentation](https://quarkus.io/guides/scheduler-reference#intervals) for information about the interval string format.
1074
+
The next example uses the [cron](https://quarkus.io/guides/scheduler-reference#cron) syntax to run the function every day at 10:15:
1075
+
1076
+
```
1077
+
{
1078
+
"ID": "interval",
1079
+
"djClassName": "org.dashjoin.function.Invoke",
1080
+
"expression": "...",
1081
+
"cron": "0 15 10 * * ?",
1082
+
"roles": [
1083
+
"scheduler"
1084
+
]
1085
+
}
1086
+
```
1087
+
1052
1088
## Dashjoin Expression Reference
1053
1089
1054
1090
In addition to the default JSONata built-in functions ([see Function Library](https://docs.jsonata.org/overview.html)), the following Dashjoin functions are added
0 commit comments