Releases: ch-robinson/dotnet-avro
4.1.0
This minor release improves surrogate schema selection when building record deserializers:
- Enum schema surrogates are now selected correctly regardless of whether the enum appears in an array, map, or union. Additionally, this behavior can now be customized via the new
CreateSurrogateSchema
method on the record deserializer builder case.
4.0.2
3.3.0
This minor release improves surrogate schema selection when building record deserializers:
- Enum schema surrogates are now selected correctly regardless of whether the enum appears in an array, map, or union. Additionally, this behavior can now be customized via the new
CreateSurrogateSchema
method on the record deserializer builder case.
3.2.1
2.1.0
This minor release improves surrogate schema selection when building record deserializers:
- Enum schema surrogates are now selected correctly regardless of whether the enum appears in an array, map, or union. Additionally, this behavior can now be customized via the new
CreateSurrogateSchema
method on the record deserializer builder case.
2.0.6
4.0.1
This patch release mitigates a .NET Framework-specific issue:
- All async calls in Chr.Avro.Confluent are now made with
ConfigureAwait(continueOnCapturedContext: false)
. In previous releases, use of consumer/producer builder extension methods may have contributed to deadlocks in certain contexts.
4.0.0
This major release brings significant performance improvements and simplifies some of the code used to build serializers and deserializers. Most applications should be able to upgrade from 3.x versions without making any additional changes.
Breaking changes
-
The
BinaryDeserializer<T>
andBinarySerializer<T>
classes have been removed from the public API (#58). -
Case interfaces no longer rely on exceptions to control flow (#53). That (regrettable) change, introduced in 3.0.0, made debugging intolerably slow (#41) and has now been reversed.
-
The codec interfaces and the case interfaces used by the serde builders have been altered to support more efficient expression generation (#58). The binary serde builder interfaces have also changed slightly—
BuildDelegate
methods no longer include the optionalcache
parameter.
Bug fixes
- Prior to 4.0.0, some CLI validation errors caused unhandled exceptions. With this release, all validation errors should be handled consistently.
New features
-
Chr.Avro now supports serializing and deserializing
ArraySegment<T>
as well as all generic collection types inSystem.Collections.Generic
andSystem.Collections.Immutable
(#59, h/t @kingwill27; #64). See the mapping documentation for more details. -
dotnet avro generate
now supports reading schemas from standard input (#62). The documentation includes Bash and PowerShell examples.
3.2.0
This minor release improves support for "array"
and "record"
type mapping.
New features
-
An
"array"
value can now be deserialized to any type with a constructor that has a singleIEnumerable<T>
parameter (#42). This opens up compatibility with collection types likeHashSet<T>
. -
Similarly, a
"record"
value can now be deserialized to any type with a constructor that has matching parameters for each record field (#38).
3.1.0
This minor release adds some new features to improve schema generation and support advanced use cases.
New features
-
The
dotnet avro create
command now includes the--temporal-behavior
flag, which can be used to specify how schemas are created forDateTime
andDateTimeOffset
:$ dotnet avro create --type System.DateTime "string" $ dotnet avro create --type System.DateTime --temporal-behavior epochmilliseconds {"type":"long","logicalType":"timestamp-millis"}
Under the hood, this maps to the new
temporalBehavior
parameter on theSchemaBuilder
(#39, h/t @promontis). -
The union deserializer and serializer builder cases can now be extended to support polymorphic mapping and similar use cases (#43). Check out this new guide page for details.