Package io.strimzi.systemtest.utils.kafkaUtils

## Class KafkaTopicUtils

- java.lang.Object
- - io.strimzi.systemtest.utils.kafkaUtils.KafkaTopicUtils

-     public class KafkaTopicUtils
      extends Object

- - ### Method Summary

    All Methods Static Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `static String` | `generateRandomNameOfTopic()` | Generated random name for the KafkaTopic resource
    `static String` | `topicSnapshot​(String topicName)` | Method which return UID for specific topic
    `static void` | `waitForKafkaTopicCreation​(String topicName)` |
    `static void` | `waitForKafkaTopicCreationByNamePrefix​(String topicNamePrefix)` |
    `static void` | `waitForKafkaTopicDeletion​(String topicName)` |
    `static void` | `waitForKafkaTopicNotReady​(String topicName)` |
    `static void` | `waitForKafkaTopicPartitionChange​(String topicName, int partitions)` |
    `static void` | `waitForKafkaTopicReady​(String topicName)` |
    `static void` | `waitForKafkaTopicsCount​(int topicCount, String clusterName)` |
    `static void` | `waitForKafkaTopicStatus​(String topicName, Enum<?> state)` | Wait until KafkaTopic is in desired status
    `static String` | `waitTopicHasRolled​(String topicName, String topicUid)` | Method which wait until topic has rolled form one generation to another.

    - ### Methods inherited from class java.lang.Object

      `equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Method Detail

    - #### generateRandomNameOfTopic

          public static String generateRandomNameOfTopic()

      Generated random name for the KafkaTopic resource
      Returns:
        random name with additional salt

    - #### topicSnapshot

          public static String topicSnapshot​(String topicName)

      Method which return UID for specific topic
      Parameters:
        `topicName` - topic name
      Returns:
        topic UID

    - #### waitTopicHasRolled

          public static String waitTopicHasRolled​(String topicName,
                                                  String topicUid)

      Method which wait until topic has rolled form one generation to another.
      Parameters:
        `topicName` - topic name
        `topicUid` - topic UID
      Returns:
        topic new UID

    - #### waitForKafkaTopicCreation

          public static void waitForKafkaTopicCreation​(String topicName)

    - #### waitForKafkaTopicCreationByNamePrefix

          public static void waitForKafkaTopicCreationByNamePrefix​(String topicNamePrefix)

    - #### waitForKafkaTopicDeletion

          public static void waitForKafkaTopicDeletion​(String topicName)

    - #### waitForKafkaTopicPartitionChange

          public static void waitForKafkaTopicPartitionChange​(String topicName,
                                                              int partitions)

    - #### waitForKafkaTopicStatus

          public static void waitForKafkaTopicStatus​(String topicName,
                                                     Enum<?> state)

      Wait until KafkaTopic is in desired status
      Parameters:
        `topicName` - name of KafkaTopic
        `state` - desired state

    - #### waitForKafkaTopicReady

          public static void waitForKafkaTopicReady​(String topicName)

    - #### waitForKafkaTopicNotReady

          public static void waitForKafkaTopicNotReady​(String topicName)

    - #### waitForKafkaTopicsCount

          public static void waitForKafkaTopicsCount​(int topicCount,
                                                     String clusterName)