Exemplo n.º 1
0
 protected void SetupEndpoint(string virtualHost, string queueName, string exchangeName)
 {
     if (!string.IsNullOrWhiteSpace(exchangeName))
     {
         Exchange = new ExchangeConfiguration() { Name = exchangeName, Type = RabbitMQUtil.ExchangeType.Fanout };
     }
     QueueEndpoint = new QueueEndpoint()
     {
         VirtualHost = virtualHost,
         RoutingKey = queueName,
         Exchange = Exchange
     };
 }
Exemplo n.º 2
0
 protected void SetupExchange(string name)
 {
     if (!string.IsNullOrWhiteSpace(name))
     {
         Exchange = new ExchangeConfiguration() { Name = name, Durable = true };
     }
 }