chia7712 commented on code in PR #20031: URL: https://github.com/apache/kafka/pull/20031#discussion_r2164850095
########## group-coordinator/src/main/java/org/apache/kafka/coordinator/group/GroupCoordinatorService.java: ########## @@ -540,6 +541,26 @@ private static void throwIfStreamsGroupHeartbeatRequestIsInvalid( } } + /** + * Validates the request. Specifically, throws if any not-yet-supported features are used. + * + * @param request The request to validate. + * @throws InvalidRequestException if the request is not valid. + */ + private static void throwIfStreamsGroupHeartbeatRequestIsUsingUnsupportedFeatures( + StreamsGroupHeartbeatRequestData request + ) throws InvalidRequestException { + throwIfNotNull(request.instanceId(), "Static membership is not yet supported."); + throwIfNotNull(request.taskOffsets(), "TaskOffsets are not supported yet."); + throwIfNotNull(request.taskEndOffsets(), "TaskEndOffsets are not supported yet."); + throwIfNotNullOrEmpty(request.warmupTasks(), "WarmupTasks are not supported yet."); + if (request.topology() != null) { + for (StreamsGroupHeartbeatRequestData.Subtopology subtopology : request.topology().subtopologies()) { + throwIfNotEmptyCollection(subtopology.sourceTopicRegex(), "Regular expressions for source topics is not supported yet."); Review Comment: nit: `is` -> `are` -- 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