private void AutoClosingTimerCallback(object state)
{
try
{
lock (this.SyncRoot)
{
if (!this.IsInitialized)
{
return;
}
DateTime expireTime = DateTime.UtcNow.AddSeconds(-this.OpenFileCacheTimeout);
this.fileAppenderCache.CloseAppenders(expireTime);
}
}
catch (Exception exception)
{
InternalLogger.Warn(exception, "Exception in AutoClosingTimerCallback.");
if (exception.MustBeRethrownImmediately())
{
throw; // Throwing exceptions here will crash the entire application (.NET 2.0 behavior)
}
}
}