Nerdbank.MessagePack (1.2.4)

Published 2026-09-09 02:38:14 +03:30 by kayer

Installation

dotnet nuget add source --name kayer --username your_username --password your_token 
dotnet add package --source kayer --version 1.2.4 Nerdbank.MessagePack

About this package

A fast and more user-friendly MessagePack serialization library for .NET and .NET Framework. This package is brought to you by one of the two major contributors to MessagePack-CSharp. As its natural successor, this library comes packed with features that its predecessor lacks, and has ongoing support.

Premium support for trimming and Native AOT, secure deserialization of untrusted data, async serialization, streaming deserialization, skip serializing of default values, reference preservation, and support for reference cycles.

Also features an automatic structural equality API.

Nerdbank.MessagePack

A modern, fast and NativeAOT-compatible MessagePack serialization library

This is a fast and more user-friendly MessagePack serialization library for .NET and .NET Framework. This package is brought to you by one of the two major contributors to MessagePack-CSharp. As its natural successor, this library comes packed with features that its predecessor lacks, and has ongoing support.

Features

  • Serializes in the compact and fast MessagePack format.
  • Performance is on par with the highly tuned and popular MessagePack-CSharp library.
  • Automatically serialize any type annotated with the PolyType [GenerateShape] attribute or non-annotated types by adding a 'witness' type with a similar annotation.
  • Fast ref-based serialization and deserialization minimizes copying of large structs.
  • NativeAOT and trimming compatible.
  • Serialize only properties that have non-default values (optionally).
  • Keep memory pressure low by using async serialization directly to/from I/O like a network, IPC pipe or file.
  • Streaming deserialization for large or over-time sequences.
  • Primitive msgpack reader and writer APIs for low-level scenarios.
  • Author custom converters for advanced scenarios.
  • Security mitigations for stack overflows.
  • Optionally serialize your custom types as arrays of values instead of maps of names and value for more compact representation and even higher performance.
  • Support for serializing instances of certain types derived from the declared type and deserializing them back to their original runtime types using unions.
  • Optionally preserve reference equality across serialization/deserialization.
  • Structural (i.e. deep, by-value) equality checking for arbitrary types, both with and without collision resistant hash functions.

See how these features and more compare with the leading MessagePack library.

Dependencies

ID Version Target Framework
Microsoft.Bcl.HashCode 6.0.0 .NETFramework4.7.2
Microsoft.NET.StringTools 18.4.0 .NETFramework4.7.2
Microsoft.VisualStudio.Validation 17.13.22 .NETFramework4.7.2
PolyType 1.3.1 .NETFramework4.7.2
System.Collections.Immutable 8.0.0 .NETFramework4.7.2
System.IO.Pipelines 8.0.0 .NETFramework4.7.2
System.Text.Json 8.0.6 .NETFramework4.7.2
Microsoft.Bcl.HashCode 6.0.0 .NETStandard2.0
Microsoft.NET.StringTools 18.4.0 .NETStandard2.0
Microsoft.VisualStudio.Validation 17.13.22 .NETStandard2.0
PolyType 1.3.1 .NETStandard2.0
System.Collections.Immutable 8.0.0 .NETStandard2.0
System.IO.Pipelines 8.0.0 .NETStandard2.0
System.Text.Json 8.0.6 .NETStandard2.0
Microsoft.NET.StringTools 18.4.0 net8.0
Microsoft.VisualStudio.Validation 17.13.22 net8.0
PolyType 1.3.1 net8.0
System.IO.Pipelines 8.0.0 net8.0
Microsoft.NET.StringTools 18.4.0 net9.0
Microsoft.VisualStudio.Validation 17.13.22 net9.0
PolyType 1.3.1 net9.0
Details
NuGet
2026-09-09 02:38:14 +03:30
1
Andrew Arnott
1.4 MiB
Assets (2)
Versions (1) View all
1.2.4 2026-09-09