david-streamlio opened a new pull request #10370:
URL: https://github.com/apache/pulsar/pull/10370


   Fixes #10269 
   
   ### Motivation
   When an exception is thrown inside the sendOutputMessage method of the 
JavaInstanceRunnable class, since it is inside a CompletableFuture, it gets 
"swallowed up" and not properly reported. This can result in a scenario in 
which the Pulsar Function is continuing to run and process messages, but no 
output is getting generated.
   
   ### Modifications
   Move the call to sendOutputMessage method outside of the CompletableFuture 
stages, and into the normal execution flow, which allows us to catch any 
exceptions thrown by that method.
   
   ### Verifying this change
   
   This change is a trivial rework / code cleanup without any test coverage.
   
   
   ### Does this pull request potentially affect one of the following parts:
   
     - Dependencies (does it add or upgrade a dependency): (no)
     - The public API: (no)
     - The schema: (no)
     - The default values of configurations: (no)
     - The wire protocol: (no)
     - The rest endpoints: (no)
     - The admin cli options: (no)
     - Anything that affects deployment: (no)
   
   ### Documentation
   
     - Does this pull request introduce a new feature? (no)
     - If yes, how is the feature documented? (not applicable)
     - If a feature is not applicable for documentation, explain why?  This is 
a bug fix
   


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

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to