feat(core, dal): WorkloadCacheService - методы для работы с кэшем отчетности workload

This commit is contained in:
Mikhail Trubnikov
2026-05-05 14:52:17 +10:00
parent a89605d02a
commit 7d42a80556
10 changed files with 380 additions and 27 deletions

View File

@@ -8,6 +8,7 @@ using PARR.API.Settings;
using PARR.Core.Common.Interfaces;
using PARR.Core.Repositories.Interfaces;
using PARR.Core.Services.NextRunServices;
using PARR.Core.Services.Workload.Implementations;
namespace PARR.API.Controllers.V1
{
@@ -18,19 +19,22 @@ namespace PARR.API.Controllers.V1
private readonly IRedisCacheService redisCacheService;
private readonly INextRunService nextRunService;
private readonly ITemplateRepository templateService;
private readonly WorkloadCacheService workloadCacheService;
public TestController(
IClientService clientService,
IRedisCacheService redisCacheService,
INextRunService nextRunService,
ITemplateRepository templateService,
MqSettings mqSettings
MqSettings mqSettings,
WorkloadCacheService workloadCacheService
)
{
this.clientService = clientService;
this.redisCacheService = redisCacheService;
this.nextRunService = nextRunService;
this.templateService = templateService;
this.workloadCacheService = workloadCacheService;
}
@@ -74,6 +78,9 @@ namespace PARR.API.Controllers.V1
[HttpPost(ApiRoutes.Test.CreateCache)]
public async Task<IActionResult> CreateCache()
{
// var aaa = await workloadCacheService.GetTemplateReportDataAsync();
//var val = await redisCacheService.GetCachedDataAsync<object>("96dAoIH/8Q9Bg8VY");
//var hashKey = redisCacheService.GetKey(new[] { "test", "mxa" });