walterddr commented on code in PR #8017:
URL: https://github.com/apache/pinot/pull/8017#discussion_r849988119
##########
pinot-plugins/pinot-stream-ingestion/pinot-pulsar/src/test/java/org/apache/pinot/plugin/stream/pulsar/PulsarConsumerTest.java:
##########
@@ -107,10 +117,37 @@ public int choosePartition(Message<?> msg, TopicMetadata
metadata) {
_partitionToFirstMessageIdMap.put(partition, messageId);
}
}
+
+ producer.flush();
}
}
- public StreamConfig getStreamConfig() {
+ public void publishRecordsBatch()
+ throws Exception {
+ for (int p = 0; p < NUM_PARTITION; p++) {
+ final int partition = p;
+ Producer<String> producer =
+
_pulsarClient.newProducer(Schema.STRING).topic(TEST_TOPIC_BATCH).messageRouter(new
MessageRouter() {
+ @Override
+ public int choosePartition(Message<?> msg, TopicMetadata metadata)
{
+ return partition;
+ }
+ }).batchingMaxMessages(BATCH_SIZE).batchingMaxPublishDelay(1,
TimeUnit.SECONDS).create();
Review Comment:
any chance this is related to recent flakiness in #8537 ?
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]