示例#1
0
 public static void LogInfo(string info, string type)
 {
     try
     {
         LogJob job = new LogJob(info, type);
         ThreadPool.QueueUserWorkItem(f => job.DoWork());
     }
     catch (Exception)
     { }
 }
示例#2
0
 public static void LogInfo(string info, string type)
 {
     try
     {
         LogJob job = new LogJob(info, type);
         System.Threading.Thread worker = new System.Threading.Thread(job.DoWork);
         worker.Start();
     }
     catch(Exception)
     {}
 }
示例#3
0
 public static void LogInfo(string info, string type)
 {
     try
     {
         LogJob job = new LogJob(info, type);
         System.Threading.Thread worker = new System.Threading.Thread(job.DoWork);
         worker.Start();
     }
     catch (Exception)
     {}
 }
示例#4
0
 public static void LogInfo(string info, Exception ex, string type)
 {
     try
     {
         info += " ";
         if (ex != null)
         {
             if (ex.InnerException != null)
             {
                 info += ex.InnerException.Message + " " + ex.InnerException.StackTrace;
             }
             else
             {
                 info += ex.Message + " " + ex.StackTrace;
             }
         }
         LogJob job = new LogJob(info, type);
         HostingEnvironment.QueueBackgroundWorkItem(f => job.DoWork());
     }
     catch (Exception)
     { }
 }
示例#5
0
 public static void LogInfo(string info, Exception ex, string type)
 {
     try
     {
         info += " ";
         if (ex != null)
         {
             if (ex.InnerException != null)
             {
                 info += ex.InnerException.Message + " " + ex.InnerException.StackTrace;
             }
             else
             {
                 info += ex.Message + " " + ex.StackTrace;
             }
         }
         LogJob job = new LogJob(info, type);
         HostingEnvironment.QueueBackgroundWorkItem(f => job.DoWork());
     }
     catch (Exception)
     { }
 }