Thank you @Nasreen Akter ,
the CRON expression was auto-generated, and seem fine.
I however found a fix that magically got the trigger to fire and seem working.
The Application Settings missed an "AzureWebJobsStorage" key, that seems to be required to run timer triggers as pointed out here.
Inserted a storage account connection string as value in there, and the trigger magically started to fire.
Thank you for the support, hope this helps someone else.
Regards
Azure Function Time Trigger not Firing
I am trying Function Apps with App Service Plan tier F1:Free.
I created a timer triggered function with the browser interface:
run.csx:
using System;
public static void Run(TimerInfo myTimer, ILogger log)
{
log.LogInformation("Test");
}
function.json:
{
"bindings": [
{
"name": "myTimer",
"type": "timerTrigger",
"direction": "in",
"schedule": "0 */5 * * * *"
}
]
}
I never managed to see the function running once.
I browsed for hours in search of a solution with no avail.
"Always on" is not available in this service plan, but I'm not clear if this is needed.
Can anyone point out how can I get it to work or at least collect more information on what's wrong?
Thank you!
Azure Functions
-
Dario Rossa 106 Reputation points
2021-04-12T18:46:35.753+00:00
1 additional answer
Sort by: Most helpful
-
Nasreen Akter 10,811 Reputation points Volunteer Moderator
2021-04-12T18:23:27.6+00:00 Hi @Dario Rossa ,
CRON expression consists of the following six fields:
{second} {minute} {hour} {day} {month} {day of the week}
Please make sure you included all six units in the schedule. For example, e.g.,
0 */5 * * * *
. Example in the below link might help. Thanks!https://learn.microsoft.com/en-us/azure/azure-functions/functions-bindings-timer?tabs=csharp#example