Repository navigation
v4.0.0-rc.1
Pre-release
Pre-release
·
160 commits
to master
since this release
This is the release candidate of v4.
v4 is a ground-up redesign: more than twice the performance, stronger security by default, full Native AOT support, and many new features, including support for C# 15 union types. It is feature-compatible and wire-compatible with v3, but contains breaking changes; see the v4 README and its "Migrating from v3" section before upgrading.
.NET 11 has been released, and this version is built with its release SDK. Unless something major comes up, the next release will be v4.0.0.
Please report any problems in the Issues.
Changes since preview.2
New
[MessagePackObject(EnumAsString = true)]writes the enums of a type by name.
Behavior changes
- Nullable annotations are enforced by default (
ValidateNullableAnnotations), on both serialization and deserialization. The SignalR hub protocol's default options leave it off. - A constructor parameter that the payload omits takes its declared default value.
- Typeless: a non-generic class derived from
Collection<T>,List<T>,Dictionary<K, V>and the like is written the way v3 wrote it, each element with its type name, and payloads written by v3 for such a class are readable again (#2321). - An
intkey above 65,535 is an error (MsgPack008), andMaxBufferedMessageSizemust be positive. - The reflection tier writes the same bytes as the source generator for a type that overrides a property in map mode.
- Analyzers: MsgPack101 / MsgPack108 report
CultureInfo,TimeZoneInfo,System.TypeandExpandoObject, which no default chain serves; MsgPack113 / MsgPack115 follow a container read into a helper method.
Dependencies
- SerializerFoundation 1.4.1 and NativeCompressions 1.3.2.
- The netstandard assets require Microsoft.Bcl.AsyncInterfaces and System.IO.Pipelines 8.0.0 instead of 10.0.0.