Windows Azure Job Scheduling in C # .net

I want to implement a task scheduler in my azure app for windows.

My goal is to run a specific application every day at a specific time. For this implementation, I have a choice

1-Using Quartz.net

Windows 2 Scheduler

If there is a built-in method available in C # .net to implement this. It's hard for me to talk about the Windows Azure HPC Scheduler. Is this a planner ?.

+4
source share
4 answers

During the planning, many answers were given (therefore, I assumed that this was a duplicate), I realized that you asked a few specific questions that were not addressed:

  • The HPC Scheduler is designed for HPC workloads and is not suitable for your purposes as a general task scheduler.
  • There is no special task scheduler using C # = you need to write one or use a library like quartz.
  • Remember that web and worker roles are mainly virtual machines in Windows 2008 Server. Whatever you do in Windows Server, you can do almost the same thing in Windows Azure virtual machines.

See the other answer that I am referring to, as I am providing you with an answer that gives you detailed information about creating a scheduler.

+2
source

Recently, the task scheduler functionality in Windows Azure has been added, making it easy to schedule tasks at certain intervals:

enter image description here

Here is a blog post explaining how you can use these tasks to communicate with websites, online roles, and even work roles: http://fabriccontroller.net/blog/posts/job-scheduling-in-windows-azure /

+6
source

When you plan to plan for Windows Azure, you need to keep in mind. You can have multiple instances of your roles on the Internet / workers, that is, you must consider that the scheduled task can be performed several times, and this may not be the way you want.

You might consider creating a scheduling system using service bus queues. The BrokeredMessage class has an interesting ScheduledEnqueueTimeUtc property, which allows you to schedule when a message should be in the queue (available). This will fill the queue with messages that appear every hour, for example.

http://msdn.microsoft.com/en-us/library/microsoft.servicebus.messaging.brokeredmessage.scheduledenqueuetimeutc.aspx

And if you decide to build such an implementation using service bus queues, you can decide to process messages at most once (ReceiveAndDelete) or at least once (PeekLock).

+4
source

In case you use the ScheduledEnqueueTimeUtc property to delay message posting, I was wondering where the message is stored before being sent to the queue? Because if you have 2 instances of your Web / Worker role, what happens?

  • you create a message, and one of the instances stores it as a cache? Or is it like an instance that caches it?

Two scenarios: 1. - InstanceA exposes a message in its cache, waiting for it to be queued - InstanceA does not work for any reason. - The message is lost forever.

    • Both instances contain it.
    • Instances of A and B are included. The message is sent twice to the queue.

In both cases, it seems that the solution is not reliable.

0
source

All Articles