Hangleton commented on code in PR #13511: URL: https://github.com/apache/kafka/pull/13511#discussion_r1168339962
########## core/src/test/scala/unit/kafka/coordinator/group/GroupMetadataManagerTest.scala: ########## @@ -640,8 +640,14 @@ class GroupMetadataManagerTest { val offsetCommitRecords = createCommittedOffsetRecords(committedOffsets) val memberId = "98098230493" val groupMetadataRecord = buildStableGroupRecordWithMember(generation, protocolType, protocol, memberId) + + // Should ignore unknown record + val unknownKey = new org.apache.kafka.coordinator.group.generated.GroupMetadataKey() + val unknownMessage = MessageUtil.toVersionPrefixedBytes(Short.MaxValue, unknownKey) + val unknownRecord = new SimpleRecord(unknownMessage, unknownMessage) + val records = MemoryRecords.withRecords(startOffset, CompressionType.NONE, - (offsetCommitRecords ++ Seq(groupMetadataRecord)).toArray: _*) + (offsetCommitRecords ++ Seq(unknownRecord) ++ Seq(groupMetadataRecord)).toArray: _*) Review Comment: Nit: maybe we could have a test with a few more unknown records in the list with different version. -- 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: jira-unsubscr...@kafka.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org