Skip to content

Instantly share code, notes, and snippets.

@EliFuzz
Created July 3, 2023 05:04
Show Gist options
  • Save EliFuzz/ec0b3d2df4be6aad90056513e6aff05c to your computer and use it in GitHub Desktop.
Save EliFuzz/ec0b3d2df4be6aad90056513e6aff05c to your computer and use it in GitHub Desktop.
Common xk6-kafka extension functions for Kafka
Function Description
consume(reader, limit) Consume messages from the Kafka server
createTopic(address, topic) Create a new topic
listTopics(address) Return a unique set of topics
produce(writer, messages) Produce messages to the Kafka server
reader(brokers, topic) Instantiate a new Reader instance
writer(brokers, topic) Instantiate a new Writer instance
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment