Triggers by time



  • The SDK supports time triggered based on CRON expressions with 6 fields ({second} {minute} {hour} {day} {month} {day of the week}). It requires an extra setting on the JobHostConfiguration:
config.UseTimers();
click below button to copy the code. By azure tutorial team
  • Your time triggered functions respond to this syntax:
// Runs once every 5 minutes
public static void CronJob([TimerTrigger("0 */5 * * * *")] TimerInfo timer)
{
    
}

// Runs immediately on startup, then every two hours thereafter
public static void StartupJob([TimerTrigger("0 0 */2 * * *", RunOnStartup = true)] TimerInfo timerInfo)
{
    
}
click below button to copy the code. By azure tutorial team

Related Searches to Triggers by time