private void InitHeartBeatTimer() { DateTime start = DateTime.Now.AddSeconds(1); TimeSpan interval = TimeSpan.FromMilliseconds(ConfigurationManager.HeartBeatInterval); heartBeatRuntime = AsyncTaskExecuter.ExecuteIntervalTask(start, interval, SendHeartBeat, ReceivedHeartBeatResponse); }
public void startUpdateDaemon() { DateTime StartTime = DateTime.Now.AddSeconds(15); TimeSpan Interval = TimeSpan.FromSeconds(ConfigurationManager.UpdateCheckInterval); CheckUpdateRuntime = AsyncTaskExecuter.ExecuteIntervalTask(StartTime, Interval, getRemoteVersion, getVersionCallback); }