You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm using the new C# assembly deployments in Azure Functions.
I want to be able to configure my timer trigger schedule differently in pre-production environments (less frequently) than in production. I'm running a script in my VSTS release to modify the function.json file in the web deploy package before deploying to my App Service.
It looks like whatever string is passed into the TimerTriggerAttribute constructor overrides the value in function.json. I've tried the second overload of the constructor to avoid compiling the schedule into the assembly but the compiler throws an error that the ScheduleType property is not supported.
Is there any supported way of configuring timer schedules differently in different environments, other than compiling different versions of the assembly?
The text was updated successfully, but these errors were encountered:
Yes. Instead of hardcoding a cron expression, put the expression in an app setting and refer to it using % signs. For instance, if you have a setting called CRON_EXPRESSION:
I'm using the new C# assembly deployments in Azure Functions.
I want to be able to configure my timer trigger schedule differently in pre-production environments (less frequently) than in production. I'm running a script in my VSTS release to modify the function.json file in the web deploy package before deploying to my App Service.
It looks like whatever string is passed into the TimerTriggerAttribute constructor overrides the value in function.json. I've tried the second overload of the constructor to avoid compiling the schedule into the assembly but the compiler throws an error that the ScheduleType property is not supported.
Is there any supported way of configuring timer schedules differently in different environments, other than compiling different versions of the assembly?
The text was updated successfully, but these errors were encountered: