Skip to content

Commit

Permalink
[incubator/kafka] fix wrapper scripts in notes (helm#15012)
Browse files Browse the repository at this point in the history
* Fix wrapper scripts in notes

Signed-off-by: Miiro Juuso <[email protected]>

* Bump chart version

Signed-off-by: Miiro Juuso <[email protected]>
  • Loading branch information
mjuuso authored and davidkarlsen committed Jul 3, 2019
1 parent 9852a8e commit 0379943
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion incubator/kafka/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: v1
description: Apache Kafka is publish-subscribe messaging rethought as a distributed
commit log.
name: kafka
version: 0.16.0
version: 0.16.1
appVersion: 5.0.1
keywords:
- kafka
Expand Down
8 changes: 4 additions & 4 deletions incubator/kafka/templates/NOTES.txt
Original file line number Diff line number Diff line change
Expand Up @@ -19,20 +19,20 @@ You can connect to Kafka by running a simple pod in the K8s cluster like this wi
Once you have the testclient pod above running, you can list all kafka
topics with:

kubectl -n {{ .Release.Namespace }} exec testclient -- /opt/kafka/bin/kafka-topics.sh --zookeeper {{ .Release.Name }}-zookeeper:2181 --list
kubectl -n {{ .Release.Namespace }} exec testclient -- kafka-topics --zookeeper {{ .Release.Name }}-zookeeper:2181 --list

To create a new topic:

kubectl -n {{ .Release.Namespace }} exec testclient -- /opt/kafka/bin/kafka-topics.sh --zookeeper {{ .Release.Name }}-zookeeper:2181 --topic test1 --create --partitions 1 --replication-factor 1
kubectl -n {{ .Release.Namespace }} exec testclient -- kafka-topics --zookeeper {{ .Release.Name }}-zookeeper:2181 --topic test1 --create --partitions 1 --replication-factor 1

To listen for messages on a topic:

kubectl -n {{ .Release.Namespace }} exec -ti testclient -- /opt/kafka/bin/kafka-console-consumer.sh --bootstrap-server {{ include "kafka.fullname" . }}:9092 --topic test1 --from-beginning
kubectl -n {{ .Release.Namespace }} exec -ti testclient -- kafka-console-consumer --bootstrap-server {{ include "kafka.fullname" . }}:9092 --topic test1 --from-beginning

To stop the listener session above press: Ctrl+C

To start an interactive message producer session:
kubectl -n {{ .Release.Namespace }} exec -ti testclient -- /opt/kafka/bin/kafka-console-producer.sh --broker-list {{ include "kafka.fullname" . }}-headless:9092 --topic test1
kubectl -n {{ .Release.Namespace }} exec -ti testclient -- kafka-console-producer --broker-list {{ include "kafka.fullname" . }}-headless:9092 --topic test1

To create a message in the above session, simply type the message and press "enter"
To end the producer session try: Ctrl+C
Expand Down

0 comments on commit 0379943

Please sign in to comment.