Releases: neosmart/AsyncLock
AsyncLock 3.2.1
This point release adds strong name signing and bundles the README as part of the nuget package, making it viewable on nuget.org
Download on Nuget.org: https://www.nuget.org/packages/NeoSmart.AsyncLock/
Or install manually:
Install-Package NeoSmart.AsyncLock -Version 3.2.1
NeoSmart.AsyncLock 3.2.0
This update brings a highly requested feature: the ability to to atomically attempt to obtain a lock or return early otherwise. The new interface is available as .TryLock()
and .TryLockAsync()
for both synchronous and asynchronous usage. The API is resistant to misuse by executing the critical path in a closure w/ the lock obtained, so there's no need to worry about sometimes disposing the returned lock and sometimes not.
A pull request from first-time contributor Caleb Frederickson (@Stroniax) adds the ability to use a CancellationToken
to time out synchronous requests (previously a CancellationToken
parameter was only accepted for the asynchronous locking methods).
The updated package has been published to NuGet as NeoSmart.AsyncLock
and may be installed as with any other package; for Visual Studio users that would look like this:
Install-Package NeoSmart.AsyncLock -Version 3.2.0