Reduce batch time in producer integration test (speedup test)
This commit is contained in:
@@ -398,7 +398,10 @@ class TestKafkaProducerIntegration(KafkaIntegrationTestCase):
|
|||||||
partition = self.client.get_partition_ids_for_topic(self.topic)[0]
|
partition = self.client.get_partition_ids_for_topic(self.topic)[0]
|
||||||
start_offset = self.current_offset(self.topic, partition)
|
start_offset = self.current_offset(self.topic, partition)
|
||||||
|
|
||||||
producer = KeyedProducer(self.client, partitioner = RoundRobinPartitioner, async=True)
|
producer = KeyedProducer(self.client,
|
||||||
|
partitioner=RoundRobinPartitioner,
|
||||||
|
async=True,
|
||||||
|
batch_send_every_t=1)
|
||||||
|
|
||||||
resp = producer.send_messages(self.topic, self.key("key1"), self.msg("one"))
|
resp = producer.send_messages(self.topic, self.key("key1"), self.msg("one"))
|
||||||
self.assertEqual(len(resp), 0)
|
self.assertEqual(len(resp), 0)
|
||||||
|
|||||||
Reference in New Issue
Block a user