dongqian1893 2015-04-30 09:24
浏览 32
已采纳

Appengine cron.yaml定义未显示在开发人员控制台中

I have a basic appengine project with multiple modules and a dispatch.yaml:

  • my-project/boxes/app.yaml (default module)
  • my-project/users/app.yaml (users module)
  • my-project/dispatch.yaml

I'm trying to configure a single hourly cronjob with the following definition:

cron:
- description: hourly box purging
  url: /api/boxes.purge
  schedule: every 1 hours
  target: default

I've tried adding it to the module it concerns, so put the above definition in file: 'my-project/boxes/cron.yaml' and running appcfg.py cron_info boxes/. My terminal seems to indicate all went well:

hourly box purging:
URL: /api/boxes.purge
Schedule: every 1 hours (UTC)
2015-04-30 10:08:00Z, 0:59:55 from now
2015-04-30 11:08:00Z, 1:59:55 from now
2015-04-30 12:08:00Z, 2:59:55 from now
2015-04-30 13:08:00Z, 3:59:55 from now
2015-04-30 14:08:00Z, 4:59:55 from now

Ye the Appengine Developer console fails to reflect this and cron jobs are not run. It does show on the local development panel.

Putting the definition in the root of the projects (besides dispatch.yaml) yields the same results. Other things i've tried (in vain): Redeploying all code, appcfg.py update_dispatch, waiting a while before refreshing the developer console.

Hopefull someone is able to help me find the obvious mistake, or confirm that their is some bug.

  • 写回答

1条回答 默认 最新

  • dongyu9667 2015-04-30 18:39
    关注

    In the Configuration section of the doc it's stated:

    Optional application-level configuration files (dispatch.yaml, cron.yaml, index.yaml, and queue.yaml) are included in the top level app directory.

    I agree, the paragraph context appears to leave room for interpretation (typically...). But the quoted text also indicates that these files are considered app-level configs. So I'd keep them at the top.

    About the update: I noticed, for example, that the index.yaml file was NOT uploaded with the rest of the multi-module app at my first deployment, I had to explicitly use appcfg.py update_indexes. This was not happening with a single module app. Maybe appcfg.py update_cron also needs to be explicit?

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥35 平滑拟合曲线该如何生成
  • ¥100 c语言,请帮蒟蒻写一个题的范例作参考
  • ¥15 名为“Product”的列已属于此 DataTable
  • ¥15 安卓adb backup备份应用数据失败
  • ¥15 eclipse运行项目时遇到的问题
  • ¥15 关于#c##的问题:最近需要用CAT工具Trados进行一些开发
  • ¥15 南大pa1 小游戏没有界面,并且报了如下错误,尝试过换显卡驱动,但是好像不行
  • ¥15 自己瞎改改,结果现在又运行不了了
  • ¥15 链式存储应该如何解决
  • ¥15 没有证书,nginx怎么反向代理到只能接受https的公网网站