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: docs/sections/queueing_jobs.md
+41-2Lines changed: 41 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -25,8 +25,9 @@ to do this.
25
25
26
26
The `createJob()` function takes three arguments.
27
27
- The first argument is the name of the type of job that you are creating.
28
-
- The second argument is optional, but if set must be an array of data and will be passed as a parameter to the `run()` function of the worker.
29
-
- The third argument is options (`'notBefore'`, `'priority'`, `'group'`).
28
+
- The second argument is optional, but if set must be an array of data and will be passed as a payload parameter to the `run()` function of the worker.
29
+
It can also be a (DTO) object that implements `CakeDto\Dto\FromArrayToArrayInterface` or provides `toArray()` method.
30
+
- The third argument is options (`'notBefore'`, `'priority'`, `'group'`, `'reference'`). Either as array or `Queue\Config\JobConfig` class.
30
31
31
32
> `priority` is sorted ascending, therefore a task with priority 1 will be executed before a task with priority 5
0 commit comments