In .NET, I'd like to schedule a large number of Tasks, e.g. via Task.Run(...). Some of the tasks are of low importance and should be delayed by the scheduler if higher priority tasks are available for execution.
Is there a way to do this? There seems to be no TaskScheduler in .NET that supports scheduling with any kind of priority.
The tasks are short-running and non-hierarchical. To be clear, this is entirely unrelated to the priority of the thread executing the tasks.
QueuedTaskScheduler from ParallelExtensionsExtras seems to be what I am looking for, but that has been without maintenance for seven years, lacks documentation and most of the links related to it are broken - I'd rather not add a dependence on it.