Serilog.Sinks.FastConsole 2.2.0

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

// Install Serilog.Sinks.FastConsole as a Cake Tool
#tool nuget:?package=Serilog.Sinks.FastConsole&version=2.2.0


Serilog sink that writes to console with high-performance non-blocking output. Supports plaintext and JSON output but does not support themes and colors.

This sink uses a background channel with a single text buffer and async writes to remove all blocking and lock contention to the console output stream. It also implements IDiposable so that calling Log.CloseAndFlush() will ensure all lines are flushed. Recommended for high-volume logging where console logging is captured and sent elsewhere, for example this library was originally created for a large fleet of API servers running in Kubernetes and logging hundreds of large JSON objects every second.

  • Built for net6.0, net5.0, netstandard2.1, netstandard2.0
  • Release notes here:

Getting started

Install package from Nuget:
dotnet add package Serilog.Sinks.FastConsole
Configure Logger (using code):
var config = new FastConsoleSinkOptions { UseJson = true };
Log.Logger = new LoggerConfiguration().WriteTo.FastConsole(config).CreateLogger();

Sink Options

Name Default Description
UseJson true Enable to write log events as a JSON object with { timestamp, level, message, properties } structure. Provide an ITextFormatter implementation instead to customize the output completely.
QueueLimit null Set max limit for the number of log entries queued in memory. Used to provide backpressure and avoid out-of-memory issues for high-volume logging.
BlockWhenFull false Sets the behavior of sink when queue of messages is full. Set to true to block instead of losing log entries. Requires QueueLimit to be set.
Product Versions
.NET net5.0 net5.0-windows net6.0 net6.0-android net6.0-ios net6.0-maccatalyst net6.0-macos net6.0-tvos net6.0-windows net7.0 net7.0-android net7.0-ios net7.0-maccatalyst net7.0-macos net7.0-tvos net7.0-windows
.NET Core netcoreapp2.0 netcoreapp2.1 netcoreapp2.2 netcoreapp3.0 netcoreapp3.1
.NET Standard netstandard2.0 netstandard2.1
.NET Framework net461 net462 net463 net47 net471 net472 net48
MonoAndroid monoandroid
MonoMac monomac
MonoTouch monotouch
Tizen tizen40 tizen60
Xamarin.iOS xamarinios
Xamarin.Mac xamarinmac
Xamarin.TVOS xamarintvos
Xamarin.WatchOS xamarinwatchos
Compatible target framework(s)
Additional computed target framework(s)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
2.2.0 4,363 10/17/2022
2.1.0 31,238 6/12/2022
2.0.0 14,104 3/9/2022
1.6.0 618 2/20/2022
1.5.0 98,628 6/27/2021
1.4.1 8,337 4/25/2021
1.4.0 318 4/25/2021
1.3.2 86,652 6/9/2020
1.3.1 7,756 10/7/2019
1.3.0 983 7/18/2019
1.2.0 385 7/18/2019
1.1.0 379 7/18/2019
1.0.0 391 7/18/2019