johnjcasey commented on code in PR #22026:
URL: https://github.com/apache/beam/pull/22026#discussion_r906365733


##########
sdks/java/io/pulsar/src/main/java/org/apache/beam/sdk/io/pulsar/WriteToPulsarDoFn.java:
##########
@@ -45,12 +54,48 @@ public void setup() throws PulsarClientException {
 
   @ProcessElement
   public void processElement(@Element byte[] messageToSend) throws Exception {
-    producer.send(messageToSend);
+    producer.sendAsync(messageToSend)

Review Comment:
   Is there any concern of data loss here? Typically Beam is supposed to handle 
any threading or async itself. I'm thinking of the case where async is delayed, 
and Beam thinks a given element is completed, but it hasn't actually been sent 
to pulsar.



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