confluent-kafka-dotnet
Show / Hide Table of Contents

Class AsyncSerde<TParsedSchema>

Inheritance
object
AsyncSerde<TParsedSchema>
AsyncDeserializer<T, TParsedSchema>
AsyncSerializer<T, TParsedSchema>
Inherited Members
object.Equals(object)
object.Equals(object, object)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
object.ReferenceEquals(object, object)
object.ToString()
Namespace: Confluent.SchemaRegistry
Assembly: Confluent.SchemaRegistry.dll
Syntax
public abstract class AsyncSerde<TParsedSchema>
Type Parameters
NameDescription
TParsedSchema

Constructors

AsyncSerde(ISchemaRegistryClient, SerdeConfig, RuleRegistry)

Declaration
protected AsyncSerde(ISchemaRegistryClient schemaRegistryClient, SerdeConfig config, RuleRegistry ruleRegistry = null)
Parameters
TypeNameDescription
ISchemaRegistryClientschemaRegistryClient
SerdeConfigconfig
RuleRegistryruleRegistry

Fields

latestCompatibilityStrict

Declaration
protected bool latestCompatibilityStrict
Field Value
TypeDescription
bool

ruleRegistry

Declaration
protected RuleRegistry ruleRegistry
Field Value
TypeDescription
RuleRegistry

schemaRegistryClient

Declaration
protected ISchemaRegistryClient schemaRegistryClient
Field Value
TypeDescription
ISchemaRegistryClient

serdeMutex

Declaration
protected SemaphoreSlim serdeMutex
Field Value
TypeDescription
SemaphoreSlim

subjectNameStrategy

Declaration
protected SubjectNameStrategyDelegate subjectNameStrategy
Field Value
TypeDescription
SubjectNameStrategyDelegate

useLatestVersion

Declaration
protected bool useLatestVersion
Field Value
TypeDescription
bool

useLatestWithMetadata

Declaration
protected IDictionary<string, string> useLatestWithMetadata
Field Value
TypeDescription
IDictionary<string, string>

useSchemaId

Declaration
protected int useSchemaId
Field Value
TypeDescription
int

Methods

ExecuteMigrations(IList<Migration>, bool, string, string, Headers, object)

Declaration
protected Task<object> ExecuteMigrations(IList<Migration> migrations, bool isKey, string subject, string topic, Headers headers, object message)
Parameters
TypeNameDescription
IList<Migration>migrations
boolisKey
stringsubject
stringtopic
Headersheaders
objectmessage
Returns
TypeDescription
Task<object>

ExecuteRules(bool, string, string, Headers, RuleMode, Schema, Schema, object, FieldTransformer)

Execute rules

Declaration
protected Task<object> ExecuteRules(bool isKey, string subject, string topic, Headers headers, RuleMode ruleMode, Schema source, Schema target, object message, FieldTransformer fieldTransformer)
Parameters
TypeNameDescription
boolisKey
stringsubject
stringtopic
Headersheaders
RuleModeruleMode
Schemasource
Schematarget
objectmessage
FieldTransformerfieldTransformer
Returns
TypeDescription
Task<object>
Exceptions
TypeCondition
RuleConditionException
ArgumentException

ExecuteRules(bool, string, string, Headers, RulePhase, RuleMode, Schema, Schema, object, FieldTransformer)

Execute rules

Declaration
protected Task<object> ExecuteRules(bool isKey, string subject, string topic, Headers headers, RulePhase rulePhase, RuleMode ruleMode, Schema source, Schema target, object message, FieldTransformer fieldTransformer)
Parameters
TypeNameDescription
boolisKey
stringsubject
stringtopic
Headersheaders
RulePhaserulePhase
RuleModeruleMode
Schemasource
Schematarget
objectmessage
FieldTransformerfieldTransformer
Returns
TypeDescription
Task<object>
Exceptions
TypeCondition
RuleConditionException
ArgumentException

GetMigrations(string, Schema, RegisteredSchema)

Declaration
protected Task<IList<Migration>> GetMigrations(string subject, Schema writer, RegisteredSchema readerSchema)
Parameters
TypeNameDescription
stringsubject
Schemawriter
RegisteredSchemareaderSchema
Returns
TypeDescription
Task<IList<Migration>>

GetParsedSchema(Schema)

Declaration
protected Task<TParsedSchema> GetParsedSchema(Schema schema)
Parameters
TypeNameDescription
Schemaschema
Returns
TypeDescription
Task<TParsedSchema>

GetReaderSchema(string, Schema)

Declaration
protected Task<RegisteredSchema> GetReaderSchema(string subject, Schema schema = null)
Parameters
TypeNameDescription
stringsubject
Schemaschema
Returns
TypeDescription
Task<RegisteredSchema>

GetSubjectName(string, bool, string)

Declaration
protected string GetSubjectName(string topic, bool isKey, string recordType)
Parameters
TypeNameDescription
stringtopic
boolisKey
stringrecordType
Returns
TypeDescription
string

GetWriterSchema(string, SchemaId, string)

Declaration
protected Task<(Schema, TParsedSchema)> GetWriterSchema(string subject, SchemaId writerId, string format = null)
Parameters
TypeNameDescription
stringsubject
SchemaIdwriterId
stringformat
Returns
TypeDescription
Task<(Schema, TParsedSchema)>

IgnoreReference(string)

Declaration
protected virtual bool IgnoreReference(string name)
Parameters
TypeNameDescription
stringname
Returns
TypeDescription
bool

ParseSchema(Schema)

Declaration
protected abstract Task<TParsedSchema> ParseSchema(Schema schema)
Parameters
TypeNameDescription
Schemaschema
Returns
TypeDescription
Task<TParsedSchema>

ResolveReferences(Schema)

Declaration
protected Task<IDictionary<string, string>> ResolveReferences(Schema schema)
Parameters
TypeNameDescription
Schemaschema
Returns
TypeDescription
Task<IDictionary<string, string>>
In this article