Bnaya.CSharp.AsyncExtensions 1.0.68

dotnet add package Bnaya.CSharp.AsyncExtensions --version 1.0.68                
NuGet\Install-Package Bnaya.CSharp.AsyncExtensions -Version 1.0.68                
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="Bnaya.CSharp.AsyncExtensions" Version="1.0.68" />                
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Bnaya.CSharp.AsyncExtensions --version 1.0.68                
#r "nuget: Bnaya.CSharp.AsyncExtensions, 1.0.68"                
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install Bnaya.CSharp.AsyncExtensions as a Cake Addin
#addin nuget:?package=Bnaya.CSharp.AsyncExtensions&version=1.0.68

// Install Bnaya.CSharp.AsyncExtensions as a Cake Tool
#tool nuget:?package=Bnaya.CSharp.AsyncExtensions&version=1.0.68                

Bnaya.CSharp.AsyncExtensions NuGet Prepare Deploy

codecov

Contribution of useful async pattern, API, Extensions, etc.

NuGet

this library available on NuGet via Install-Package Bnaya.CSharp.AsyncExtensions

This library have the following godies:

  • Exception Handlinfg
    • ThrowAll (produce AggregateException when waiting on Task.WhenAll)
    • Format (format async exception into friendlier callstack represantation)
  • Timeout (will apply timeout semantic for any Task)
    • WithTimeout (will throw on timeout)
    • IsTimeoutAsync (will return indication without throwing, ideal for SLA checks [prctice: check and produce warning])
  • Cancellation
    • CancelSafe (will run the CancellationTokenSource.Cancel within try catch and prevent unexpected side effect which can happen when cancellation token registration throw)
    • RegisterWeak (use week registration to cancellation token, letting the GC to collect the instance of the registration even when the token is still alive, can reduce potential for memory leaks)
  • Frendly async locking facilities (which can replace the clasical lock statement).
    • Extensions
      • TryAcquireAsync
      • AcquireAsync
    • Instance-able
      • AsyncLock
Product Compatible and additional computed target framework versions.
.NET net7.0 is compatible.  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. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (4)

Showing the top 4 NuGet packages that depend on Bnaya.CSharp.AsyncExtensions:

Package Downloads
Weknow.EventSource.Backbone.Contracts

Package Description

Weknow.EventSource.Backbone

Package Description

Weknow.GraphDbClient.Abstraction

Package Description

EventSourcing.Backbone.Abstractions

Package Description

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
1.0.68 5,950 6/19/2023
1.0.67 5,751 5/23/2023
1.0.66 760 5/18/2023
1.0.65 680 5/18/2023
1.0.64 7,461 2/16/2023
1.0.62 1,605 2/2/2023
1.0.60 7,648 12/6/2022
1.0.58 838 12/6/2022
1.0.56 4,085 11/15/2022
1.0.54 40,376 4/12/2022
1.0.52 967 4/12/2022
1.0.51 993 4/12/2022
1.0.49 52,718 12/30/2021
1.0.28 84,781 7/24/2020
1.0.27 1,304 6/12/2020
1.0.25 2,085 8/17/2018
1.0.23 1,828 5/2/2018
1.0.22 1,621 5/2/2018
1.0.21 1,540 4/17/2018
1.0.20 1,614 4/16/2018
1.0.19 1,582 4/15/2018
1.0.18 1,684 4/14/2018
1.0.15 1,654 12/21/2017
1.0.14 1,646 12/21/2017
1.0.13 1,640 11/23/2017
1.0.11 1,809 11/21/2017
1.0.7 1,829 11/16/2017

Release 1.0.27 (Breaking Changes)
Remove obsolete api of exception formatting.

Add FormatLazy which is better citizen for modern logger scenarios.
It will do the formatting on the ToString time i.e won't format logs which was filtered out.

example:
logger.LogError(ex.FormatLazy(), "Fault execution");