芹菜,如果 eta 过去了,apply_async 会怎样?

celery, what happens to apply_async if eta is past?

难调试自己摸索

如果当您调用 apply_async() 时 eta 已过会怎样?

默默滴?执行它是因为它应该在过去?

来自文档:

The ETA (estimated time of arrival) lets you set a specific date and time that is the earliest time at which your task will be executed. countdown is a shortcut to set eta by seconds into the future. The task is guaranteed to be executed at some time after the specified date and time, but not necessarily at that exact time.

我刚刚在我们的设置上对此进行了测试,过去的 eta 绝对有效。 Celery 不会放弃任务 - 它或多或少会立即执行。希望这对您有所帮助!