AdminClient

AdminClient is the base of administrative clients for Apache Kafka with support for managing and inspecting topics, brokers, configurations and ACLs.

Note
KafkaAdminClient is the default and only known implementation of the AdminClient Contract in Apache Kafka.
Table 1. AdminClient Contract (Abstract Methods Only)
Method Description

alterReplicaLogDirs

AlterReplicaLogDirsResult alterReplicaLogDirs(
  Map<TopicPartitionReplica, String> replicaAssignment,
  AlterReplicaLogDirsOptions options)

Used when…​FIXME

close

void close(
  Duration timeout)

Used when…​FIXME

createAcls

CreateAclsResult createAcls(
  Collection<AclBinding> acls,
  CreateAclsOptions options)

Used when…​FIXME

createDelegationToken

CreateDelegationTokenResult createDelegationToken(
  CreateDelegationTokenOptions options)

Used when…​FIXME

createPartitions

CreatePartitionsResult createPartitions(
  Map<String, NewPartitions> newPartitions,
  CreatePartitionsOptions options)

Used when…​FIXME

createTopics

CreateTopicsResult createTopics(
  Collection<NewTopic> newTopics,
  CreateTopicsOptions options)

Used when…​FIXME

deleteAcls

DeleteAclsResult deleteAcls(
  Collection<AclBindingFilter> filters,
  DeleteAclsOptions options)

Used when…​FIXME

deleteConsumerGroups

DeleteConsumerGroupsResult deleteConsumerGroups(
  Collection<String> groupIds,
  DeleteConsumerGroupsOptions options)

Used when…​FIXME

deleteRecords

DeleteRecordsResult deleteRecords(
  Map<TopicPartition, RecordsToDelete> recordsToDelete,
  DeleteRecordsOptions options)

Used when…​FIXME

deleteTopics

DeleteTopicsResult deleteTopics(
  Collection<String> topics,
  DeleteTopicsOptions options)

Used when…​FIXME

describeAcls

DescribeAclsResult describeAcls(
  AclBindingFilter filter,
  DescribeAclsOptions options)

Used when…​FIXME

describeCluster

DescribeClusterResult describeCluster(
  DescribeClusterOptions options)

Used when…​FIXME

describeConfigs

DescribeConfigsResult describeConfigs(
  Collection<ConfigResource> resources,
  DescribeConfigsOptions options)

Used when…​FIXME

describeConsumerGroups

DescribeConsumerGroupsResult describeConsumerGroups(
  Collection<String> groupIds,
  DescribeConsumerGroupsOptions options)

Used when…​FIXME

describeDelegationToken

DescribeDelegationTokenResult describeDelegationToken(
  DescribeDelegationTokenOptions options)

Used when…​FIXME

describeLogDirs

DescribeLogDirsResult describeLogDirs(
  Collection<Integer> brokers,
  DescribeLogDirsOptions options)

Used when…​FIXME

describeReplicaLogDirs

DescribeReplicaLogDirsResult describeReplicaLogDirs(
  Collection<TopicPartitionReplica> replicas,
  DescribeReplicaLogDirsOptions options)

Used when…​FIXME

describeTopics

DescribeTopicsResult describeTopics(
  Collection<String> topicNames,
  DescribeTopicsOptions options)

Used when…​FIXME

electPreferredLeaders

ElectPreferredLeadersResult electPreferredLeaders(
  Collection<TopicPartition> partitions,
  ElectPreferredLeadersOptions options)
ElectPreferredLeadersResult electPreferredLeaders(
  Collection<TopicPartition> partitions) (1)
  1. Uses the default ElectPreferredLeadersOptions

Used when PreferredReplicaLeaderElectionCommand utility is requested to electPreferredLeaders

expireDelegationToken

ExpireDelegationTokenResult expireDelegationToken(
  byte[] hmac,
  ExpireDelegationTokenOptions options)

Used when…​FIXME

incrementalAlterConfigs

AlterConfigsResult incrementalAlterConfigs(
  Map<ConfigResource,
  Collection<AlterConfigOp>> configs,
  AlterConfigsOptions options)

Used when…​FIXME

listConsumerGroupOffsets

ListConsumerGroupOffsetsResult listConsumerGroupOffsets(
  String groupId,
  ListConsumerGroupOffsetsOptions options)

Used when…​FIXME

listConsumerGroups

ListConsumerGroupsResult listConsumerGroups(
  ListConsumerGroupsOptions options)

Used when…​FIXME

listTopics

ListTopicsResult listTopics(
  ListTopicsOptions options)

Used when…​FIXME

metrics

Map<MetricName, ? extends Metric> metrics()

Used when…​FIXME

renewDelegationToken

RenewDelegationTokenResult renewDelegationToken(
  byte[] hmac,
  RenewDelegationTokenOptions options)

Used when…​FIXME

Creating AdminClient Instance — create Object Method

AdminClient create(Properties props)
AdminClient create(Map<String, Object> conf)

create simply requests the KafkaAdminClient object to create a KafkaAdminClient.

Note
create is used in Kafka administration utilities.

results matching ""

    No results matching ""