Skip to content

Instantly share code, notes, and snippets.

@yemrekeskin
Created September 23, 2013 13:35
Show Gist options
  • Save yemrekeskin/6670482 to your computer and use it in GitHub Desktop.
Save yemrekeskin/6670482 to your computer and use it in GitHub Desktop.
Helper.cs for AppPoolController Class
public class SystemCriticalException
: Exception
{
public SystemCriticalException() { }
public SystemCriticalException(string message)
: base(message) { }
public SystemCriticalException(string message, Exception inner)
: base(message, inner) { }
}
internal class CriticalExceptionLogger
{
/// <summary>
/// Log4net log handle.
/// </summary>
readonly static ILog log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
internal static void Log(Exception exception, string format, params object[] args)
{
string message = string.Format(format, args);
log.Fatal(message, exception);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment