KAFKA-18341: Remove KafkaConfig GroupType config check and warn log (#18320)

As ZK mode is being removed for 4.0, we don't need this check anymore.

Reviewers: David Jacot <djacot@confluent.io>
This commit is contained in:
Ken Huang 2025-01-13 18:42:17 +08:00 committed by GitHub
parent 273719227e
commit 0b60d08d23
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 4 additions and 6 deletions

View File

@ -435,14 +435,12 @@ class KafkaConfig private(doLog: Boolean, val props: util.Map[_, _])
if (!protocols.contains(GroupType.CLASSIC)) { if (!protocols.contains(GroupType.CLASSIC)) {
throw new ConfigException(s"Disabling the '${GroupType.CLASSIC}' protocol is not supported.") throw new ConfigException(s"Disabling the '${GroupType.CLASSIC}' protocol is not supported.")
} }
if (protocols.contains(GroupType.CONSUMER)) { if (protocols.contains(GroupType.CONSUMER) && !isNewGroupCoordinatorEnabled) {
if (processRoles.isEmpty || !isNewGroupCoordinatorEnabled) { warn(s"The new '${GroupType.CONSUMER}' rebalance protocol is only supported with the new group coordinator.")
warn(s"The new '${GroupType.CONSUMER}' rebalance protocol is only supported in KRaft cluster with the new group coordinator.")
}
} }
if (protocols.contains(GroupType.SHARE)) { if (protocols.contains(GroupType.SHARE)) {
if (processRoles.isEmpty || !isNewGroupCoordinatorEnabled) { if (!isNewGroupCoordinatorEnabled) {
warn(s"The new '${GroupType.SHARE}' rebalance protocol is only supported in KRaft cluster with the new group coordinator.") warn(s"The new '${GroupType.SHARE}' rebalance protocol is only supported with the new group coordinator.")
} }
warn(s"Share groups and the new '${GroupType.SHARE}' rebalance protocol are enabled. " + warn(s"Share groups and the new '${GroupType.SHARE}' rebalance protocol are enabled. " +
"This is part of the early access of KIP-932 and MUST NOT be used in production.") "This is part of the early access of KIP-932 and MUST NOT be used in production.")