I am developing a .NET core application with the Azure Batch SDK. When it comes to creating the tasks I am wondering how many threads my task should consist of.
First I started to evaluate the number of CPU cores of the underlying node and spawn that amount of threads.
Later then, I realized it might be better to let the Azure Batch Scheduler do that work for me, tweak the pools requiredSlots
and taskSlotsPerNode
settings instead and only create single-threaded worker tasks.
Unfortunately, I couldn't find any advice in the documentation on the Azure Batch task to thread (TPL task) ratio.
Any advice on this?