Skip to content

Commit

Permalink
MINOR: Need to split the controller bootstrap servers on ',' in list …
Browse files Browse the repository at this point in the history
…comprehenson (#17183)

Kafka Streams system tests were failing with this error:

Failed to parse host name from entry 3001@d for the configuration controller.quorum.voters.  Each entry should be in the form `{id}@{host}:{port}`.

The cause is that in kafka.py line 876, we create a delimited string from a list comprehension, but the input is a string itself, so each character gets appended vs. the bootstrap server string of host:port. To fix this, this PR adds split(',') to controller_quorum_bootstrap_servers. Note that this only applies when dynamicRaftQuorum=False

Reviewers: Alyssa Huang <[email protected]>, Chia-Ping Tsai <[email protected]>
  • Loading branch information
bbejeck authored Sep 15, 2024
1 parent 6744a71 commit e1f11c6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tests/kafkatest/services/kafka/kafka.py
Original file line number Diff line number Diff line change
Expand Up @@ -875,7 +875,7 @@ def start_node(self, node, timeout_sec=60, **kwargs):
else:
self.controller_quorum_voters = ','.join(["%s@%s" % (self.controller_quorum.idx(node) + first_node_id - 1,
bootstrap_server)
for bootstrap_server in controller_quorum_bootstrap_servers])
for bootstrap_server in controller_quorum_bootstrap_servers.split(',')])
# define controller.listener.names
self.controller_listener_names = ','.join(self.controller_listener_name_list(node))
# define sasl.mechanism.controller.protocol to match the isolated quorum if one exists
Expand Down

0 comments on commit e1f11c6

Please sign in to comment.