Stop multiple tasks with a timer or a kill function and limit number of parallel tasks
Hi João,
I kindly ask you to implement a feature to stop looping tasks or tasks running indefinitely long to stop after a specific period. (Just the other day I had a task running for more than two thousand seconds, although it usually just takes seconds.
In addition, I would like to ask you to limit the number of parallel tasks to a given number. I need more than one or two tasks but only a few of the same tasks running at the same time. For the time being, I can only say to stop the current or the new task or to have them run together. I would like to set a maximum number.
(I have tried to increase a global variable with each run and subtract one from it, when the task finishes. I have an if-clause implemented, which stops all the same running tasks, but I don't know, if this works as I would like to have it.)
Thank you for your great work.
Cheers,
A. (patron)