Skip to content

Commit

Permalink
Fixed #953
Browse files Browse the repository at this point in the history
  • Loading branch information
gertjvr authored and phatboyg committed Aug 2, 2017
1 parent d1cb3e6 commit 59ec6bd
Showing 1 changed file with 2 additions and 4 deletions.
Expand Up @@ -40,7 +40,8 @@ public RabbitMqBusFactoryConfigurator(IRabbitMqEndpointConfiguration configurati

_hosts = new BusHostCollection<RabbitMqHost>();

_settings = new RabbitMqReceiveSettings("ignore", "fanout", false, true);
var queueName = _configuration.ConsumeTopology.CreateTemporaryQueueName("bus-");
_settings = new RabbitMqReceiveSettings(queueName, "fanout", false, true);
_settings.SetQueueArgument("x-expires", TimeSpan.FromMinutes(1));
_settings.SetExchangeArgument("x-expires", TimeSpan.FromMinutes(1));
}
Expand Down Expand Up @@ -135,9 +136,6 @@ public IRabbitMqHost Host(RabbitMqHostSettings settings)
var host = new RabbitMqHost(settings);
_hosts.Add(host);

if (_hosts.Count == 1 && string.IsNullOrWhiteSpace(_settings.QueueName))
_settings.QueueName = _configuration.ConsumeTopology.CreateTemporaryQueueName("bus-");

return host;
}

Expand Down

0 comments on commit 59ec6bd

Please sign in to comment.