Removed hangfire. Added TickerQ

This commit is contained in:
2025-08-19 22:53:12 +02:00
parent 60178dc54b
commit ab92edb008
20 changed files with 1267 additions and 487 deletions

View File

@@ -1,40 +0,0 @@
using Hangfire;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Mvc;
using Moonlight.Shared.Http.Responses.Admin.Hangfire;
namespace Moonlight.ApiServer.Http.Controllers.Admin.Sys;
[ApiController]
[Route("api/admin/system/hangfire")]
[Authorize(Policy = "permissions:admin.system.hangfire")]
public class HangfireController : Controller
{
private readonly JobStorage JobStorage;
public HangfireController(JobStorage jobStorage)
{
JobStorage = jobStorage;
}
[HttpGet("stats")]
public Task<HangfireStatsResponse> GetStats()
{
var statistics = JobStorage.GetMonitoringApi().GetStatistics();
return Task.FromResult(new HangfireStatsResponse()
{
Awaiting = statistics.Awaiting,
Deleted = statistics.Deleted,
Enqueued = statistics.Enqueued,
Failed = statistics.Failed,
Processing = statistics.Processing,
Queues = statistics.Queues,
Recurring = statistics.Recurring,
Retries = statistics.Retries,
Scheduled = statistics.Scheduled,
Servers = statistics.Servers,
Succeeded = statistics.Succeeded
});
}
}