数据需要每天 / 每小时跑一次,怎么调度?

按数据量从小到大:

crontab(系统级)

schedule(Python 库)

import schedule
schedule.every().day.at("03:00").do(my_job)
while True:
    schedule.run_pending()
    time.sleep(60)

APScheduler

Celery + Redis/RabbitMQ

Airflow

我自己接单的经验:

别一上来就上 Airflow,80% 的项目用 crontab 就够。


本文由 BBZ · 小朵科技工作室 出品。