|
|
@@ -4,15 +4,19 @@ import org.springframework.amqp.core.Binding;
|
|
|
import org.springframework.amqp.core.BindingBuilder;
|
|
|
import org.springframework.amqp.core.Queue;
|
|
|
import org.springframework.amqp.core.TopicExchange;
|
|
|
+import org.springframework.beans.factory.annotation.Value;
|
|
|
import org.springframework.context.annotation.Bean;
|
|
|
import org.springframework.context.annotation.Configuration;
|
|
|
|
|
|
@Configuration
|
|
|
public class RabbitConfig {
|
|
|
|
|
|
+ @Value("${rabbitmq.template.exchange}")
|
|
|
+ private String exchangeName;
|
|
|
+
|
|
|
@Bean
|
|
|
TopicExchange exchange() {
|
|
|
- return new TopicExchange("entry");
|
|
|
+ return new TopicExchange(exchangeName);
|
|
|
}
|
|
|
|
|
|
@Bean
|