{
configureExchange(config.getExchangeConfiguration(exchangeName));
}
catch (UnknownExchangeException e)
{
throw new ServerScopedRuntimeException("Could not configure exchange " + exchangeName, e);
}
catch (ReservedExchangeNameException e)
{
throw new ServerScopedRuntimeException("Could not configure exchange " + exchangeName, e);
}
catch (AMQUnknownExchangeType e)
{
throw new ServerScopedRuntimeException("Could not configure exchange " + exchangeName, e);
}
}
String[] queueNames = config.getQueueNames();
for (Object queueNameObj : queueNames)
{
String queueName = String.valueOf(queueNameObj);
try
{
configureQueue(config.getQueueConfiguration(queueName));
}
catch (ConfigurationException e)
{
throw new ServerScopedRuntimeException("Could not configure queue " + queueName, e);
}
}
}