Copilot commented on code in PR #20005:
URL: https://github.com/apache/kafka/pull/20005#discussion_r2158510091
##########
tests/kafkatest/tests/streams/streams_broker_bounce_test.py:
##########
@@ -112,8 +112,8 @@ def __init__(self, test_context):
'configs': {"min.insync.replicas": 2} },
'tagg' : { 'partitions': self.partitions, 'replication-factor':
self.replication,
'configs': {"min.insync.replicas": 2} },
- '__consumer_offsets' : { 'partitions': 50, 'replication-factor':
self.replication,
- 'configs': {"min.insync.replicas": 2} }
+ '__consumer_offsets' : { 'partitions': self.partitions,
'replication-factor': self.replication,
Review Comment:
Changing the partitions from a hardcoded value (50) to self.partitions helps
avoid inconsistencies across brokers. This resolves a bug where brokers could
have a different understanding of the number of partitions.
##########
tests/kafkatest/tests/streams/streams_broker_bounce_test.py:
##########
@@ -285,7 +288,7 @@ def test_all_brokers_bounce(self, failure_mode,
num_failures, metadata_quorum, g
# Set min.insync.replicas to 1 because in the last stage of the test
there is only one broker left.
# Otherwise the last offset commit will never succeed and time out and
potentially take longer as
# duration passed to the close method of the Kafka Streams client.
- self.topics['__consumer_offsets'] = { 'partitions': 50,
'replication-factor': self.replication,
+ self.topics['__consumer_offsets'] = { 'partitions': self.partitions,
'replication-factor': self.replication,
Review Comment:
Replacing the hardcoded partition count with self.partitions in the test
configuration eliminates the risk of conflicting group coordinators during
broker bounce.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]