feat(core): Заготовка WorkloadCacheService
This commit is contained in:
@@ -0,0 +1,53 @@
|
||||
using Microsoft.Extensions.Logging;
|
||||
using PARR.Core.Common.Interfaces;
|
||||
|
||||
namespace PARR.Core.Services.Workload.Implementations
|
||||
{
|
||||
/// <summary>
|
||||
/// Класс управления КЭШем для workload
|
||||
/// </summary>
|
||||
internal class WorkloadCacheService
|
||||
{
|
||||
private readonly ILogger<WorkloadCacheService> logger;
|
||||
private readonly IRedisCacheService redisCacheService;
|
||||
|
||||
public WorkloadCacheService(
|
||||
ILogger<WorkloadCacheService> logger,
|
||||
IRedisCacheService redisCacheService
|
||||
//IShortcodeService
|
||||
)
|
||||
{
|
||||
this.logger = logger;
|
||||
this.redisCacheService = redisCacheService;
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Создать КЭШ шаблонов.
|
||||
/// КЭШ рабочих групп и зон ответственности
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public async System.Threading.Tasks.Task CreateTemplateCacheAsync()
|
||||
{
|
||||
await DeleteTemplateCacheAsync();
|
||||
|
||||
//1. Получить из БД все шаблоны - НЕТ РЕПЫ
|
||||
//2. Получить по каждому шаблону ЗО и РГ
|
||||
//3. Сохранить в Redis
|
||||
|
||||
//redisCacheService
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Удалить КЭШ шаблонов.
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
private async System.Threading.Tasks.Task DeleteTemplateCacheAsync()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user