【问题标题】:How to schedule jobs for python code in Firebase?如何在 Firebase 中为 python 代码安排作业?
【发布时间】:2018-02-18 12:47:42
【问题描述】:

我想让我的代码每天在 firebase 服务器上运行一次。该代码使用一些从 HTTP 库中提取的数据作为美丽的汤。经过一番搜索,我找不到合适的结果。你能告诉我怎么做吗?提前致谢

【问题讨论】:

    标签: python firebase google-cloud-platform google-cloud-functions


    【解决方案1】:

    您可以查看function-cron,它允许您在Firebase 中安排cron 作业。

    Google App Engine 提供 Cron 服务。使用此服务 调度和 Google Cloud Pub/Sub 用于分布式消息传递,您可以 构建一个应用程序以可靠地安排可以触发的任务 谷歌云函数。 https://github.com/firebase/functions-cron

    【讨论】:

      【解决方案2】:

      您现在可以使用 Google Cloud Scheduler 通过 Google Pub/Sub 触发作业 - 这是一项完全托管的服务,运行起来非常便宜。见这里:https://cloud.google.com/scheduler/

      【讨论】:

        猜你喜欢
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 2018-04-25
        • 2013-07-28
        • 2010-09-12
        • 2020-01-05
        • 1970-01-01
        • 1970-01-01
        相关资源
        最近更新 更多