mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-06-05 15:28:28 +01:00
Use stopwatch for more accurate measurements and reduce log spam
DateTime.Now is suitible for small timespans Replaced the needlessly complex and verbose logging for the httpserver
This commit is contained in:
@@ -44,7 +44,7 @@ namespace Emby.Server.Implementations.ScheduledTasks
|
||||
|
||||
var dueTime = triggerDate - now;
|
||||
|
||||
logger.LogInformation("Daily trigger for {0} set to fire at {1}, which is {2} minutes from now.", taskName, triggerDate.ToString(), dueTime.TotalMinutes.ToString(CultureInfo.InvariantCulture));
|
||||
logger.LogInformation("Daily trigger for {0} set to fire at {1}, which is {2} minutes from now.", taskName, triggerDate, dueTime);
|
||||
|
||||
Timer = new Timer(state => OnTriggered(), null, dueTime, TimeSpan.FromMilliseconds(-1));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user