AvroSharp.KafkaFlow 1.0.0

dotnet add package AvroSharp.KafkaFlow --version 1.0.0
                    
NuGet\Install-Package AvroSharp.KafkaFlow -Version 1.0.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="AvroSharp.KafkaFlow" Version="1.0.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="AvroSharp.KafkaFlow" Version="1.0.0" />
                    
Directory.Packages.props
<PackageReference Include="AvroSharp.KafkaFlow" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add AvroSharp.KafkaFlow --version 1.0.0
                    
#r "nuget: AvroSharp.KafkaFlow, 1.0.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package AvroSharp.KafkaFlow@1.0.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=AvroSharp.KafkaFlow&version=1.0.0
                    
Install as a Cake Addin
#tool nuget:?package=AvroSharp.KafkaFlow&version=1.0.0
                    
Install as a Cake Tool

AvroSharp.KafkaFlow

KafkaFlow serializer middleware for Confluent Schema Registry, on AvroSharp and AvroSharp.Confluent, without Apache.Avro. A replacement for KafkaFlow's KafkaFlow.Serializer.SchemaRegistry.ConfluentAvro:

  • The same bytes and subjects as KafkaFlow's Confluent Avro serializer. The tests compare them byte for byte, and each reads what the other writes.
  • The same setup: KafkaFlow's WithSchemaRegistry on the cluster, and AddSchemaRegistryAvroSharpSerializer and AddSchemaRegistryAvroSharpDeserializer in place of KafkaFlow's methods.
  • Types: generated from .avsc files, or your own C# types marked [AvroSerializable]. Several record types can share one topic, each read as its own type.
  • Schema evolution: each message is read in its writer's schema and resolved to your type's.

Status: new in 1.0.0, and released with AvroSharp at the same version. It follows semantic versioning with the rest of AvroSharp.

Guide · API reference · AvroSharp.Confluent's guide · AvroSharp documentation

Install

dotnet add package AvroSharp.KafkaFlow
dotnet add package AvroSharp.Generators

AvroSharp.KafkaFlow depends on KafkaFlow 4.0.0 or later (below 5.0), and targets .NET 8 and later (no .NET Framework). KafkaFlow's assemblies aren't strong-named, so neither is this one.

Use

services.AddKafka(kafka => kafka.AddCluster(cluster => cluster
    .WithBrokers(["localhost:9092"])
    .WithSchemaRegistry(config => config.Url = "http://localhost:8081")
    .AddProducer("orders", producer => producer
        .DefaultTopic("orders")
        .AddMiddlewares(middlewares => middlewares.AddSchemaRegistryAvroSharpSerializer()))
    .AddConsumer(consumer => consumer
        .Topic("orders")
        .WithGroupId("billing")
        .WithBufferSize(100)
        .WithWorkersCount(10)
        .AddMiddlewares(middlewares => middlewares
            .AddSchemaRegistryAvroSharpDeserializer<Order>()
            .AddTypedHandlers(handlers => handlers.AddHandler<OrderHandler>())))));

For a topic with several record types, pass them to the deserializer: AddSchemaRegistryAvroSharpDeserializer([typeof(OrderPlaced), typeof(OrderShipped)]). The guide covers that, the settings, and moving from KafkaFlow's Confluent Avro serializer.

Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 is compatible.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
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
1.0.0 58 10/3/2026