From 0d7a1d58a4ec4b30fdba3f1269821780230b04f2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Ma=C5=9Blanka?= Date: Mon, 15 Jul 2024 12:09:03 +0000 Subject: [PATCH] k/group: do not log ignoring raft configuration batches MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Raft configuration batches are integral part of Raft managed log. Emitting warn log message that Redpanda ignore them when parsing consumer group state machine data may be confusing as this is expected and not something that the users should worry about. Signed-off-by: Michał Maślanka --- src/v/kafka/server/group_data_parser.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/v/kafka/server/group_data_parser.h b/src/v/kafka/server/group_data_parser.h index 29c6f997ae24..753cf42cca65 100644 --- a/src/v/kafka/server/group_data_parser.h +++ b/src/v/kafka/server/group_data_parser.h @@ -16,6 +16,7 @@ #include "kafka/server/group_metadata.h" #include "kafka/server/logger.h" #include "model/record.h" +#include "model/record_batch_types.h" template T parse_tx_batch(const model::record_batch& batch, int8_t version) { @@ -81,6 +82,10 @@ class group_data_parser { if (b.header().type == model::record_batch_type::raft_data) { return handle_raft_data(std::move(b)); } + // silently ignore raft configuration. + if (b.header().type == model::record_batch_type::raft_configuration) { + return ss::now(); + } if (b.header().type == model::record_batch_type::group_prepare_tx) { auto data = parse_tx_batch( b, group::prepared_tx_record_version);