Skip to content

Commit

Permalink
retrieve kafka metadata method
Browse files Browse the repository at this point in the history
  • Loading branch information
nasark committed May 3, 2024
1 parent 3f7db72 commit 54bfcf3
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions lib/manageiq/messaging/kafka/client.rb
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down

0 comments on commit 54bfcf3

Please sign in to comment.