2017 Job Queue: What Starts It?

OldNavDogOldNavDog Member Posts: 88
In the 2017 Task-Scheduler-Based Job Queue model, there doesn't appear to be anything that "Kicks-off" the Queue. Everything seems to depend on the INSERT of a Job Queue Entry.

Am I missing something? It seems kind of a "non-robust" setup for Recurring tasks, in that, if something happens and a Recurring Job Queue Entry doesn't get rescheduled, it is just DONE, and there is not a simple way to "Restart the Queue".

Again, I feel I must be missing something...
Experience is what you get, when you don't get what you want. --Anon.

Answers

  • nick_robbonick_robbo Member Posts: 49
    Hi, If you "Restart" the Job Queue Entry which relates to the Scheduled Task, it Reschedules the task. (IE removes the Scheduled Task, and inserts a new one. The code in "Restart" just calls SetStatus to On Hold, then Ready. Hope this helps.
  • OldNavDogOldNavDog Member Posts: 88
    Yes, I know that; but overall, there doesn't appear to be a "GetNextRequest" Main Loop that Job Queue USED to Run. It seems all too much like one of those "tower" games, where you build taller and taller piles of blocks or sticks until the whole thing collapses, because there's no "glue" holding everything together.

    GetNextRequest was that "Glue" for Job Queue. Now its gone.
    Experience is what you get, when you don't get what you want. --Anon.
  • MarkusWeilandMarkusWeiland Member Posts: 11
    Do you have a look at COD453? The EnqueueJobQueueEntry function creates the job with the new Taskscheduler datatype after all. Taskscheduler has also an Error Codeunit (COD450) which handles an error during the job. maybe that helps.
  • Ettu_BruteEttu_Brute Member Posts: 8
    If you start a service tier with "Enable Task Scheduler" option ticked you have have in fact started the job queue. The old job queue no longer exists, has been replaced by this Task Scheduler which is always running (as long as the service tier is running and the Enable Task Scheduler is ticked).
  • nick_robbonick_robbo Member Posts: 49
    There is no "GetNextRequest" loop which you can interrogate. Microsoft is handling this somehow behind the scenes. Apparently I have heard it works in a similar way to Windows Scheduled Tasks.
Sign In or Register to comment.