1.增加库存记录mq处理
This commit is contained in:
@@ -14,6 +14,8 @@ public class RabbitConfig {
|
||||
public static final String ROUTING_STOCK_RECORD_SALE = "routing.stock.record.sale";
|
||||
|
||||
public static final String QUEUE_STOCK_RECORD = "queue.stock.record";
|
||||
public static final String ROUTING_STOCK_RECORD= "routing.stock.record";
|
||||
|
||||
|
||||
@Bean
|
||||
Queue stockRecordSaleQueue() {
|
||||
@@ -29,4 +31,14 @@ public class RabbitConfig {
|
||||
Binding binding(Queue stockRecordSaleQueue, DirectExchange stockRecordExchange) {
|
||||
return BindingBuilder.bind(stockRecordSaleQueue).to(stockRecordExchange).with(ROUTING_STOCK_RECORD_SALE);
|
||||
}
|
||||
|
||||
@Bean
|
||||
Queue stockRecordSaleQueue2() {
|
||||
return new Queue(QUEUE_STOCK_RECORD);
|
||||
}
|
||||
|
||||
@Bean
|
||||
Binding binding2(Queue stockRecordSaleQueue2, DirectExchange stockRecordExchange) {
|
||||
return BindingBuilder.bind(stockRecordSaleQueue2).to(stockRecordExchange).with(ROUTING_STOCK_RECORD);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user