Azure的WebRole计划任务,每天早上

编程入门 行业动态 更新时间:2024-10-19 08:46:24
本文介绍了Azure的WebRole计划任务,每天早上的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我试图找出解决的办法得到一个WebRole每天早上早上5点运行任务。我已经看过Quartz.Net和计算器,但所有这些例子预定任务每10分钟运行。有没有表现出任何的例子我该怎么安排呢?

I am trying to figure out a solution to getting a WebRole to run a Task every morning at 5AM. I have looked at Quartz.Net and the examples on stackoverflow but all of them schedule the task to run every 10 minutes. Are there any examples that show how I can schedule it?

推荐答案

Quartz.Net应该是很好的you.Try使用的 CronTrigger (或 CronTriggerImpl在 2.x版)。

Quartz.Net should be good for you.Try to use CronTrigger (or CronTriggerImpl in version 2.x).

的cron-EX pression的例子 - 0 0 5 * *? - 每天早上5点运行。

Example of cron-expression - "0 0 5 * * ?" - run every day at 5 AM.

触发克龙子前pression位置意思是:

Cron trigger sub-expression position meaning:

  • 秒 - 0 你(在0跑秒)
  • 分 - 0 你(在0分钟内)
  • 小时 - 5 为你(在5个小时的运行; 它采用24小时制的)
  • 某一天的月 - * - 天天跑
  • 月 - * 你(运行每月)
  • 某一天的周 - ? - 你(某一天的一个月时间已代替)
  • 没有指定
  • 年(可选字段) - 的不使用的
  • Seconds - 0 for you (run at 0 second)
  • Minutes - 0 for you (run at 0 minutes)
  • Hours - 5 for you (run at 5 hour; it uses 24-hour clock)
  • Day-of-Month - * - run every day
  • Month - * for you (run every month)
  • Day-of-Week - ? - not specified for you (Day-of-Month has been used instead)
  • Year (optional field) - not used
  • 更多推荐

    Azure的WebRole计划任务,每天早上

    本文发布于:2023-11-27 04:10:44,感谢您对本站的认可!
    本文链接:https://www.elefans.com/category/jswz/34/1636535.html
    版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
    本文标签:早上   计划   Azure   WebRole

    发布评论

    评论列表 (有 0 条评论)
    草根站长

    >www.elefans.com

    编程频道|电子爱好者 - 技术资讯及电子产品介绍!