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: README.md
+58-12Lines changed: 58 additions & 12 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -125,17 +125,16 @@ You can see an example of this in the [remote-server-example](./solana-programs/
125
125
You can queue such a task by using `remoteV0` instead of `compileV0` in the `QueueTaskV0` instruction.
126
126
127
127
```typescript
128
-
awaitprogram.methods
129
-
.queueTaskV0({
130
-
id: taskId,
131
-
trigger: { now: {} },
132
-
transaction: {
133
-
remoteV0: {
134
-
url: "http://localhost:3002/remote",
135
-
signer: me,
136
-
},
128
+
awaitprogram.methods.queueTaskV0({
129
+
id: taskId,
130
+
trigger: { now: {} },
131
+
transaction: {
132
+
remoteV0: {
133
+
url: "http://localhost:3002/remote",
134
+
signer: me,
137
135
},
138
-
})
136
+
},
137
+
});
139
138
```
140
139
141
140
### Monitoring the Task Queue
@@ -150,7 +149,6 @@ Note that this will only show you tasks that have not been run. Tasks that have
150
149
151
150
If a task is active but has not yet been run, the cli will display a simulation result for the task. This is to help you debug the task if for some reason it is not running.
152
151
153
-
154
152
### Cron Tasks
155
153
156
154
Sometimes, it's helpful to run a task on a specific schedule. You can do this by creating a cron job. A cron job will queue tasks onto a task queue at a specific time. The following example will queue a task every minute. Note that you will need to keep the cron funded so that it can, in turn, fund the task queue for each task it creates.
A single cron job can queue multiple transactions. You can add transactions to a cron job by using the `cron-transaction` command. To add a normal transaction to a cron job, it is easier to write a script:
0 commit comments