diff --git a/tests/kafkatest/services/console_consumer.py b/tests/kafkatest/services/console_consumer.py index 4df42b79e7e08..2124fc4efea37 100644 --- a/tests/kafkatest/services/console_consumer.py +++ b/tests/kafkatest/services/console_consumer.py @@ -135,7 +135,6 @@ def __init__(self, context, num_nodes, kafka, topic, group_id="test-consumer-gro self.messages_consumed = {idx: [] for idx in range(1, num_nodes + 1)} self.client_id = client_id self.print_key = print_key - self.log_values = True if version == TRUNK else False self.log_level = "TRACE" def prop_file(self, node): @@ -192,7 +191,8 @@ def start_cmd(self, node): if self.print_key: cmd += " --property print.key=true" - if self.log_values: + # LoggingMessageFormatter was introduced in 0.9.0.0 + if node.version > LATEST_0_8_2: cmd+=" --formatter kafka.tools.LoggingMessageFormatter" cmd += " 2>> %(stderr)s | tee -a %(stdout)s &" % args