Add work on PublishedSnapshotService

This commit is contained in:
Nikolaj
2020-09-15 08:45:40 +02:00
parent 5e17aa3bf1
commit 02828db8fd
52 changed files with 255 additions and 254 deletions

View File

@@ -348,7 +348,7 @@ namespace Umbraco.Web.Scheduling
var hasTasks = TaskCount > 0;
if (!force && hasTasks)
_logger.Info<BackgroundTaskRunner>("{LogPrefix} Waiting for tasks to complete", _logPrefix);
_logger.LogInformation("{LogPrefix} Waiting for tasks to complete", _logPrefix);
// complete the queue
// will stop waiting on the queue or on a latch
@@ -704,7 +704,7 @@ namespace Umbraco.Web.Scheduling
if (_terminating == false)
{
_terminating = true;
_logger.Info<BackgroundTaskRunner>("{LogPrefix} Terminating {Immediate}", _logPrefix, immediate ? immediate.ToString() : string.Empty);
_logger.LogInformation("{LogPrefix} Terminating {Immediate}", _logPrefix, immediate ? immediate.ToString() : string.Empty);
onTerminating = true;
}
}
@@ -789,7 +789,7 @@ namespace Umbraco.Web.Scheduling
/// </remarks>
private void StopImmediate()
{
_logger.Info<BackgroundTaskRunner>("{LogPrefix} Canceling tasks", _logPrefix);
_logger.LogInformation("{LogPrefix} Canceling tasks", _logPrefix);
try
{
Shutdown(true, true); // cancel all tasks, wait for the current one to end
@@ -823,7 +823,7 @@ namespace Umbraco.Web.Scheduling
terminatedSource = _terminatedSource;
}
_logger.Info<BackgroundTaskRunner>("{LogPrefix} Tasks {TaskStatus}, terminated",
_logger.LogInformation("{LogPrefix} Tasks {TaskStatus}, terminated",
_logPrefix,
immediate ? "cancelled" : "completed");

View File

@@ -83,7 +83,7 @@ namespace Umbraco.Web.Scheduling
// run
var result = _contentService.PerformScheduledPublish(DateTime.Now);
foreach (var grouped in result.GroupBy(x => x.Result))
_logger.Info<ScheduledPublishing>(
_logger.LogInformation(
"Scheduled publishing result: '{StatusCount}' items with status {Status}",
grouped.Count(), grouped.Key);
}