Rename Client Process method to Schedule

This commit is contained in:
Ken Hibino
2020-01-03 20:24:18 -08:00
parent 9256fb6023
commit 606b0fae64
6 changed files with 13 additions and 13 deletions

View File

@@ -73,13 +73,13 @@ func main() {
}
// process the task immediately.
err := client.Process(&t1, time.Now())
err := client.Schedule(&t1, time.Now())
// process the task 24 hours later.
err = client.Process(&t2, time.Now().Add(24 * time.Hour))
err = client.Schedule(&t2, time.Now().Add(24 * time.Hour))
// specify the max number of retry (default: 25)
err = client.Process(&t1, time.Now(), asynq.MaxRetry(1))
err = client.Schedule(&t1, time.Now(), asynq.MaxRetry(1))
}
```