Files
parr_api/PARR.API/Settings/MqSettings.cs

37 lines
1.2 KiB
C#

using PARR.Domain.Enums;
using PARR.Domain.Settings;
namespace PARR.API.Settings
{
public class MqSettings
{
public MqSettingsBase GenerateTemplates { get; set; } = new();
public MqSettingsBase TemplateDistributor { get; set; } = new();
public MqSettingsBase TemplateActivator { get; set; } = new();
public MqStatistics Statistics { get; set; } = new MqStatistics();
public MqSettingsBase TemplatesMatcher { get; set; } = new();
public MqSettingsBase TemplatesUpdater { get; set; } = new();
public MqSettingsBase NextRun { get; set; } = new();
/// <summary>
/// Настройки MQ для задач
/// </summary>
public Dictionary<TaskTypeEnum, MqSettingsBase> Tasks { get; set; } = new();
}
public class MqStatistics
{
public StatMqAuth StatMqAuth { get; set; } = new StatMqAuth();
}
public class StatMqAuth : IMqSettings
{
public string HostName { get; init; } = string.Empty;
public string QueueName { get; init; } = string.Empty;
public string User { get; init; } = string.Empty;
public string Password { get; init; } = string.Empty;
public ushort? PrefetchCount { get; init; } = 0;
}
}