test_class.declarator: NUM_BROKERS = 3
test_class.modifier: private static final
test_class.original_string: private static final int NUM_BROKERS = 3;
test_class.type: int
test_class.var_name: NUM_BROKERS
test_class.declarator: NUM_ZK = 3
test_class.modifier: private static final
test_class.original_string: private static final int NUM_ZK = 3;
test_class.type: int
test_class.var_name: NUM_ZK
test_class.declarator: DEFAULT_PARTITIONS = 2
test_class.modifier: private static final
test_class.original_string: private static final int DEFAULT_PARTITIONS = 2;
test_class.type: int
test_class.var_name: DEFAULT_PARTITIONS
test_class.declarator: DEFAULT_REPLICATION_FACTOR = 3
test_class.modifier: private static final
test_class.original_string: private static final int DEFAULT_REPLICATION_FACTOR = 3;
test_class.type: int
test_class.var_name: DEFAULT_REPLICATION_FACTOR
test_class.declarator: TIMEOUT_MS = 20000
test_class.modifier: private static final
test_class.original_string: private static final Integer TIMEOUT_MS = 20000;
test_class.type: Integer
test_class.var_name: TIMEOUT_MS
test_class.declarator: kafka
test_class.modifier: private static
test_class.original_string: private static EmbeddedKafkaCluster kafka;
test_class.type: EmbeddedKafkaCluster
test_class.var_name: kafka
test_class.declarator: topicEnsure
test_class.modifier: private static
test_class.original_string: private static TopicEnsure topicEnsure;
test_class.type: TopicEnsure
test_class.var_name: topicEnsure
test_class.file: utility-belt/src/test/java/io/confluent/admin/utils/TopicEnsureTest.java
test_class.identifier: TopicEnsureTest
test_case.body: @Test
    public void testTopicExistsForNonexistentTopic() throws Exception {
      assertFalse(topicEnsure.topicExists(simpleTopicSpec("unknown-topic"), TIMEOUT_MS));
    }
test_case.class_method_signature: TopicEnsureTest.testTopicExistsForNonexistentTopic()
test_case.full_signature: @Test public void testTopicExistsForNonexistentTopic()
test_case.identifier: testTopicExistsForNonexistentTopic
test_case.invocations: assertFalse topicExists simpleTopicSpec
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testTopicExistsForNonexistentTopic()
focal_class.declarator: adminClient
focal_class.modifier: private final
focal_class.original_string: private final AdminClient adminClient;
focal_class.type: AdminClient
focal_class.var_name: adminClient
focal_class.file: utility-belt/src/main/java/io/confluent/admin/utils/TopicEnsure.java
focal_class.identifier: TopicEnsure
focal_class.class_method_signature: TopicEnsure.TopicEnsure(Properties props)
focal_class.full_signature: public  TopicEnsure(Properties props)
focal_class.identifier: TopicEnsure
focal_class.modifiers: public
focal_class.parameters: (Properties props)
focal_class.signature:  TopicEnsure(Properties props)
focal_class.class_method_signature: TopicEnsure.createTopic(TopicSpec spec, int timeOut)
focal_class.full_signature: public boolean createTopic(TopicSpec spec, int timeOut)
focal_class.identifier: createTopic
focal_class.modifiers: public
focal_class.parameters: (TopicSpec spec, int timeOut)
focal_class.return: boolean
focal_class.signature: boolean createTopic(TopicSpec spec, int timeOut)
focal_class.class_method_signature: TopicEnsure.validateTopic(TopicSpec spec, int timeOut)
focal_class.full_signature: public boolean validateTopic(TopicSpec spec, int timeOut)
focal_class.identifier: validateTopic
focal_class.modifiers: public
focal_class.parameters: (TopicSpec spec, int timeOut)
focal_class.return: boolean
focal_class.signature: boolean validateTopic(TopicSpec spec, int timeOut)
focal_class.class_method_signature: TopicEnsure.topicExists(TopicSpec spec, Integer timeOut)
focal_class.full_signature: public boolean topicExists(TopicSpec spec, Integer timeOut)
focal_class.identifier: topicExists
focal_class.modifiers: public
focal_class.parameters: (TopicSpec spec, Integer timeOut)
focal_class.return: boolean
focal_class.signature: boolean topicExists(TopicSpec spec, Integer timeOut)
focal_method.body: public boolean topicExists(TopicSpec spec, Integer timeOut) throws Exception {
      try {
        DescribeTopicsResult topicDescribeResult = adminClient.describeTopics(
            Collections.singletonList(spec.name()), new DescribeTopicsOptions().timeoutMs(timeOut)
        );
        topicDescribeResult.all().get().get(spec.name());
      } catch (ExecutionException e) {
        if (e.getCause() instanceof UnknownTopicOrPartitionException) {
          return false;
        } else {
          throw e;
        }
      }
      return true;
    }
focal_method.class_method_signature: TopicEnsure.topicExists(TopicSpec spec, Integer timeOut)
focal_method.full_signature: public boolean topicExists(TopicSpec spec, Integer timeOut)
focal_method.identifier: topicExists
focal_method.invocations: describeTopics singletonList name timeoutMs get get all name getCause
focal_method.modifiers: public
focal_method.parameters: (TopicSpec spec, Integer timeOut)
focal_method.return: boolean
focal_method.signature: boolean topicExists(TopicSpec spec, Integer timeOut)