C# Класс KafkaNet.KafkaMetadataProvider

This provider blocks while it attempts to get the MetaData configuration of the Kafka servers. If any retry errors occurs it will continue to block the downstream call and then repeatedly query kafka until the retry errors subside. This repeat call happens in a backoff manner, which each subsequent call waiting longer before a requery. Error Codes: LeaderNotAvailable = 5 NotLeaderForPartition = 6 ConsumerCoordinatorNotAvailableCode = 15 BrokerId = -1 Documentation: https://cwiki.apache.org/confluence/display/KAFKA/A+Guide+To+The+Kafka+Protocol#AGuideToTheKafkaProtocol-MetadataResponse
Наследование: IDisposable
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
Dispose ( ) : void
Get ( IKafkaConnection connections ) : Task

Given a collection of server connections, query for all topics metadata.

Get ( IKafkaConnection connections, IEnumerable topics ) : Task

Given a collection of server connections, query for the topic metadata.

KafkaMetadataProvider ( IKafkaLog log ) : KafkaNet.Protocol

Приватные методы

Метод Описание
BackoffOnRetry ( int retryAttempt, bool performRetry ) : System.Threading.Tasks.Task
Get ( IKafkaConnection connections, MetadataRequest request ) : Task
GetMetadataResponse ( IKafkaConnection connections, MetadataRequest request ) : Task
ValidateBroker ( Broker broker ) : MetadataValidationResult
ValidateResponse ( MetadataResponse metadata ) : IEnumerable
ValidateTopic ( Topic topic ) : MetadataValidationResult

Описание методов

Dispose() публичный Метод

public Dispose ( ) : void
Результат void

Get() публичный Метод

Given a collection of server connections, query for all topics metadata.
public Get ( IKafkaConnection connections ) : Task
connections IKafkaConnection The server connections to query. Will cycle through the collection, starting at zero until a response is received.
Результат Task

Get() публичный Метод

Given a collection of server connections, query for the topic metadata.
public Get ( IKafkaConnection connections, IEnumerable topics ) : Task
connections IKafkaConnection The server connections to query. Will cycle through the collection, starting at zero until a response is received.
topics IEnumerable The collection of topics to get metadata for.
Результат Task

KafkaMetadataProvider() публичный Метод

public KafkaMetadataProvider ( IKafkaLog log ) : KafkaNet.Protocol
log IKafkaLog
Результат KafkaNet.Protocol