public class MetadataClient
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
MetadataClient.ClusterAndGeneration |
static class |
MetadataClient.ClusterAndPlacements |
Constructor and Description |
---|
MetadataClient(KafkaCruiseControlConfig config,
long metadataTTLMs,
org.apache.kafka.common.utils.Time time) |
Modifier and Type | Method and Description |
---|---|
void |
close()
Close the admin client.
|
org.apache.kafka.common.Cluster |
cluster()
Get the current cluster.
|
MetadataClient.ClusterAndGeneration |
clusterAndGeneration()
Get the current cluster and generation
|
MetadataClient.ClusterAndGeneration |
refreshMetadata()
Refresh the metadata.
|
MetadataClient.ClusterAndGeneration |
refreshMetadata(int timeoutMs)
Refresh the metadata.
|
java.util.Map<java.lang.String,kafka.common.TopicPlacement> |
topicPlacements() |
public MetadataClient(KafkaCruiseControlConfig config, long metadataTTLMs, org.apache.kafka.common.utils.Time time)
public MetadataClient.ClusterAndGeneration refreshMetadata()
public MetadataClient.ClusterAndGeneration refreshMetadata(int timeoutMs)
public void close()
public MetadataClient.ClusterAndGeneration clusterAndGeneration()
public org.apache.kafka.common.Cluster cluster()
public java.util.Map<java.lang.String,kafka.common.TopicPlacement> topicPlacements()