Helios.DedicatedThreadPool
0.1.0
See the version list below for details.
dotnet add package Helios.DedicatedThreadPool --version 0.1.0
NuGet\Install-Package Helios.DedicatedThreadPool -Version 0.1.0
<PackageReference Include="Helios.DedicatedThreadPool" Version="0.1.0" />
paket add Helios.DedicatedThreadPool --version 0.1.0
#r "nuget: Helios.DedicatedThreadPool, 0.1.0"
// Install Helios.DedicatedThreadPool as a Cake Addin
#addin nuget:?package=Helios.DedicatedThreadPool&version=0.1.0
// Install Helios.DedicatedThreadPool as a Cake Tool
#tool nuget:?package=Helios.DedicatedThreadPool&version=0.1.0
An instanced, dedicated ThreadPool for eliminating "noisy neighbor" problems on the CLR ThreadPool
Learn more about Target Frameworks and .NET Standard.
This package has no dependencies.
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Initial build of `DedicatedThreadPool`. Works via the following API:
```csharp
using (var threadPool = new Helios.Concurrency.DedicatedThreadPool(
new DedicatedThreadPoolSettings(numThreads)))
{
threadPool.QueueUserWorkItem(() => { ... }));
}
```
Creates a `DedicatedThreadPool` object which allocates a fixed number of threads, each with their own independent task queue.
This `DedicatedThreadPool` can also be used in combination with a `DedicatedThreadPoolTaskScheduler` for TPL support, like this:
```csharp
//use 3 threads
var Pool = new DedicatedThreadPool(new DedicatedThreadPoolSettings(3));
var Scheduler = new DedicatedThreadPoolTaskScheduler(Pool);
var Factory = new TaskFactory(Scheduler);
var task = Factory.StartNew(() =>
{
//work that'll run on the dedicated thread pool...
});
task.Wait();
```