文件名从 shasteel-biz/src/main/java/com/iailab/module/shasteel/mq/config/TopicPredictFinishRabbitConfig.java 修改 |
| | |
| | | package com.iailab.module.shasteel.mq.config; |
| | | |
| | | import com.iailab.module.shasteel.mq.common.RoutingConstant; |
| | | import com.iailab.module.shasteel.mq.consumer.PredictFinishMessage; |
| | | import org.springframework.amqp.core.Binding; |
| | | import org.springframework.amqp.core.BindingBuilder; |
| | |
| | | * @createTime 2024年11月27日 |
| | | */ |
| | | @Configuration |
| | | public class TopicPredictFinishRabbitConfig { |
| | | //绑定键 |
| | | public final static String routingPredictFinish = PredictFinishMessage.PREDICTFINISH_ROUTING_KEY; |
| | | public class QueuePredictFinishConfig { |
| | | // 队列名称 |
| | | public final static String QUEUE_NAME = "IaiabFastShateel.Model.PredictFinish"; |
| | | |
| | | @Bean |
| | | public Queue predictFinishQueue() { |
| | | return new Queue(TopicPredictFinishRabbitConfig.routingPredictFinish); |
| | | return new Queue(QueuePredictFinishConfig.QUEUE_NAME); |
| | | } |
| | | |
| | | @Bean |
| | |
| | | // 注意通配符*和#的用法 |
| | | @Bean |
| | | Binding bindingExchangeMessagePF() { |
| | | return BindingBuilder.bind(predictFinishQueue()).to(predictFinishExchange()).with(routingPredictFinish); |
| | | return BindingBuilder.bind(predictFinishQueue()).to(predictFinishExchange()).with(RoutingConstant.Iailab_Model_PredictFinish); |
| | | } |
| | | } |