Méthode | Description | |
---|---|---|
BrokerRouter ( |
||
Dispose ( ) : void | ||
GetAllTopicMetadataFromLocalCache ( ) : List |
Returns Topic metadata for each topic. The topic metadata will by default check the cache. To force querying the metadata from the server use RefreshAllTopicMetadata |
|
GetTopicMetadataFromLocalCache ( ) : List |
Returns Topic metadata for each topic requested. The topic metadata will by default check the cache first and then if it does not exist it will then request metadata from the server. To force querying the metadata from the server use RefreshTopicMetadata |
|
GetTopicMetadataRefreshTime ( string topic ) : System.DateTime | ||
RefreshAllTopicMetadata ( ) : Task |
Force a call to the kafka servers to refresh metadata for all topics. This method will ignore the cache and initiate a call to the kafka servers for all topics, updating the cache with the resulting metadata. Only call this method to force a metadata update. For all other queries use GetAllTopicMetadataFromLocalCache which uses cached values. |
|
RefreshMissingTopicMetadata ( ) : Task | ||
RefreshTopicMetadata ( ) : Task |
Force a call to the kafka servers to refresh metadata for the given topics. This method will ignore the cache and initiate a call to the kafka servers for all given topics, updating the cache with the resulting metadata. Only call this method to force a metadata update. For all other queries use GetTopicMetadataFromLocalCache which uses cached values. |
|
SelectBrokerRouteFromLocalCache ( string topic, byte key = null ) : KafkaNet.BrokerRoute |
Select a broker for a given topic using the IPartitionSelector function.
|
|
SelectBrokerRouteFromLocalCache ( string topic, int partitionId ) : KafkaNet.BrokerRoute |
Select a broker for a specific topic and partitionId. This function does not use any selector criteria. If the given partitionId does not exist an exception will be thrown. |
Méthode | Description | |
---|---|---|
GetCachedRoute ( string topic, KafkaNet.Protocol.Partition partition ) : KafkaNet.BrokerRoute | ||
GetCachedTopic ( string topic, System.TimeSpan expiration = null ) : KafkaNet.Protocol.Topic | ||
GetConnections ( ) : IKafkaConnection[] | ||
RefreshAllTopicMetadata ( System.TimeSpan timeout ) : Task |
Force refresh each topic metadata that exists on kafka servers.
|
|
RefreshTopicMetadata ( System.TimeSpan cacheExpiration, System.TimeSpan timeout ) : Task |
Refresh metadata Request will try to refresh only the topics that were expired in the cache. If cacheExpiration is null: refresh metadata Request will try to refresh only topics that are not in the cache.
|
|
SearchCacheForTopics ( IEnumerable |
||
TryGetRouteFromCache ( string topic, KafkaNet.Protocol.Partition partition ) : KafkaNet.BrokerRoute | ||
UpdateInternalMetadataCache ( MetadataResponse metadata ) : void | ||
UpsertConnectionToBrokerConnectionIndex ( int brokerId, KafkaNet.Model.KafkaEndpoint brokerEndpoint, IKafkaConnection>.Func |
public BrokerRouter ( |
||
kafkaOptions | ||
Résultat | KafkaNet.Common |
public GetAllTopicMetadataFromLocalCache ( ) : List |
||
Résultat | List |
public GetTopicMetadataFromLocalCache ( ) : List |
||
Résultat | List |
public GetTopicMetadataRefreshTime ( string topic ) : System.DateTime | ||
topic | string | |
Résultat | System.DateTime |
public RefreshMissingTopicMetadata ( ) : Task | ||
Résultat | Task |
public SelectBrokerRouteFromLocalCache ( string topic, byte key = null ) : KafkaNet.BrokerRoute | ||
topic | string | The topic to retreive a broker route for. |
key | byte | The key used by the IPartitionSelector to collate to a consistent partition. Null value means key will be ignored in selection process. |
Résultat | KafkaNet.BrokerRoute |
public SelectBrokerRouteFromLocalCache ( string topic, int partitionId ) : KafkaNet.BrokerRoute | ||
topic | string | The topic name to select a broker for. |
partitionId | int | The exact partition to select a broker for. |
Résultat | KafkaNet.BrokerRoute |