How to delete Topics in Kafka
Deleting Kafka Topics using Kowl
less than a minute
This will delete all the data inside the Topic. If the data is not yet processed, it will be lost forever !
Finding old Topics
If you need to find out, if your Topic has unprocessed data, check the Consumers inside Kowl. If there is any with Lag, it still has unprocessed data.
Using Kowl for inspecting messages
Instructions
Allowing Kafka to delete Topics
By default Kafka is configured to not allow Topic deletion.
Therefore you need to execute the following steps first:
Open your Cluster inside Lens
Edit Kafka’s StatefulSet

Search for KAFKA_CFG_DELETE_TOPIC_ENABLE and set it’s value to ‘true’

Click “Save & Exit”
On the Workloads → Pods page, you can see that Kafka is now restarting to load the new Config.
After it has restarted you can go into Kowl and your mouse over a Topic.
If will show you a Trashbin symbol, click it to delete a Topic

After you confirmed deletion, there is no way to get any unprocessed Data back

Kowl will also now show a success Message
If the Topic comes back, you still have a producer and Kafka automatically re-created it.
Last modified February 17, 2023: update (#208) (ea731fc)