We’ve recently made updates to the WebJobs Portal experience in the Azure Portal designed to make it easier to set up a scheduled triggered WebJob, access the trigger URL for triggered WebJobs, and other operations like viewing your logs.
Creating a scheduled WebJob
As you can see in the screenshot, to create a scheduled WebJob requires 3 steps, in addition to the usual steps of naming and uploading your code.
- Select “triggered” as the WebJob type option
- Select “Scheduled” as the WebJob triggers option
- Add a cron tab expression
To create a scheduled WebJob in the new experience, you just provide a cron tab expression as part of the creation of your triggered WebJob. This will add a schedule property to your
setting.job file which Kudu will then use to call your WebJob. Importantly, this requires “always on” to be enabled. If you wish to have a triggered WebJob called on a schedule without “always on” being required or if the schedule you require is too complicated to be expressed as a cron tab expression, you can continue to use Azure Scheduler by choosing the “WebHook” option for “Triggers”, and then providing the trigger URL to an Azure Scheduler job. This is a departure from how we previously did scheduled jobs, where we’d automatically create a Azure Scheduler job for you. We had a lot of feedback that this wasn’t optimal for all scenarios, so we’ve moved to this new model.
Updates to browse WebJobs experience
In addition to the triggered WebJobs updates, we’ve redone the browse experience to both bring it in line with the other browse experiences in the portal, as well as expose the trigger URL for triggered WebJobs in an easier to access way. One major experience change is that the logs, delete, and run buttons at the top of the blade correspond with the selected row. You can see this experience in the picture below.
We’re always looking for more feedback on the WebJobs experience. You can leave feedback on the WebJobs UX experience at our feedback site or in the comments section down below.