Yolean/kubernetes-kafka

How do you suggest creating topics on startup, thank you

meirhazonAnyVision opened this issue · 3 comments

Hello,
Using your great solution what would be the best way for creating topics on startup?
Thanks so much,
Meir

Kubernetes Jobs will by default retry until they succeed. There's an example of how to use kafka' shell scripts at https://github.com/Yolean/kubernetes-kafka/blob/v5.1.0/kafka/test/produce-consume.yml#L60. It's admittedly a resource intensive restart, with a full JVM, but ok for some automation.

I'm curious about the advantages of choosing Kubernetes Jobs over InitContainers in the StatefulSet. Could you explain?

mjeri commented

@SoerenHenning Isn't it the case that the Kafka server should be running before we can configure topics? Correct me if I'm wrong please.