Scanner Fixes (#2800)
This commit is contained in:
parent
123917fbec
commit
8167fc5a4f
34 changed files with 462 additions and 203 deletions
|
@ -20,6 +20,7 @@ public interface ICleanupService
|
|||
Task Cleanup();
|
||||
Task CleanupDbEntries();
|
||||
void CleanupCacheAndTempDirectories();
|
||||
void CleanupCacheDirectory();
|
||||
Task DeleteSeriesCoverImages();
|
||||
Task DeleteChapterCoverImages();
|
||||
Task DeleteTagCoverImages();
|
||||
|
@ -178,6 +179,23 @@ public class CleanupService : ICleanupService
|
|||
_logger.LogInformation("Cache and temp directory purged");
|
||||
}
|
||||
|
||||
public void CleanupCacheDirectory()
|
||||
{
|
||||
_logger.LogInformation("Performing cleanup of Cache directories");
|
||||
_directoryService.ExistOrCreate(_directoryService.CacheDirectory);
|
||||
|
||||
try
|
||||
{
|
||||
_directoryService.ClearDirectory(_directoryService.CacheDirectory);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
_logger.LogError(ex, "There was an issue deleting one or more folders/files during cleanup");
|
||||
}
|
||||
|
||||
_logger.LogInformation("Cache directory purged");
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Removes Database backups older than configured total backups. If all backups are older than total backups days, only the latest is kept.
|
||||
/// </summary>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue