Exemplo n.º 1
0
        /// <summary>
        /// Delete report folders older than a certain age to avoid unbounded growth of the crash repository.
        /// </summary>
        /// <remarks>The folders for the deduplication process older than the property 'DeleteWaitingReportsDays' days old are deleted.</remarks>
        private static void CleanRepository(ReportWatcher InWatcher)
        {
            try
            {
                foreach (var Queue in InWatcher.ReportQueues)
                {
                    Queue.CleanLandingZone();
                }

                CrashReporterProcessServicer.Log.CleanOutOldLogs(Config.Default.DeleteWaitingReportsDays);

                Symbolicator.CleanOutOldLogs(Config.Default.DeleteWaitingReportsDays);
            }
            catch (Exception Ex)
            {
                CrashReporterProcessServicer.WriteException("CleanRepository: " + Ex, Ex);
            }
        }