diff --git a/lib/manageiq/messaging/kafka/client.rb b/lib/manageiq/messaging/kafka/client.rb index 77eccb5..f99f78a 100644 --- a/lib/manageiq/messaging/kafka/client.rb +++ b/lib/manageiq/messaging/kafka/client.rb @@ -65,8 +65,7 @@ def close # list all topics def topics - native_kafka = producer.instance_variable_get(:@native_kafka) - Rdkafka::Metadata.new(native_kafka).topics.collect { |topic| topic[:topic_name] } + kafka_client.admin.metadata.topics.map { |topic| topic[:topic_name] } end private