private void OnTime(object state) { mTimer.Change(-1, -1); try { if (mCurrentTest != null) { Loger.Process(LogType.DEBUG, mCurrentTest.StatisticalInfo.ToString()); Network.StatisticalReport resport = new Network.StatisticalReport(); resport.UnitTest = Name; resport.Info = mCurrentTest.StatisticalInfo; mClient.Send(resport); Network.ReportDelayTimes reporttimes = new ReportDelayTimes(); reporttimes.UnitTest = this.Name; reporttimes.Times = mCurrentTest.GetDelayTimes(); mClient.Send(reporttimes); Network.ReportErrors reportErrors = new ReportErrors(); reportErrors.UnitTest = this.Name; reportErrors.Errors = mCurrentTest.GetErrors(); mClient.Send(reportErrors); } } catch (Exception e_) { } finally { mTimer.Change(1000, 1000); } }
public void OnProcessReport(Network.StatisticalReport report) { Process.TestProcessAgent agent = AgentManager.GetAgent(report.UnitTest); agent.StatisticalInfo = report.Info; Loger.Process(LogType.INFO, "statistical report from {0}", report.UnitTest); report.Node = this.Name; mServerClient.Send(report); }