From 6c69c98e3324db3b14ecb519ff36243769c1ed83 Mon Sep 17 00:00:00 2001 From: "Collin M. Barrett" Date: Tue, 22 Sep 2020 17:04:44 -0500 Subject: [PATCH] =?UTF-8?q?feat(archival):=20=E2=9C=A8=20bump=20log=20leve?= =?UTF-8?q?l?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Commands/ArchiveList.cs | 4 ++-- .../Commands/EnqueueArchiveAllLists.cs | 2 +- .../Persistence/ITxtFileRepository.cs | 6 +++--- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/services/Archival/FilterLists.Archival.Application/Commands/ArchiveList.cs b/services/Archival/FilterLists.Archival.Application/Commands/ArchiveList.cs index 597f72a25..8953bc132 100644 --- a/services/Archival/FilterLists.Archival.Application/Commands/ArchiveList.cs +++ b/services/Archival/FilterLists.Archival.Application/Commands/ArchiveList.cs @@ -51,7 +51,7 @@ public Handler( public async Task Handle(Command request, CancellationToken cancellationToken) { _ = request ?? throw new ArgumentNullException(nameof(request)); - _logger.LogDebug("Archiving list {ListId}", request.ListId); + _logger.LogInformation("Archiving list {ListId}", request.ListId); var segmentUrls = (await GetSegmentUrlsAsync(request.ListId, cancellationToken)).ToList(); if (segmentUrls.Count > 0) @@ -60,7 +60,7 @@ public async Task Handle(Command request, CancellationToken cancellationTo await _repo.AddFileAsync(file, cancellationToken); _repo.Commit(); - _logger.LogDebug( + _logger.LogInformation( "Archived segment(s) {@SegmentNumbers} of list {ListId}", segmentUrls.Select(s => s.SegmentNumber), request.ListId); diff --git a/services/Archival/FilterLists.Archival.Application/Commands/EnqueueArchiveAllLists.cs b/services/Archival/FilterLists.Archival.Application/Commands/EnqueueArchiveAllLists.cs index 49d211daf..abce8fdd6 100644 --- a/services/Archival/FilterLists.Archival.Application/Commands/EnqueueArchiveAllLists.cs +++ b/services/Archival/FilterLists.Archival.Application/Commands/EnqueueArchiveAllLists.cs @@ -41,7 +41,7 @@ public async Task Handle(Command request, CancellationToken cancellationTo spacing = TimeSpan.FromSeconds((double)86400 / lists.Count); #endif - _logger.LogDebug("Enqueuing archival of {ArchiveCount} lists spaced {Spacing} seconds apart.", archiveCount, spacing.Seconds); + _logger.LogInformation("Enqueuing archival of {ArchiveCount} lists spaced {Spacing} seconds apart.", archiveCount, spacing.Seconds); for (var i = 0; i < archiveCount; i++) { diff --git a/services/Archival/FilterLists.Archival.Infrastructure/Persistence/ITxtFileRepository.cs b/services/Archival/FilterLists.Archival.Infrastructure/Persistence/ITxtFileRepository.cs index 9b0d76ac1..912e106d8 100644 --- a/services/Archival/FilterLists.Archival.Infrastructure/Persistence/ITxtFileRepository.cs +++ b/services/Archival/FilterLists.Archival.Infrastructure/Persistence/ITxtFileRepository.cs @@ -53,7 +53,7 @@ public async Task AddFileAsync(IFile file, CancellationToken cancellationToken) textStreams.Add(strategy.Convert(segment, cancellationToken)); } - _logger.LogDebug("Writing {FileName}", file.TargetFileName); + _logger.LogInformation("Writing {FileName}", file.TargetFileName); var fileInfo = new FileInfo(Path.Combine(_options.RepositoryPath, file.TargetFileName)); _writtenFiles.Add(fileInfo); @@ -65,7 +65,7 @@ public async Task AddFileAsync(IFile file, CancellationToken cancellationToken) await textStream.CopyToAsync(target, cancellationToken); } - _logger.LogDebug("Finished writing {FileName}", file.TargetFileName); + _logger.LogInformation("Finished writing {FileName}", file.TargetFileName); } public void Commit() @@ -76,7 +76,7 @@ public void Commit() Commands.Stage(_repo, fileNames); _repo.Commit(message, signature, signature); - _logger.LogDebug("Committed {@FileNames}", fileNames); + _logger.LogInformation("Committed {@FileNames}", fileNames); } public void Dispose()