Skip to content

Releases: ch-robinson/dotnet-avro

3.3.0

21 Feb 21:00
Compare
Choose a tag to compare

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

21 Feb 19:14
Compare
Choose a tag to compare

This patch release fixes a deserialization bug:

  • When attempting to map a record schema with an enum field to a type without a match, Chr.Avro would fail to build a deserializer.

2.1.0

21 Feb 20:59
Compare
Choose a tag to compare

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

21 Feb 19:13
Compare
Choose a tag to compare

This patch release fixes a deserialization bug:

  • When attempting to map a record schema with an enum field to a type without a match, Chr.Avro would fail to build a deserializer.

4.0.1

18 Feb 17:50
Compare
Choose a tag to compare

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

21 Jan 21:03
Compare
Choose a tag to compare

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> and BinarySerializer<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 optional cache 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 in System.Collections.Generic and System.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

16 Dec 21:02
Compare
Choose a tag to compare

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 single IEnumerable<T> parameter (#42). This opens up compatibility with collection types like HashSet<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

29 Oct 14:51
Compare
Choose a tag to compare

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 for DateTime and DateTimeOffset:

    $ 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 the SchemaBuilder (#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.

3.0.0

18 Oct 18:31
Compare
Choose a tag to compare

This major release improves Chr.Avro’s extensibility, drops .NET Framework targets, and fixes some bugs. Most applications should be able to upgrade from 2.x versions without making any additional changes.

Breaking changes

  • Chr.Avro no longer targets .NET Framework 4.5.2. All class libraries exclusively target .NET Standard 2.0. (Framework 4.6.1 and higher are supported, but 4.7.2 and higher are recommended.)

  • Starting with 3.0.0, Chr.Avro packages are strong named. Accordingly, Chr.Avro.Confluent 3.0.0 requires Confluent.Kafka and Confluent.SchemaRegistry ≥ 1.2.0.

  • Chr.Avro.Json now uses System.Text.Json under the hood (#20). As a result, some interfaces have changed. INewtonsoftJsonSchemaReader and INewtonsoftJsonSchemaWriter have been removed, and JsonElement has replaced JToken.

  • The case interfaces used by the JSON reader and writer, the schema builder, the type resolver, and the serde builders have been improved (#26). These changes make it easier to create custom cases and improve the usefulness of exceptions.

  • When serializing to the "decimal" logical type, numbers will no longer be truncated based on precision (#14). This aligns Chr.Avro with the official Java implementation and reduces the complexity of serde operations. Numbers may still be truncated based on scale.

Bug fixes

  • Prior to 3.0.0, DateTimeOffsets created from local times didn’t round trip correctly (#29, h/t @russell-mcdaniel).

  • Schemas built for flag enums now consider the enum’s underlying type (#27).

New features

  • Classes that extend Schema and LogicalType have been unsealed to support applications that require custom schema metadata.

  • Confluent.Kafka extension methods support DependentProducerBuilder (#30, h/t @woodlee and @promontis).

3.0.0-rc.1

11 Oct 15:02
Compare
Choose a tag to compare
3.0.0-rc.1 Pre-release
Pre-release
Release 3.0.0-rc.1