NonBlocking 1.1.2

.NET Standard 1.0
There is a newer version of this package available.
See the version list below for details.
dotnet add package NonBlocking --version 1.1.2
NuGet\Install-Package NonBlocking -Version 1.1.2
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="NonBlocking" Version="1.1.2" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add NonBlocking --version 1.1.2
#r "nuget: NonBlocking, 1.1.2"
#r directive can be used in F# Interactive, C# scripting and .NET Interactive. Copy this into the interactive tool or source code of the script to reference the package.
// Install NonBlocking as a Cake Addin
#addin nuget:?package=NonBlocking&version=1.1.2

// Install NonBlocking as a Cake Tool
#tool nuget:?package=NonBlocking&version=1.1.2

Implementation of a lock-free dictionary on .Net

     Included types:
     === NonBlocking.ConcurrentDictionary
     Lock-free, wait-free implementation of a dictionary.
     - has the same API as System.Collections.Concurrent.ConcurrentDictionary.
     - No locks are taken during any operation including Get, Add, Remove, internal resizes etc...
     - While multiple threads accessing NonBlocking dictionary will help each other in operations such as table resizing, there is no dependency on such behavior. If any thread get unscheduled or delayed for whatever reason, other threads will be able to make progress independently.
     - NonBlocking dictionary scales linearly with the number of active threads if hardware permits.

     On most operations NonBlocking dictionary is faster than Concurrent, especially in write-heavy scenarios.

     Core algorithms are based on NonBlockingHashMap, written and released to the public domain by Dr. Cliff Click. A good overview could be found here:

     === Counter32
     === Counter64
     Low-overhead scalable counters.

Product Versions
.NET net5.0 net5.0-windows net6.0 net6.0-android net6.0-ios net6.0-maccatalyst net6.0-macos net6.0-tvos net6.0-windows net7.0 net7.0-android net7.0-ios net7.0-maccatalyst net7.0-macos net7.0-tvos net7.0-windows
.NET Core netcoreapp1.0 netcoreapp1.1 netcoreapp2.0 netcoreapp2.1 netcoreapp2.2 netcoreapp3.0 netcoreapp3.1
.NET Standard netstandard1.0 netstandard1.1 netstandard1.2 netstandard1.3 netstandard1.4 netstandard1.5 netstandard1.6 netstandard2.0 netstandard2.1
.NET Framework net45 net451 net452 net46 net461 net462 net463 net47 net471 net472 net48
MonoAndroid monoandroid
MonoMac monomac
MonoTouch monotouch
Tizen tizen30 tizen40 tizen60
Universal Windows Platform uap uap10.0
Windows Phone wp8 wp81 wpa81
Windows Store netcore netcore45 netcore451
Xamarin.iOS xamarinios
Xamarin.Mac xamarinmac
Xamarin.TVOS xamarintvos
Xamarin.WatchOS xamarinwatchos
Compatible target framework(s)
Additional computed target framework(s)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (5)

Showing the top 5 NuGet packages that depend on NonBlocking:

Package Downloads

An auto-mocking container that generates mocks using Moq


FunFair Common Test Infrastructure for building xUnit tests on top of.


The fastest cache library written in C# for items with set expiration time. Easy to use, thread-safe and light on memory. Optimized to scale from dozens to millions of items. Features lock-free reads and writes, allocation-free reads and automatic eviction. Credit to Vladimir Sadov for his implementation of NonBlocking.ConcurrentDictionary which is used as an underlying store.


Aggregator for multidimensional hierarchies


Scriptable update package tool

GitHub repositories (1)

Showing the top 1 popular GitHub repositories that depend on NonBlocking:

Repository Stars
An auto-mocking IoC container for Moq
Version Downloads Last updated
2.1.0 11,543 6/24/2022
2.0.0 10,673 3/17/2022
1.1.2 24,629 5/21/2020
1.1.1 3,840 5/14/2020
1.1.0 521 5/7/2020
1.0.3 13,969 2/13/2019
1.0.2 365,943 1/20/2018
1.0.0 1,128 7/20/2017
1.0.0-rc7 798 7/14/2017
1.0.0-rc6 1,103 5/19/2017
1.0.0-rc5 976 5/19/2017
1.0.0-rc4 1,072 5/10/2017

Some performance improvements.