Table of Contents

Class AvroSharpGenericRecordSerializer

Namespace
AvroSharp.Confluent
Assembly
AvroSharp.Confluent.dll

Writes generic records, each with its own schema (Schema), as Confluent's generic Avro serializer does: one serializer for a topic that carries records of several schemas, such as a bridge or a replay tool. Each schema is registered (or looked up) under its subject once, by the subject name strategy, with the record's name for the Record and TopicRecord strategies. Created by CreateSerializer(ISchemaRegistryClient, AvroSharpSerializerConfig?, RuleRegistry?).

public sealed class AvroSharpGenericRecordSerializer : IAsyncSerializer<AvroValue>, ISerializer<AvroValue>
Inheritance
AvroSharpGenericRecordSerializer
Implements
IAsyncSerializer<AvroValue>
ISerializer<AvroValue>
Inherited Members

Remarks

It is both asynchronous and synchronous, as AvroSharpSerializer<T> is. Its caches are kept per schema instance, so records that share a RecordSchema share them.

Methods

Serialize(AvroValue, SerializationContext)

Writes a record with its schema, without a task once its schema ID is known. A null value is a tombstone: no message body.

SerializeAsync(AvroValue, SerializationContext)

Writes a record with its schema. A null value is a tombstone: no message body.