in src/main/java/com/epam/digital/data/platform/starter/actuator/readinessprobe/KafkaHealthCheckTopicCreator.java [59:68]
private boolean isTopicExist(AdminClient adminClient) {
try {
return adminClient.listTopics()
.names()
.get(TOPIC_CREATION_TIMEOUT, TimeUnit.SECONDS)
.contains(KAFKA_HEALTH_TOPIC);
} catch (Exception e) {
throw new CreateKafkaTopicException("Failed to retrieve existing kafka topics", e);
}
}