tinaselenge commented on code in PR #14693: URL: https://github.com/apache/kafka/pull/14693#discussion_r1407647882
########## core/src/test/scala/unit/kafka/server/LogRecoveryTest.scala: ########## @@ -78,15 +84,20 @@ class LogRecoveryTest extends QuorumTestHarness { override def setUp(testInfo: TestInfo): Unit = { super.setUp(testInfo) - configs = TestUtils.createBrokerConfigs(2, zkConnect, enableControlledShutdown = false).map(KafkaConfig.fromProps(_, overridingProps)) + configs = TestUtils.createBrokerConfigs(2, zkConnectOrNull, enableControlledShutdown = false).map(KafkaConfig.fromProps(_, overridingProps)) // start both servers - server1 = TestUtils.createServer(configProps1) - server2 = TestUtils.createServer(configProps2) + server1 = createBroker(configProps1) + server2 = createBroker(configProps2) servers = List(server1, server2) // create topic with 1 partition, 2 replicas, one on each broker - createTopic(zkClient, topic, partitionReplicaAssignment = Map(0 -> Seq(0,1)), servers = servers) + if (isKRaftTest()) { + admin = createAdminClient(servers, ListenerName.forSecurityProtocol(SecurityProtocol.PLAINTEXT)) + createTopicWithAdmin(admin, topic, servers, 2, replicaAssignment = Map(0 -> Seq(0, 1))) + } else { + createTopic(zkClient, topic, partitionReplicaAssignment = Map(0 -> Seq(0, 1)), servers = servers) + } Review Comment: good point. I have addressed this now. Thank you. -- 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