Google AppEngine PYTHON 灵活的环境是否支持任务队列?
Does Google AppEngine PYTHON flexible Environment support task queues?
我长期以来一直将 GAE STANDARD 与 webApp2 一起使用。它对任务队列有很好的支持和文档。但是现在我刚开始使用 Python FLASK 和 Google AppEngine FLEXIBLE,与 GAE Standard 中对任务队列的文档和支持相比,我找不到任何明确的任务队列文档。
如果支持任务队列,或者有人使用过它们,请分享可能有用的链接或文档。
其次,您认为后台任务(例如 Celery 等)是否有替代或更好的方法?
任何意见都会非常有帮助。
来自Task Queues in Migrating Services from the Standard Environment to the Flexible Environment:
The Task Queue service has limited availability outside of the
standard environment. If you want to use the service outside of the
standard environment, you can sign up for the Cloud Tasks alpha.
Outside of the standard environment, you can't add tasks to push
queues, but a service running in the flexible environment can be
the target of a push task. You can specify this using the
target
parameter when adding a task to queue or by specifying
the default target
for the queue in queue.yaml
.
In many cases where you might use pull queues, such as queuing up
tasks or messages that will be pulled and processed by separate
workers, Cloud Pub/Sub can be a good alternative as it offers
similar functionality and delivery guarantees.
正如 Dan 回答的那样,Cloud Pub/Sub 是一个不错的选择。
这是我发现的另一个 answer,非常有用。
我长期以来一直将 GAE STANDARD 与 webApp2 一起使用。它对任务队列有很好的支持和文档。但是现在我刚开始使用 Python FLASK 和 Google AppEngine FLEXIBLE,与 GAE Standard 中对任务队列的文档和支持相比,我找不到任何明确的任务队列文档。 如果支持任务队列,或者有人使用过它们,请分享可能有用的链接或文档。 其次,您认为后台任务(例如 Celery 等)是否有替代或更好的方法? 任何意见都会非常有帮助。
来自Task Queues in Migrating Services from the Standard Environment to the Flexible Environment:
The Task Queue service has limited availability outside of the standard environment. If you want to use the service outside of the standard environment, you can sign up for the Cloud Tasks alpha.
Outside of the standard environment, you can't add tasks to push queues, but a service running in the flexible environment can be the target of a push task. You can specify this using the
target
parameter when adding a task to queue or by specifying the defaulttarget
for the queue inqueue.yaml
.In many cases where you might use pull queues, such as queuing up tasks or messages that will be pulled and processed by separate workers, Cloud Pub/Sub can be a good alternative as it offers similar functionality and delivery guarantees.
正如 Dan 回答的那样,Cloud Pub/Sub 是一个不错的选择。 这是我发现的另一个 answer,非常有用。