m1a2st commented on code in PR #18196: URL: https://github.com/apache/kafka/pull/18196#discussion_r1944593893
########## core/src/main/scala/kafka/server/MetadataCache.scala: ########## @@ -144,4 +149,95 @@ object MetadataCache { ): KRaftMetadataCache = { new KRaftMetadataCache(brokerId, kraftVersionSupplier) } + + def toCluster(clusterId: String, image: MetadataImage): Cluster = { + val brokerToNodes = new util.HashMap[Integer, java.util.List[Node]] + image.cluster().brokers() + .values().stream() + .filter(broker => !broker.fenced()) Review Comment: Yes, I want to keep this because we need to convert it to a Java future. ########## core/src/test/scala/integration/kafka/api/CustomQuotaCallbackTest.scala: ########## @@ -87,11 +90,25 @@ class CustomQuotaCallbackTest extends IntegrationTestHarness with SaslSetup { override def configureSecurityBeforeServersStart(testInfo: TestInfo): Unit = { super.configureSecurityBeforeServersStart(testInfo) + } + + override def configureSecurityAfterServersStart(): Unit = { + super.configureSecurityAfterServersStart() createScramCredentials(createAdminClient(), JaasTestUtils.KAFKA_SCRAM_ADMIN, JaasTestUtils.KAFKA_SCRAM_ADMIN_PASSWORD) } + override def addFormatterSettings(formatter: Formatter): Unit = { + formatter.setScramArguments( + List(s"SCRAM-SHA-256=[name=${JaasTestUtils.KAFKA_SCRAM_ADMIN},password=${JaasTestUtils.KAFKA_SCRAM_ADMIN_PASSWORD}]").asJava) + } + + override def createPrivilegedAdminClient() = { + createAdminClient(bootstrapServers(), securityProtocol, trustStoreFile, clientSaslProperties, + kafkaClientSaslMechanism, JaasTestUtils.KAFKA_SCRAM_ADMIN, JaasTestUtils.KAFKA_SCRAM_ADMIN_PASSWORD) + } + @ParameterizedTest(name = TestInfoUtils.TestWithParameterizedQuorumAndGroupProtocolNames) - @MethodSource(Array("getTestQuorumAndGroupProtocolParametersClassicGroupProtocolOnly_ZK_implicit")) + @MethodSource(Array("getTestQuorumAndGroupProtocolParametersClassicGroupProtocolOnly")) Review Comment: The main reason is that this test targets the server, not the consumer. Therefore, I didn't test different consumers separately, but I will address this. -- 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