Logging Exceptions In-Depth

Exceptions are safeguards to deal with any unexpected or exceptional situations and logging them helps finding the root cause of issues during runtime. Significance of logging becomes even more critical on production where resources to debug are very scarce. So, to have in-depth information on what gone wrong and where play a very important role and helps troubleshooting/resolving the issues effectively.

Below is the C# implementation to log the in-depth information about the exception raised during runtime:

Application_Error() would be the method in Global.asax file of your web application.

Cheers!!