How to manually invoke a Timer Trigger Azure function on Azure Portal?

Viewed 1420

I have published a Timer Trigger Azure Function to my Azure account. I configured it to run twice a day but I would like to be able to run on demand. Surprisingly it is not a easy to find feature, neither easy to find online for help.

3 Answers

Azure Function Timer Trigger - I configured it to run twice a day but I would like to be able to run on demand.

I believe your ask is - Is it possible to run the Timer Triggered Azure Function on demand/request.

Scenario 1:

AFAIK, that is not possible to run on-demand/request the Azure Timer Triggered Function with the same function but we can use an HTTP Triggered function as the 2nd function which uses the same logic as the timer function that runs on a schedule - is the best approach for testing on-demand basis.

Please check the example described here.

Scenario 2:

Suppose the scenario is running/testing the Azure Function Timer Trigger after every deployment but the CRON is configured twice in a day or other, then the runOnStartup setting is used as documented here and in MSFT docs, which triggers the function when the runtime starts but won't cause the runtime to start as a result of a deployment.

Related