What is the correct way to catch all exceptions that is unhandled in service fabric ReceiveReminderAsync

Poul K. Sørensen

Is there anyway to hook into service fabric to catch those exceptions that might happen in ReceiveReminderAsync and log them out for debugging or do we as developers need to make sure we have try/catch within the ReceiveReminderAsync to log the exceptions?

Would be nice if one could get and handle all unhandled exceptions that was not handled by user code.

Vaclav Turecek

There is no hook for unhandled exceptions. The actor framework catches unhandled exceptions from actor methods so that the host process doesn't crash. If the actor method is called by a client (from ActorProxy), the exception is sent to the caller. If the actor method is a reminder or timer method, the exception is simply caught and the actor continues to run. So if you want to handle your exceptions, use a try..catch like you normally would.

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at


Login to comment


TOP Ranking