MetadataCache
is…FIXME
MetadataCache
is created exclusively for KafkaServer (when started).
MetadataCache
takes a single broker ID when created.
MetadataCache
maintains the metadataSnapshot and is used to…FIXME
MetadataCache
tracks the controllerId
…FIXME
Name | Description |
---|---|
|
|
|
Java’s ReentrantReadWriteLock |
|
MetadataCache
uses [MetadataCache brokerId=[brokerId]] as the logging prefix (aka logIdent
).
Tip
|
Enable Add the following line to
Refer to Logging. |
getAllTopics(): Set[String]
getAllTopics
…FIXME
Note
|
getAllTopics is used when…FIXME
|
getTopicMetadata(
topics: Set[String],
listenerName: ListenerName,
errorUnavailableEndpoints: Boolean = false,
errorUnavailableListeners: Boolean = false): Seq[MetadataResponse.TopicMetadata]
getTopicMetadata
…FIXME
Note
|
getTopicMetadata is used when…FIXME
|
getAliveBrokers: Seq[Broker]
getAliveBrokers
…FIXME
Note
|
getAliveBrokers is used when…FIXME
|
updateMetadata(
correlationId: Int,
updateMetadataRequest: UpdateMetadataRequest): Seq[TopicPartition]
updateMetadata
…FIXME
Note
|
updateMetadata is used exclusively when ReplicaManager is requested to maybeUpdateMetadataCache.
|
getClusterMetadata(clusterId: String, listenerName: ListenerName): Cluster
getClusterMetadata
…FIXME
Note
|
getClusterMetadata is used exclusively when KafkaApis is requested to handle an UpdateMetadata request.
|
getPartitionReplicaEndpoints(
tp: TopicPartition,
listenerName: ListenerName): Map[Int, Node]
getPartitionReplicaEndpoints
…FIXME
Note
|
getPartitionReplicaEndpoints is used when ReplicaManager is requested to findPreferredReadReplica.
|