File tree Expand file tree Collapse file tree 1 file changed +4
-0
lines changed
src/functionaltests/java/com/ericsson/ei/rabbitmq/configuration Expand file tree Collapse file tree 1 file changed +4
-0
lines changed Original file line number Diff line number Diff line change 1414import org .springframework .amqp .core .TopicExchange ;
1515import org .springframework .amqp .rabbit .connection .CachingConnectionFactory ;
1616import org .springframework .amqp .rabbit .core .RabbitAdmin ;
17+ import org .springframework .amqp .rabbit .core .RabbitManagementTemplate ;
1718import org .springframework .amqp .rabbit .core .RabbitTemplate ;
1819import org .springframework .amqp .rabbit .listener .SimpleMessageListenerContainer ;
1920import org .springframework .beans .factory .annotation .Autowired ;
@@ -64,6 +65,8 @@ public void connect_to_message_bus() throws Exception {
6465 File qpidConfig = new File (config );
6566 amqpBroker = new AMQPBrokerManager (qpidConfig .getAbsolutePath (), port );
6667 amqpBroker .startBroker ();
68+
69+ RabbitManagementTemplate rabbitManagementTemplate = new RabbitManagementTemplate ("amqp:guest@guest//localhost:" +rabbitMQPort );
6770
6871 RmqHandler rmqHandler = eventManager .getRmqHandler ();
6972 rmqHandler .setPort (port );
@@ -74,6 +77,7 @@ public void connect_to_message_bus() throws Exception {
7477 RabbitTemplate rabbitTemplate = rabbitAdmin .getRabbitTemplate ();
7578
7679 rmqHandler .setRabbitTemplate (rabbitTemplate );
80+ rmqHandler .setRabbitManagementTemplate (rabbitManagementTemplate );
7781 rmqHandler .getContainer ().setRabbitAdmin (rabbitAdmin );
7882 rmqHandler .getContainer ().setConnectionFactory (rmqHandler .getCachingConnectionFactory ());
7983 rmqHandler .getContainer ().setQueueNames (rmqHandler .getQueueName ());
You can’t perform that action at this time.
0 commit comments