private static string FormatExceptionMessage(Exception exception, string fmt, object[] vars) { // Simple exception formatting: for a more comprehensive version see // http://code.msdn.microsoft.com/windowsazure/Fix-It-app-for-Building-cdd80df4 var msg = string.Format(fmt, vars); var msgfinal = string.Format(";Exception Details={0}", FormatUtils.FormatException(exception, includeContext: true)); return(msg + msgfinal); }
public void TraceApi(string componentName, string method, TimeSpan timespan, string properties) { var msg = FormatUtils.FormatTraceApi(componentName, method, timespan, properties); Trace.TraceInformation(msg); }
public void Error(Exception exception, string fmt, params object[] vars) { Trace.TraceError(FormatUtils.FormatExceptionStackTrace(exception), fmt, vars); }
public void Error(Exception exception) { Trace.TraceError(FormatUtils.FormatExceptionStackTrace(exception)); }