hachikuji commented on code in PR #14774: URL: https://github.com/apache/kafka/pull/14774#discussion_r1424500490
########## core/src/main/scala/kafka/coordinator/group/GroupMetadataManager.scala: ########## @@ -1352,6 +1360,28 @@ object GroupMetadataManager { "%X".format(BigInt(1, bytes)) } + def maybeConvertError(error: Errors) : Errors = { + error match { + case Errors.UNKNOWN_TOPIC_OR_PARTITION + | Errors.NOT_ENOUGH_REPLICAS + | Errors.NOT_ENOUGH_REPLICAS_AFTER_APPEND => + Errors.COORDINATOR_NOT_AVAILABLE + + case Errors.NOT_LEADER_OR_FOLLOWER + | Errors.KAFKA_STORAGE_ERROR => + Errors.NOT_COORDINATOR + + case Errors.MESSAGE_TOO_LARGE + | Errors.RECORD_LIST_TOO_LARGE + | Errors.INVALID_FETCH_SIZE => + Errors.INVALID_COMMIT_OFFSET_SIZE Review Comment: Right. I would think UNKNOWN_SERVER_ERROR or something like that would be more appropriate for a case like this. It doesn't say anything about the size of the offset commit. -- 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