queue and builder separation

This commit is contained in:
2026-01-18 20:49:26 +01:00
Unverified
parent 67017b54f6
commit 5fa91a73d1
3 changed files with 44 additions and 16 deletions

View File

@@ -0,0 +1,21 @@
namespace TimetableDesigner.Backend.Events.Providers.RabbitMQ;
public class RabbitMQEventQueueBuilder : EventQueueBuilder<RabbitMQEventQueue>
{
public string Hostname { get; set; } = "localhost";
public int Port { get; set; } = 5672;
public string Username { get; set; } = null!;
public string Password { get; set; } = null!;
public string ExchangeName { get; set; } = null!;
public string QueuePrefix { get; set; } = null!;
public override IDictionary<string, string> GetConnectionParameters() => new Dictionary<string, string>()
{
{ nameof(Hostname), Hostname },
{ nameof(Port), Port.ToString() },
{ nameof(Username), Username },
{ nameof(Password), Password },
{ nameof(ExchangeName), ExchangeName },
{ nameof(QueuePrefix), QueuePrefix }
};
}