babumahesh commented on PR #10665:
URL: https://github.com/apache/gravitino/pull/10665#issuecomment-4201677626

   @justinmclean @yuqi1129 
   
   I have enhanced the `dispatchEvent()` function to explicitly handle 
`FailureEvent`s by catching and swallowing listener exceptions while logging 
them appropriately.
   
   For all other event types, the existing behavior remains unchanged:
   - `PreEvent` continues to propagate `ForbiddenException` for control-flow 
decisions.
   - Regular `Event` continues to propagate listener exceptions as before.
   
   An alternative approach would have been to introduce a separate 
`dispatchFailureEvent()` or  `dispatchEventSafe()` method and update all 
dispatcher classes to use it for failure flows. However, I chose to handle this 
within `dispatchEvent()` itself to avoid changes at the call sites and keep the 
integration simpler.


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