Files
parr_api/PARR.BLL/Contracts/Interfaces/IMqSettings.cs

27 lines
975 B
C#

namespace PARR.BLL.Contracts.Interfaces
{
/// <summary>
/// Поля настроек MQ, используется для appsettings.json
/// </summary>
public interface IMqSettings
{
string HostName { get; set; }
string QueueName { get; set; }
string User { get; set; }
string Password { get; set; }
/// <summary>
/// Кол-во сообщений которые может принимать consumer за один раз. 0 или null - без ограничений
/// </summary>
ushort? PrefetchCount { get; set; }
}
public class MqSettingsBase : IMqSettings
{
public string HostName { get; set; } = string.Empty;
public string QueueName { get; set; } = string.Empty;
public string User { get; set; } = string.Empty;
public string Password { get; set; } = string.Empty;
public ushort? PrefetchCount { get; set; } = 0;
}
}