DistributedLock 2.5.1
See the version list below for details.
dotnet add package DistributedLock --version 2.5.1
NuGet\Install-Package DistributedLock -Version 2.5.1
<PackageReference Include="DistributedLock" Version="2.5.1" />
<PackageVersion Include="DistributedLock" Version="2.5.1" />
<PackageReference Include="DistributedLock" />
paket add DistributedLock --version 2.5.1
#r "nuget: DistributedLock, 2.5.1"
#:package DistributedLock@2.5.1
#addin nuget:?package=DistributedLock&version=2.5.1
#tool nuget:?package=DistributedLock&version=2.5.1
DistributedLock is a .NET library that provides robust and easy-to-use distributed mutexes, reader-writer locks, and semaphores based on a variety of underlying technologies.
With DistributedLock, synchronizing access to a region of code across multiple applications/machines is as simple as:
await using (await myDistributedLock.AcquireAsync())
{
	// I hold the lock here
}
Read the documentation here.
| Product | Versions Compatible and additional computed target framework versions. | 
|---|---|
| .NET | net5.0 was computed. net5.0-windows was computed. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. | 
| .NET Core | netcoreapp2.0 was computed. netcoreapp2.1 was computed. netcoreapp2.2 was computed. netcoreapp3.0 was computed. netcoreapp3.1 was computed. | 
| .NET Standard | netstandard2.0 is compatible. netstandard2.1 is compatible. | 
| .NET Framework | net461 was computed. net462 is compatible. net463 was computed. net47 was computed. net471 was computed. net472 is compatible. net48 was computed. net481 was computed. | 
| MonoAndroid | monoandroid was computed. | 
| MonoMac | monomac was computed. | 
| MonoTouch | monotouch was computed. | 
| Tizen | tizen40 was computed. tizen60 was computed. | 
| Xamarin.iOS | xamarinios was computed. | 
| Xamarin.Mac | xamarinmac was computed. | 
| Xamarin.TVOS | xamarintvos was computed. | 
| Xamarin.WatchOS | xamarinwatchos was computed. | 
- 
                                                    .NETFramework 4.6.2- Azure.Storage.Blobs (>= 12.19.1)
- DistributedLock.Azure (>= 1.0.2)
- DistributedLock.FileSystem (>= 1.0.3)
- DistributedLock.MySql (>= 1.0.2)
- DistributedLock.Postgres (>= 1.2.1)
- DistributedLock.Redis (>= 1.0.3)
- DistributedLock.SqlServer (>= 1.0.6)
- DistributedLock.WaitHandles (>= 1.0.1)
- DistributedLock.ZooKeeper (>= 1.0.0)
- Microsoft.Bcl.AsyncInterfaces (>= 8.0.0)
- Microsoft.Data.SqlClient (>= 5.2.2)
- MySqlConnector (>= 2.3.5)
- Npgsql (>= 8.0.6)
- StackExchange.Redis (>= 2.7.27)
- System.ValueTuple (>= 4.5.0)
- ZooKeeperNetEx (>= 3.4.12.4)
 
- 
                                                    .NETFramework 4.7.2- Azure.Storage.Blobs (>= 12.19.1)
- DistributedLock.Azure (>= 1.0.2)
- DistributedLock.FileSystem (>= 1.0.3)
- DistributedLock.MySql (>= 1.0.2)
- DistributedLock.Oracle (>= 1.0.4)
- DistributedLock.Postgres (>= 1.2.1)
- DistributedLock.Redis (>= 1.0.3)
- DistributedLock.SqlServer (>= 1.0.6)
- DistributedLock.WaitHandles (>= 1.0.1)
- DistributedLock.ZooKeeper (>= 1.0.0)
- Microsoft.Data.SqlClient (>= 5.2.2)
- MySqlConnector (>= 2.3.5)
- Npgsql (>= 8.0.6)
- Oracle.ManagedDataAccess (>= 23.6.1)
- StackExchange.Redis (>= 2.7.27)
- ZooKeeperNetEx (>= 3.4.12.4)
 
- 
                                                    .NETStandard 2.0- Azure.Storage.Blobs (>= 12.19.1)
- DistributedLock.Azure (>= 1.0.2)
- DistributedLock.FileSystem (>= 1.0.3)
- DistributedLock.MySql (>= 1.0.2)
- DistributedLock.Postgres (>= 1.2.1)
- DistributedLock.Redis (>= 1.0.3)
- DistributedLock.SqlServer (>= 1.0.6)
- DistributedLock.WaitHandles (>= 1.0.1)
- DistributedLock.ZooKeeper (>= 1.0.0)
- Microsoft.Bcl.AsyncInterfaces (>= 8.0.0)
- Microsoft.Data.SqlClient (>= 5.2.2)
- MySqlConnector (>= 2.3.5)
- Npgsql (>= 8.0.6)
- StackExchange.Redis (>= 2.7.27)
- System.Threading.AccessControl (>= 8.0.0)
- ZooKeeperNetEx (>= 3.4.12.4)
 
- 
                                                    .NETStandard 2.1- Azure.Storage.Blobs (>= 12.19.1)
- DistributedLock.Azure (>= 1.0.2)
- DistributedLock.FileSystem (>= 1.0.3)
- DistributedLock.MySql (>= 1.0.2)
- DistributedLock.Oracle (>= 1.0.4)
- DistributedLock.Postgres (>= 1.2.1)
- DistributedLock.Redis (>= 1.0.3)
- DistributedLock.SqlServer (>= 1.0.6)
- DistributedLock.WaitHandles (>= 1.0.1)
- DistributedLock.ZooKeeper (>= 1.0.0)
- Microsoft.Data.SqlClient (>= 5.2.2)
- MySqlConnector (>= 2.3.5)
- Npgsql (>= 8.0.6)
- Oracle.ManagedDataAccess.Core (>= 23.6.1)
- StackExchange.Redis (>= 2.7.27)
- System.Threading.AccessControl (>= 8.0.0)
- ZooKeeperNetEx (>= 3.4.12.4)
 
NuGet packages (13)
Showing the top 5 NuGet packages that depend on DistributedLock:
| Package | Downloads | 
|---|---|
| Silky.Rpc Providing RPC communication service for Silky framework | |
| Silky.Transaction Encapsulating the basic package of Silky distributed transaction | |
| Net.RunMethodsSequentially Runs updates to single resources, e.g. a database, on startup of an application that has multiple instances | |
| Else.TheSaga.Locking.DistributedLock A module that allows you use distributed locking (using sql server, thanks to DistributedLock library) --------------------- .net core Saga / ProcessManager implementation https://github.com/b-y-t-e/TheSaga | |
| Silky.Lock Silky DistributedLock | 
GitHub repositories (3)
Showing the top 3 popular GitHub repositories that depend on DistributedLock:
| Repository | Stars | 
|---|---|
| elsa-workflows/elsa-core 
                                                            A .NET workflows library
                                                         | |
| JonPSmith/AuthPermissions.AspNetCore 
                                                            This library provides extra authorization and multi-tenant features to an ASP.NET Core application.
                                                         | |
| liuhll/silky 
                                                            The Silky framework is designed to help developers quickly build a microservice development framework through simple code and configuration under the .net platform.
                                                         | 
| Version | Downloads | Last Updated | 
|---|---|---|
| 2.7.1 | 2,550 | 10/26/2025 | 
| 2.7.0 | 86,819 | 8/10/2025 | 
| 2.6.0 | 288,392 | 1/28/2025 | 
| 2.5.1 | 74,328 | 12/7/2024 | 
| 2.5.0 | 274,500 | 6/30/2024 | 
| 2.4.0 | 152,516 | 3/26/2024 | 
| 2.3.4 | 404,673 | 11/28/2023 | 
| 2.3.3 | 252,922 | 7/17/2023 | 
| 2.3.2 | 419,291 | 11/13/2022 | 
| 2.3.1 | 297,956 | 7/9/2022 | 
| 2.3.0 | 269,613 | 12/17/2021 | 
| 2.2.0 | 97,642 | 10/2/2021 | 
| 2.1.0 | 176,326 | 6/18/2021 | 
| 2.0.2 | 74,166 | 4/24/2021 | 
| 2.0.1 | 56,100 | 2/25/2021 | 
| 2.0.0 | 52,610 | 1/14/2021 | 
| 2.0.0-alpha02 | 483 | 12/23/2020 | 
| 2.0.0-alpha01 | 554 | 8/28/2020 | 
| 1.5.0 | 4,169,847 | 1/29/2020 | 
| 1.5.0-beta01 | 732 | 1/28/2020 | 
| 1.4.0 | 754,774 | 2/8/2018 | 
| 1.3.1 | 211,657 | 4/17/2017 | 
| 1.3.0 | 4,747 | 3/12/2017 | 
| 1.2.0 | 98,860 | 2/4/2017 | 
| 1.1.0 | 41,866 | 7/15/2015 | 
| 1.0.1 | 3,795 | 6/6/2015 | 
| 1.0.0 | 16,291 | 6/6/2015 |