aboutsummaryrefslogtreecommitdiff
path: root/test/basic-produce-consume.yml
diff options
context:
space:
mode:
authorStaffan Olsson <staffan@repos.se>2017-11-05 11:31:35 +0100
committerStaffan Olsson <staffan@repos.se>2017-11-05 11:33:07 +0100
commit3fad8bf507bb6e6aabc49f8961e3948b9dd3cf4d (patch)
tree4621b73c932d891f2eda79e052f607395bf77548 /test/basic-produce-consume.yml
parent14ec1ad9aba8baae220a7ce0db5055c3ea2bbaf6 (diff)
downloadkubernetes-kafka-3fad8bf507bb6e6aabc49f8961e3948b9dd3cf4d.tar.gz
kubernetes-kafka-3fad8bf507bb6e6aabc49f8961e3948b9dd3cf4d.tar.bz2
kubernetes-kafka-3fad8bf507bb6e6aabc49f8961e3948b9dd3cf4d.zip
Changes replication-factor for test topics to 2 ...
because 1 is useless, as even a normal reschedule of the broker pod that happens to own the replica+partition will disrupt clients. Testing with replication-factor=2 but using 3 for production topics is sensible because we can test with 3 brokers how replication performs.
Diffstat (limited to 'test/basic-produce-consume.yml')
-rw-r--r--test/basic-produce-consume.yml26
1 files changed, 25 insertions, 1 deletions
diff --git a/test/basic-produce-consume.yml b/test/basic-produce-consume.yml
index 128a00a..32ec4ec 100644
--- a/test/basic-produce-consume.yml
+++ b/test/basic-produce-consume.yml
@@ -36,7 +36,31 @@ data:
#pkill java
exit 0
-
+---
+apiVersion: batch/v1
+kind: Job
+metadata:
+ name: basic-produce-consume
+ namespace: test-kafka
+spec:
+ template:
+ spec:
+ containers:
+ - name: topic-create
+ image: solsson/kafka:1.0.0@sha256:17fdf1637426f45c93c65826670542e36b9f3394ede1cb61885c6a4befa8f72d
+ command:
+ - ./bin/kafka-topics.sh
+ - --zookeeper
+ - zookeeper.kafka.svc.cluster.local:2181
+ - --create
+ - --if-not-exists
+ - --topic
+ - test-basic-produce-consume
+ - --partitions
+ - "1"
+ - --replication-factor
+ - "2"
+ restartPolicy: Never
---
apiVersion: apps/v1beta1
kind: Deployment