184 packages tagged with “await”
A helper library for the Task-Based Asynchronous Pattern (TAP).
This package enables Visual Studio 2012 projects to use the new 'async' and 'await' keywords. This package also includes Task-based extension methods that allow using some of the existing asynchronous APIs with the new language keywords. Windows Phone Silverlight 8 projects can use this package to get access to async extension methods for the networking types. This package is not supported in Visual Studio 2010, and is only required for projects targeting .NET Framework 4.5, Windows 8, Windows Phone Silverlight 8, or Windows Phone 8.1 when consuming a library that uses this package. For known issues, please see: http://blogs.msdn.com/b/bclteam/p/asynctargetingpackkb.aspx. For more information on the async programming model, visit MSDN: http://msdn.microsoft.com/en-us/library/vstudio/hh191443.aspx. Supported Platforms: - .NET Framework 4 (with KB2468871) - Windows 8 - Windows Phone 8.1 - Windows Phone Silverlight 7.5 - Silverlight 4 - Portable Class Libraries
When using dependency injection and async-await pattern it is possible to end up with an interface with a method that returns a Task. If this interface method is used in a synchronous method there is a likelihood that it will erroneously be run as a fire and forget method. In this situation this analyser generates a warning.
Introduces IAsyncEnumerable, IAsyncEnumerator, ForEachAsync(), and ParallelForEachAsync() GitHub: https://github.com/Dasync/AsyncEnumerable PROBLEM SPACE Helps to (a) create an element provider, where producing an element can take a lot of time due to dependency on other asynchronous events (e.g. wait handles, network streams), and (b) a consumer that processes those element as soon as they are ready without blocking the thread (the processing is scheduled on a worker thread instead). EXAMPLE using Dasync.Collections; static IAsyncEnumerable<int> ProduceAsyncNumbers(int start, int end) { return new AsyncEnumerable<int>(async yield => { // Just to show that ReturnAsync can be used multiple times await yield.ReturnAsync(start); for (int number = start + 1; number <= end; number++) await yield.ReturnAsync(number); // You can break the enumeration loop with the following call: yield.Break(); // This won't be executed due to the loop break above await yield.ReturnAsync(12345); }); } // Just to compare with synchronous version of enumerator static IEnumerable<int> ProduceNumbers(int start, int end) { yield return start; for (int number = start + 1; number <= end; number++) yield return number; yield break; yield return 12345; } static async Task ConsumeNumbersAsync() { var asyncEnumerableCollection = ProduceAsyncNumbers(start: 1, end: 10); await asyncEnumerableCollection.ForEachAsync(async number => { await Console.Out.WriteLineAsync($"{number}"); }); } // Just to compare with synchronous version of enumeration static void ConsumeNumbers() { var enumerableCollection = ProduceNumbers(start: 1, end: 10); foreach (var number in enumerableCollection) { Console.Out.WriteLine($"{number}"); } }
A C# lock replacement for async/await, supporting recursion/re-entrance and asynchronous waits. Handles async recursion correctly - note that Nito.AsyncEx does not!
AsyncFixer detects common async/await anti-patterns and, when possible, offers automatic fixes. It currently reports 6 categories of async/await misuse and provides code fixes for 3 of them. It has been validated against thousands of open-source C# projects and is designed to handle tricky real-world edge cases. Tool-friendly diagnostics support AI-assisted workflows even when a built-in code fix is not available.
Checks for `ConfigureAwait(false)` usage. More info: * https://www.tabsoverspaces.com/id/233852 * https://www.tabsoverspaces.com/id/233732 * https://www.tabsoverspaces.com/id/233523 * https://www.tabsoverspaces.com/id/233476
Async-friendly format for stack traces and exceptions (not needed in .NET 6+)
Extensions for System.Threading.Tasks Includes extension methods to safely fire-and-forget a Task and/or a ValueTask Includes WeakEventManger which avoids memory leaks when events are not unsubscribed
The Execution Context Scoping package adds the 'Execution Context Scope' lifestyle, which allows instances to live within an explicitly defined execution context scope (or logical call context) and get disposed when this scope ends. This scope allows flowing through asynchronous method calls.
Asyncify-CSharp is an analyzer and codefix that allows you to quickly update your code to use the Task Asynchronous Programming model. This model, introduced in C# 5, adds an intuitive way of handling asynchronous calls within C#. The analyzer allows large codebases to be easily modified to use the TAP model by finding violations and applying fixes up the call tree.
Enable using the new Value Tuple structure to write elegant code that allows async methods to be fired in parallel despite having different return types var (result1, result2) = await (GetStringAsync(), GetGuidAsync()); Based on the work of Joseph Musser https://github.com/jnm2
A set of async versions of common concurrency primitives.
Binaries for the AsyncBridge library. Visit https://github.com/tejacques/AsyncBridge for an overview and usage examples.
Free yourself from async void! TaskMonitor is a task wrapper component helping you to deal with "fire and forget" Task (non awaited task) by implementing async/await best practices. Featuring: * Safe execution of your non awaited tasks * Delegates for all states of the loaded task * Builder pattern for more elegant construction and deferred execution * Support for task with result * Default handling of errors and statistics * Global configuration for statistics and errors handler * Consider globally or locally the cancel state as faulted to simplify your workflow
The core module for a simple SSL or non-SSL async await Tcp Server and Client with authentication. This package is used by both Tcp.NET.Client and Tcp.NET.Server.
An implementation of an actor designed to integrate with C#'s async/await.
A lightweight HTTP compliant web server written in C# with full async/await implementation
Async Extensions for ICommand Includes AsyncCommand and IAsyncCommand which allows ICommand to safely be used asynchronously with Task. Includes AsyncValueCommand and IAsyncValueCommand which allows ICommand to safely be used asynchronously with ValueTask
C# LINQ Async extension methods library for async/await task.
Additional stylecop rules for the async / await c# features.
The server module for a simple SSL or non-SSL Tcp Server with authentication.
Useful extensions contribution by Bnaya Eshet Blog: http://blogs.microsoft.co.il/bnaya/ Source Code: https://github.com/bnayae/Bnaya.CSharp.AsyncExtensions # NuGet this library available on NuGet via Install-Package Bnaya.CSharp.AsyncExtensions ## This library have the following goodies: * Exception Handling * ThrowAll (produce AggregateException when waiting on Task.WhenAll) * Format (format async exception into friendlier call-stack representation) * Timeout (will apply timeout semantic for any Task) * WithTimeout (will throw on timeout) * IsTimeoutAsync (will return indication without throwing, ideal for SLA checks [practice: 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) * Friendly async locking facilities (which can replace the classical lock statement). * Extensions * TryAcquireAsync * AcquireAsync * Instance-able * AsyncLock * WhenN: use to complete task after n task succeed THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
The client module for a simple SSL or non-SSL Tcp Client with authentication.
Gear for making components.
Stop copying and pasting code in order to support Async/Await! Shaolinq.AsyncRewriter generates async methods from your sync methods using Roslyn. AsyncRewriter is used extensively by the Shaolinq ORM/LINQ project.
Miminum set of the async/await portability libarary.
Deprecated. Use the unified package AsyncBridge instead.
The server and client modules for a simple SSL or non-SSL Tcp Server with authentication.