equanz commented on a change in pull request #10279:
URL: https://github.com/apache/pulsar/pull/10279#discussion_r700932705



##########
File path: 
pulsar-broker/src/test/java/org/apache/pulsar/broker/service/PersistentTopicE2ETest.java
##########
@@ -739,10 +740,14 @@ public void testConcurrentlyDeleteSchema() throws 
Exception {
         admin.namespaces().createNamespace("prop/ns-delete-schema", 3);
         admin.topics().createPartitionedTopic(topic, partitions);
 
-        Producer producer = pulsarClient
+        Producer<Schemas.BytesRecord> producer = pulsarClient
                 .newProducer(Schema.JSON(Schemas.BytesRecord.class))
                 .topic(topic)
+                .enableBatching(false)

Review comment:
       In this PR, I'll introduce internal producer lazy-loading feature. When 
internal producer is elected by MessageRouter and isn't created yet, create it 
lazily.
   
https://github.com/equanz/pulsar/blob/844cca7cf84b76b7d27f12de4dbf36e23cbf29e9/pulsar-client/src/main/java/org/apache/pulsar/client/impl/PartitionedProducerImpl.java#L193-L211
   Therefore, if it isn't elected by MessageRouter, doesn't create producer and 
also topic in this test case.
   
   For above reason, we should add `Producer#send`.
   
   When enableBatching, not easier to elect all of internal producers at client 
side.
   
https://github.com/apache/pulsar/blob/fe4cd09c297f7ab2a892a6c81bb0998e7ee737f2/pulsar-client/src/main/java/org/apache/pulsar/client/impl/RoundRobinPartitionMessageRouterImpl.java#L82-L84
   




-- 
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]


Reply via email to