I’m currently working on setting up a task scheduler in Azure, and I’d appreciate some input on my proposed implementation. Here’s the gist:
- Task Scheduler Requirements: I need a system that can manage multiple task schedules, each linked to a unique task identifier. When the schedule triggers, the system should call a callback API for the corresponding task.
- Dynamic Scheduling: These schedules can vary from seconds to weeks, so the system must be flexible enough to handle this range.
- Rescheduling Capability: I also want to incorporate the ability to reschedule tasks that are already in the queue.
- Azure-Based Solution: I aim to keep the solution within the Azure ecosystem for ease of management and scalability. Additionally, the callback API will be hosted on ContainerApp and should be able to auto-scale as needed.
Given these requirements and the proposed approach, I’d love to hear any feedback or alternative suggestions. Are there any Azure services or features that could streamline this process further or offer better scalability and cost optimization?
Initial Approach: To implement this, I’m considering utilizing Azure Durable Functions. Each task schedule would trigger a Durable Function instance, which would then ‘sleep’ until the scheduled time. Upon waking, it would call the callback API for the respective task. To handle rescheduling, I plan to use external events to interrupt the sleep and update the schedule dynamically.
Vetri 007 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.