System.Threading.Channels 11.0.0-preview.7.26381.103
About
The System.Threading.Channels library provides types for passing data asynchronously between producers and consumers.
Key Features
- Abstractions representing channels for one or more producers to publish data to one or more consumers
- APIs focused on asynchronous production and consumption of data
- Factory methods for producing multiple kinds of channels
How to Use
using System;
using System.Threading.Channels;
using System.Threading.Tasks;
Channel<int> channel = Channel.CreateUnbounded<int>();
Task producer = Task.Run(async () =>
{
int i = 0;
while (true)
{
channel.Writer.TryWrite(i++);
await Task.Delay(TimeSpan.FromSeconds(1));
}
});
Task consumer = Task.Run(async () =>
{
await foreach (int value in channel.Reader.ReadAllAsync())
{
Console.WriteLine(value);
}
});
await Task.WhenAll(producer, consumer);
Main Types
The main types provided by this library are:
System.Threading.Channel<T>System.Threading.Channel
Additional Documentation
Related Packages
https://www.nuget.org/packages/System.Threading.Tasks.Dataflow/
Feedback & Contributing
System.Threading.Channels is released as open source under the MIT license. Bug reports and contributions are welcome at the GitHub repository.
Showing the top 20 packages that depend on System.Threading.Channels.
| Packages | Downloads |
|---|---|
|
protobuf-net.Grpc
Package Description
|
2,263 |
|
MassTransit
MassTransit provides a developer-focused, modern platform for creating distributed applications without complexity.
|
2,235 |
|
Microsoft.CodeAnalysis.Workspaces.Common
A shared package used by the .NET Compiler Platform ("Roslyn") including support for analyzing projects and solutions.
Do not install this package manually, it will be added as a prerequisite by other packages that require it.
More details at https://aka.ms/roslyn-packages
This package was built from the source at https://github.com/dotnet/roslyn/commit/6a5a63bbc9f4449d9bd1e95a8f9624939c3ccdc3.
|
1,262 |
|
Microsoft.CodeAnalysis.Workspaces.MSBuild
.NET Compiler Platform ("Roslyn") support for analyzing MSBuild projects and solutions. This should be used with at least one
of the following packages to add the appropriate language support:
- Microsoft.CodeAnalysis.CSharp.Workspaces
- Microsoft.CodeAnalysis.VisualBasic.Workspaces
More details at https://aka.ms/roslyn-packages
This package was built from the source at https://github.com/dotnet/roslyn/commit/6c4a46a31302167b425d5e0a31ea83c9a9aa1d09.
|
1,119 |
|
Serilog
Simple .NET logging with fully-structured events
|
1,104 |
|
Microsoft.CodeAnalysis.Workspaces.Common
A shared package used by the .NET Compiler Platform ("Roslyn") including support for analyzing projects and solutions.
Do not install this package manually, it will be added as a prerequisite by other packages that require it.
More details at https://aka.ms/roslyn-packages
This package was built from the source at https://github.com/dotnet/roslyn/commit/6c4a46a31302167b425d5e0a31ea83c9a9aa1d09.
|
1,101 |
|
Microsoft.CodeAnalysis.CSharp.Workspaces
.NET Compiler Platform ("Roslyn") support for analyzing C# projects and solutions.
More details at https://aka.ms/roslyn-packages
This package was built from the source at https://github.com/dotnet/roslyn/commit/6c4a46a31302167b425d5e0a31ea83c9a9aa1d09.
|
1,101 |
|
Serilog
Simple .NET logging with fully-structured events
|
1,097 |
|
Serilog
Simple .NET logging with fully-structured events
|
1,092 |
|
protobuf-net.Grpc
Package Description
|
1,049 |
|
Serilog
Simple .NET logging with fully-structured events
|
992 |
|
MassTransit
MassTransit provides a developer-focused, modern platform for creating distributed applications without complexity.
|
66 |
|
MassTransit
MassTransit provides a developer-focused, modern platform for creating distributed applications without complexity.
|
64 |
|
Akka
Canonical actor model implementation for .NET with local + distributed actors in C# and F#.
|
61 |
|
MassTransit
MassTransit provides a developer-focused, modern platform for creating distributed applications without complexity.
|
61 |
|
Npgsql
Npgsql is the open source .NET data provider for PostgreSQL.
|
61 |
|
StackExchange.Redis
High performance Redis client, incorporating both synchronous and asynchronous usage.
|
58 |
|
Microsoft.Data.SqlClient
The current data provider for SQL Server and Azure SQL databases. This has replaced System.Data.SqlClient. These classes provide access to SQL and encapsulate database-specific protocols, including tabular data stream (TDS).
Commonly Used Types:
Microsoft.Data.SqlClient.SqlConnection
Microsoft.Data.SqlClient.SqlException
Microsoft.Data.SqlClient.SqlParameter
Microsoft.Data.SqlClient.SqlDataReader
Microsoft.Data.SqlClient.SqlCommand
Microsoft.Data.SqlClient.SqlTransaction
Microsoft.Data.SqlClient.SqlParameterCollection
Microsoft.Data.SqlClient.SqlClientFactory
When using NuGet 3.x this package requires at least version 3.4.
|
56 |
|
MassTransit
MassTransit provides a developer-focused, modern platform for creating distributed applications without complexity.
|
56 |
|
Microsoft.CodeAnalysis.Features
.NET Compiler Platform ("Roslyn") support for creating editing experiences.
More details at https://aka.ms/roslyn-packages
This package was built from the source at https://github.com/dotnet/roslyn/commit/bde21ee2b98b775b010d01a93f81ef587fe80962.
|
55 |
.NET 10.0
- No dependencies.
.NET 11.0
- No dependencies.
.NET Framework 4.6.2
- Microsoft.Bcl.AsyncInterfaces (>= 11.0.0-preview.7.26381.103)
- System.Threading.Tasks.Extensions (>= 4.6.3)
.NET Standard 2.0
- Microsoft.Bcl.AsyncInterfaces (>= 11.0.0-preview.7.26381.103)
- System.Threading.Tasks.Extensions (>= 4.6.3)
.NET Standard 2.1
- No dependencies.