Skip to content

Commit

Permalink
Changes replication-factor for test topics to 2 ...
Browse files Browse the repository at this point in the history
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.
  • Loading branch information
solsson committed Nov 5, 2017
1 parent 14ec1ad commit 3fad8bf
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 3 deletions.
26 changes: 25 additions & 1 deletion test/basic-produce-consume.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
3 changes: 1 addition & 2 deletions test/basic-with-kafkacat.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ data:
kafkacat -C -b $BOOTSTRAP -t test-basic-with-kafkacat -o -1 -e | grep $unique
exit 0
---
apiVersion: batch/v1
kind: Job
Expand All @@ -47,7 +46,7 @@ spec:
- --partitions
- "1"
- --replication-factor
- "1"
- "2"
restartPolicy: Never
---
apiVersion: apps/v1beta1
Expand Down

0 comments on commit 3fad8bf

Please sign in to comment.