jiangpengcheng commented on issue #17776:
URL: https://github.com/apache/pulsar/issues/17776#issuecomment-1778447582

   msg which has an error will be nacked and then retried, functions even with 
the `--retain-ordering` will not wait for this failed msg to be succeeded but 
will continue to process other messages
   
   so the `--retain-ordering` just ensures the order of msgs that can be 
processed successfully
   
   you can try with a java function too:
   
   
   ```
   package org.example;
   
   import java.util.function.Function;
   
   public class JavaNativeExclamationFunction implements Function<String, 
String> {
       @Override
       public String apply(String input) {
           if (input.contains("B")) {
               throw new RuntimeException("fail on B");
           }
           return String.format("%s!", input);
       }
   }
   ```


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