Skip to content

A bash script to remove messages in kafka topics by lowering the retention before upping the retention back to the default value or configured value.

License

MIT, MIT licenses found

Licenses found

MIT
LICENSE
MIT
LICENSE.md
Notifications You must be signed in to change notification settings

nshumoogum/drain-kafka-topics

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

drain-kafka-topics

A bash script to remove messages in kafka topics by lowering the retention before upping the retention back to the default value or configured value.

Installation

  • Install homebrew by running the following command:

ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" < /dev/null 2> /dev/null

Distributed streaming platform

  • Run brew install zookeeper
  • Run brew install kafka
  • Run brew services start zookeeper
  • Run brew services start kafka

Running script

Once messages have been added to kafka topics, one can drain all topics of all messages with the following command:

./drain-kafka-topics

otherwise it is possible to drain chosen topics with:

./drain-kafka-topics -t <topic1>,<topic2>

For more commands use the help (-h) flag, like so:

./drain-kafka-topics -h

License

See LICENSE for details.

Contributing

See CONTRIBUTING for details.


Thanks to

About

A bash script to remove messages in kafka topics by lowering the retention before upping the retention back to the default value or configured value.

Resources

License

MIT, MIT licenses found

Licenses found

MIT
LICENSE
MIT
LICENSE.md

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages