Class KafkaAdminClient


  • public class KafkaAdminClient
    extends Object
    Vert.x Kafka Admin client implementation

    NOTE: This class has been automatically generated from the original non Mutiny-ified interface using Vert.x codegen.

    • Constructor Detail

      • KafkaAdminClient

        public KafkaAdminClient​(io.vertx.kafka.admin.KafkaAdminClient delegate)
      • KafkaAdminClient

        public KafkaAdminClient​(Object delegate)
    • Method Detail

      • getDelegate

        public io.vertx.kafka.admin.KafkaAdminClient getDelegate()
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object
      • create

        public static KafkaAdminClient create​(Vertx vertx,
                                              Map<String,​String> config)
        Parameters:
        vertx - Vert.x instance to use
        config - Kafka admin client configuration
        Returns:
        an instance of the KafkaAdminClient
      • listTopics

        public io.smallrye.mutiny.Uni<Set<String>> listTopics()
        List the topics available in the cluster with the default options.

        Unlike the bare Vert.x variant, this method returns a Uni. Don't forget to subscribe on it to trigger the operation.

        Returns:
        the uni firing the result of the operation when completed, or a failure if the operation failed.
      • listTopicsAndAwait

        public Set<String> listTopicsAndAwait()
        Blocking variant of listTopics().

        This method waits for the completion of the underlying asynchronous operation. If the operation completes successfully, the result is returned, otherwise the failure is thrown (potentially wrapped in a RuntimeException).

        Returns:
        the Set instance produced by the operation.
      • listTopicsAndForget

        public void listTopicsAndForget()
        Variant of listTopics() that ignores the result of the operation.

        This method subscribes on the result of listTopics(), but discards the outcome (item or failure). This method is useful to trigger the asynchronous operation from listTopics() but you don't need to compose it with other operations.

      • describeTopics

        public io.smallrye.mutiny.Uni<Map<String,​io.vertx.kafka.admin.TopicDescription>> describeTopics​(List<String> topicNames)
        Describe some topics in the cluster, with the default options.

        Unlike the bare Vert.x variant, this method returns a Uni. Don't forget to subscribe on it to trigger the operation.

        Parameters:
        topicNames - the names of the topics to describe
        Returns:
        the uni firing the result of the operation when completed, or a failure if the operation failed.
      • describeTopicsAndAwait

        public Map<String,​io.vertx.kafka.admin.TopicDescription> describeTopicsAndAwait​(List<String> topicNames)
        Blocking variant of io.vertx.mutiny.kafka.admin.KafkaAdminClient#describeTopics(List).

        This method waits for the completion of the underlying asynchronous operation. If the operation completes successfully, the result is returned, otherwise the failure is thrown (potentially wrapped in a RuntimeException).

        Parameters:
        topicNames - the names of the topics to describe
        Returns:
        the Map instance produced by the operation.
      • describeTopicsAndForget

        public void describeTopicsAndForget​(List<String> topicNames)
        Variant of io.vertx.mutiny.kafka.admin.KafkaAdminClient#describeTopics(List) that ignores the result of the operation.

        This method subscribes on the result of io.vertx.mutiny.kafka.admin.KafkaAdminClient#describeTopics(List), but discards the outcome (item or failure). This method is useful to trigger the asynchronous operation from io.vertx.mutiny.kafka.admin.KafkaAdminClient#describeTopics(List) but you don't need to compose it with other operations.

        Parameters:
        topicNames - the names of the topics to describe
      • createTopics

        public io.smallrye.mutiny.Uni<Void> createTopics​(List<io.vertx.kafka.admin.NewTopic> topics)
        Creates a batch of new Kafka topics

        Unlike the bare Vert.x variant, this method returns a Uni. Don't forget to subscribe on it to trigger the operation.

        Parameters:
        topics - topics to create
        Returns:
        the uni firing the result of the operation when completed, or a failure if the operation failed.
      • createTopicsAndAwait

        public Void createTopicsAndAwait​(List<io.vertx.kafka.admin.NewTopic> topics)
        Blocking variant of io.vertx.mutiny.kafka.admin.KafkaAdminClient#createTopics(List).

        This method waits for the completion of the underlying asynchronous operation. If the operation completes successfully, the result is returned, otherwise the failure is thrown (potentially wrapped in a RuntimeException).

        Parameters:
        topics - topics to create
        Returns:
        the Void instance produced by the operation.
      • createTopicsAndForget

        public void createTopicsAndForget​(List<io.vertx.kafka.admin.NewTopic> topics)
        Variant of io.vertx.mutiny.kafka.admin.KafkaAdminClient#createTopics(List) that ignores the result of the operation.

        This method subscribes on the result of io.vertx.mutiny.kafka.admin.KafkaAdminClient#createTopics(List), but discards the outcome (item or failure). This method is useful to trigger the asynchronous operation from io.vertx.mutiny.kafka.admin.KafkaAdminClient#createTopics(List) but you don't need to compose it with other operations.

        Parameters:
        topics - topics to create
      • deleteTopics

        public io.smallrye.mutiny.Uni<Void> deleteTopics​(List<String> topicNames)
        Deletes a batch of Kafka topics

        Unlike the bare Vert.x variant, this method returns a Uni. Don't forget to subscribe on it to trigger the operation.

        Parameters:
        topicNames - the names of the topics to delete
        Returns:
        the uni firing the result of the operation when completed, or a failure if the operation failed.
      • deleteTopicsAndAwait

        public Void deleteTopicsAndAwait​(List<String> topicNames)
        Blocking variant of io.vertx.mutiny.kafka.admin.KafkaAdminClient#deleteTopics(List).

        This method waits for the completion of the underlying asynchronous operation. If the operation completes successfully, the result is returned, otherwise the failure is thrown (potentially wrapped in a RuntimeException).

        Parameters:
        topicNames - the names of the topics to delete
        Returns:
        the Void instance produced by the operation.
      • deleteTopicsAndForget

        public void deleteTopicsAndForget​(List<String> topicNames)
        Variant of io.vertx.mutiny.kafka.admin.KafkaAdminClient#deleteTopics(List) that ignores the result of the operation.

        This method subscribes on the result of io.vertx.mutiny.kafka.admin.KafkaAdminClient#deleteTopics(List), but discards the outcome (item or failure). This method is useful to trigger the asynchronous operation from io.vertx.mutiny.kafka.admin.KafkaAdminClient#deleteTopics(List) but you don't need to compose it with other operations.

        Parameters:
        topicNames - the names of the topics to delete
      • createPartitions

        public io.smallrye.mutiny.Uni<Void> createPartitions​(Map<String,​io.vertx.kafka.admin.NewPartitions> partitions)
        Creates a batch of new partitions in the Kafka topic

        Unlike the bare Vert.x variant, this method returns a Uni. Don't forget to subscribe on it to trigger the operation.

        Parameters:
        partitions - partitions to create
        Returns:
        the uni firing the result of the operation when completed, or a failure if the operation failed.
      • createPartitionsAndAwait

        public Void createPartitionsAndAwait​(Map<String,​io.vertx.kafka.admin.NewPartitions> partitions)
        Blocking variant of io.vertx.mutiny.kafka.admin.KafkaAdminClient#createPartitions(Map).

        This method waits for the completion of the underlying asynchronous operation. If the operation completes successfully, the result is returned, otherwise the failure is thrown (potentially wrapped in a RuntimeException).

        Parameters:
        partitions - partitions to create
        Returns:
        the Void instance produced by the operation.
      • createPartitionsAndForget

        public void createPartitionsAndForget​(Map<String,​io.vertx.kafka.admin.NewPartitions> partitions)
        Variant of io.vertx.mutiny.kafka.admin.KafkaAdminClient#createPartitions(Map) that ignores the result of the operation.

        This method subscribes on the result of io.vertx.mutiny.kafka.admin.KafkaAdminClient#createPartitions(Map), but discards the outcome (item or failure). This method is useful to trigger the asynchronous operation from io.vertx.mutiny.kafka.admin.KafkaAdminClient#createPartitions(Map) but you don't need to compose it with other operations.

        Parameters:
        partitions - partitions to create
      • listConsumerGroups

        public io.smallrye.mutiny.Uni<List<io.vertx.kafka.admin.ConsumerGroupListing>> listConsumerGroups()
        Get the the consumer groups available in the cluster with the default options

        Unlike the bare Vert.x variant, this method returns a Uni. Don't forget to subscribe on it to trigger the operation.

        Returns:
        the uni firing the result of the operation when completed, or a failure if the operation failed.
      • listConsumerGroupsAndAwait

        public List<io.vertx.kafka.admin.ConsumerGroupListing> listConsumerGroupsAndAwait()
        Blocking variant of listConsumerGroups().

        This method waits for the completion of the underlying asynchronous operation. If the operation completes successfully, the result is returned, otherwise the failure is thrown (potentially wrapped in a RuntimeException).

        Returns:
        the List instance produced by the operation.
      • listConsumerGroupsAndForget

        public void listConsumerGroupsAndForget()
        Variant of listConsumerGroups() that ignores the result of the operation.

        This method subscribes on the result of listConsumerGroups(), but discards the outcome (item or failure). This method is useful to trigger the asynchronous operation from listConsumerGroups() but you don't need to compose it with other operations.

      • describeConsumerGroups

        public io.smallrye.mutiny.Uni<Map<String,​io.vertx.kafka.admin.ConsumerGroupDescription>> describeConsumerGroups​(List<String> groupIds)
        Describe some group ids in the cluster, with the default options

        Unlike the bare Vert.x variant, this method returns a Uni. Don't forget to subscribe on it to trigger the operation.

        Parameters:
        groupIds - the ids of the groups to describe
        Returns:
        the uni firing the result of the operation when completed, or a failure if the operation failed.
      • describeConsumerGroupsAndAwait

        public Map<String,​io.vertx.kafka.admin.ConsumerGroupDescription> describeConsumerGroupsAndAwait​(List<String> groupIds)
        Blocking variant of io.vertx.mutiny.kafka.admin.KafkaAdminClient#describeConsumerGroups(List).

        This method waits for the completion of the underlying asynchronous operation. If the operation completes successfully, the result is returned, otherwise the failure is thrown (potentially wrapped in a RuntimeException).

        Parameters:
        groupIds - the ids of the groups to describe
        Returns:
        the Map instance produced by the operation.
      • describeConsumerGroupsAndForget

        public void describeConsumerGroupsAndForget​(List<String> groupIds)
        Variant of io.vertx.mutiny.kafka.admin.KafkaAdminClient#describeConsumerGroups(List) that ignores the result of the operation.

        This method subscribes on the result of io.vertx.mutiny.kafka.admin.KafkaAdminClient#describeConsumerGroups(List), but discards the outcome (item or failure). This method is useful to trigger the asynchronous operation from io.vertx.mutiny.kafka.admin.KafkaAdminClient#describeConsumerGroups(List) but you don't need to compose it with other operations.

        Parameters:
        groupIds - the ids of the groups to describe
      • describeCluster

        public io.smallrye.mutiny.Uni<io.vertx.kafka.admin.ClusterDescription> describeCluster()
        Describe the nodes in the cluster with the default options

        Unlike the bare Vert.x variant, this method returns a Uni. Don't forget to subscribe on it to trigger the operation.

        Returns:
        the uni firing the result of the operation when completed, or a failure if the operation failed.
      • describeClusterAndAwait

        public io.vertx.kafka.admin.ClusterDescription describeClusterAndAwait()
        Blocking variant of describeCluster().

        This method waits for the completion of the underlying asynchronous operation. If the operation completes successfully, the result is returned, otherwise the failure is thrown (potentially wrapped in a RuntimeException).

        Returns:
        the ClusterDescription instance produced by the operation.
      • describeClusterAndForget

        public void describeClusterAndForget()
        Variant of describeCluster() that ignores the result of the operation.

        This method subscribes on the result of describeCluster(), but discards the outcome (item or failure). This method is useful to trigger the asynchronous operation from describeCluster() but you don't need to compose it with other operations.

      • deleteConsumerGroups

        public io.smallrye.mutiny.Uni<Void> deleteConsumerGroups​(List<String> groupIds)
        Delete consumer groups from the cluster.

        Unlike the bare Vert.x variant, this method returns a Uni. Don't forget to subscribe on it to trigger the operation.

        Parameters:
        groupIds - the ids of the groups to delete
        Returns:
        the uni firing the result of the operation when completed, or a failure if the operation failed.
      • deleteConsumerGroupsAndAwait

        public Void deleteConsumerGroupsAndAwait​(List<String> groupIds)
        Blocking variant of io.vertx.mutiny.kafka.admin.KafkaAdminClient#deleteConsumerGroups(List).

        This method waits for the completion of the underlying asynchronous operation. If the operation completes successfully, the result is returned, otherwise the failure is thrown (potentially wrapped in a RuntimeException).

        Parameters:
        groupIds - the ids of the groups to delete
        Returns:
        the Void instance produced by the operation.
      • deleteConsumerGroupsAndForget

        public void deleteConsumerGroupsAndForget​(List<String> groupIds)
        Variant of io.vertx.mutiny.kafka.admin.KafkaAdminClient#deleteConsumerGroups(List) that ignores the result of the operation.

        This method subscribes on the result of io.vertx.mutiny.kafka.admin.KafkaAdminClient#deleteConsumerGroups(List), but discards the outcome (item or failure). This method is useful to trigger the asynchronous operation from io.vertx.mutiny.kafka.admin.KafkaAdminClient#deleteConsumerGroups(List) but you don't need to compose it with other operations.

        Parameters:
        groupIds - the ids of the groups to delete
      • deleteConsumerGroupOffsets

        public io.smallrye.mutiny.Uni<Void> deleteConsumerGroupOffsets​(String groupId,
                                                                       Set<io.vertx.kafka.client.common.TopicPartition> partitions)
        Delete committed offsets for a set of partitions in a consumer group. This will succeed at the partition level only if the group is not actively subscribed to the corresponding topic.

        Unlike the bare Vert.x variant, this method returns a Uni. Don't forget to subscribe on it to trigger the operation.

        Parameters:
        groupId - The group id of the group whose offsets will be deleted
        partitions - The set of partitions in the consumer group whose offsets will be deleted
        Returns:
        the uni firing the result of the operation when completed, or a failure if the operation failed.
      • deleteConsumerGroupOffsetsAndAwait

        public Void deleteConsumerGroupOffsetsAndAwait​(String groupId,
                                                       Set<io.vertx.kafka.client.common.TopicPartition> partitions)
        Blocking variant of io.vertx.mutiny.kafka.admin.KafkaAdminClient#deleteConsumerGroupOffsets(String,Set).

        This method waits for the completion of the underlying asynchronous operation. If the operation completes successfully, the result is returned, otherwise the failure is thrown (potentially wrapped in a RuntimeException).

        Parameters:
        groupId - The group id of the group whose offsets will be deleted
        partitions - The set of partitions in the consumer group whose offsets will be deleted
        Returns:
        the Void instance produced by the operation.
      • deleteConsumerGroupOffsetsAndForget

        public void deleteConsumerGroupOffsetsAndForget​(String groupId,
                                                        Set<io.vertx.kafka.client.common.TopicPartition> partitions)
        Variant of io.vertx.mutiny.kafka.admin.KafkaAdminClient#deleteConsumerGroupOffsets(String,Set) that ignores the result of the operation.

        This method subscribes on the result of io.vertx.mutiny.kafka.admin.KafkaAdminClient#deleteConsumerGroupOffsets(String,Set), but discards the outcome (item or failure). This method is useful to trigger the asynchronous operation from io.vertx.mutiny.kafka.admin.KafkaAdminClient#deleteConsumerGroupOffsets(String,Set) but you don't need to compose it with other operations.

        Parameters:
        groupId - The group id of the group whose offsets will be deleted
        partitions - The set of partitions in the consumer group whose offsets will be deleted
      • close

        public io.smallrye.mutiny.Uni<Void> close()
        Close the admin client

        Unlike the bare Vert.x variant, this method returns a Uni. Don't forget to subscribe on it to trigger the operation.

        Returns:
        the uni firing the result of the operation when completed, or a failure if the operation failed.
      • closeAndAwait

        public Void closeAndAwait()
        Blocking variant of close().

        This method waits for the completion of the underlying asynchronous operation. If the operation completes successfully, the result is returned, otherwise the failure is thrown (potentially wrapped in a RuntimeException).

        Returns:
        the Void instance produced by the operation.
      • closeAndForget

        public void closeAndForget()
        Variant of close() that ignores the result of the operation.

        This method subscribes on the result of close(), but discards the outcome (item or failure). This method is useful to trigger the asynchronous operation from close() but you don't need to compose it with other operations.

      • close

        public io.smallrye.mutiny.Uni<Void> close​(long timeout)
        Close the admin client

        Unlike the bare Vert.x variant, this method returns a Uni. Don't forget to subscribe on it to trigger the operation.

        Parameters:
        timeout - timeout to wait for closing
        Returns:
        the uni firing the result of the operation when completed, or a failure if the operation failed.
      • closeAndAwait

        public Void closeAndAwait​(long timeout)
        Blocking variant of close(long).

        This method waits for the completion of the underlying asynchronous operation. If the operation completes successfully, the result is returned, otherwise the failure is thrown (potentially wrapped in a RuntimeException).

        Parameters:
        timeout - timeout to wait for closing
        Returns:
        the Void instance produced by the operation.
      • closeAndForget

        public void closeAndForget​(long timeout)
        Variant of close(long) that ignores the result of the operation.

        This method subscribes on the result of close(long), but discards the outcome (item or failure). This method is useful to trigger the asynchronous operation from close(long) but you don't need to compose it with other operations.

        Parameters:
        timeout - timeout to wait for closing
      • newInstance

        public static KafkaAdminClient newInstance​(io.vertx.kafka.admin.KafkaAdminClient arg)