Compare commits

...

No commits in common. 'main' and 'b320470aa84e09d419b0b7edb99fc6994f99c80e' have entirely different histories.

2
.gitignore vendored

@ -1,5 +1,5 @@
HELP.md
target
target/
!.mvn/wrapper/maven-wrapper.jar
!**/src/main/**/target/
!**/src/test/**/target/

@ -17,11 +17,4 @@
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-amqp</artifactId>
</dependency>
</dependencies>
</project>

@ -1,57 +0,0 @@
package com.shun.business.config;
import org.springframework.amqp.core.*;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
/**
* @author
* @since 2023/6/21 21:08
*/
@Configuration
public class RabbitMQConfig {
/**
*
*/
public static final String PLACE_ORDER_EXCHANGE = "place_order_exchange";
/**
* Queue
*/
public static final String COUPON_QUEUE = "coupon_queue";
public static final String USER_POINTS_QUEUE = "user_points_queue";
public static final String BUSINESS_QUEUE = "business_queue";
@Bean
public Exchange placeOrderExchange(){
return ExchangeBuilder.fanoutExchange(PLACE_ORDER_EXCHANGE).build();
}
@Bean
public Queue couponQueue(){
return QueueBuilder.durable(COUPON_QUEUE).build();
}
@Bean
public Queue userPointsQueue(){
return QueueBuilder.durable(USER_POINTS_QUEUE).build();
}
@Bean
public Queue businessQueue(){
return QueueBuilder.durable(BUSINESS_QUEUE).build();
}
@Bean
public Binding couponBinding(Exchange placeOrderExchange, Queue couponQueue){
return BindingBuilder.bind(couponQueue).to(placeOrderExchange).with("").noargs();
}
@Bean
public Binding userPointsBinding(Exchange placeOrderExchange,Queue userPointsQueue){
return BindingBuilder.bind(userPointsQueue).to(placeOrderExchange).with("").noargs();
}
@Bean
public Binding businessBinding(Exchange placeOrderExchange,Queue businessQueue){
return BindingBuilder.bind(businessQueue).to(placeOrderExchange).with("").noargs();
}
}

@ -1,28 +0,0 @@
package com.shun.business.listener;
import com.rabbitmq.client.Channel;
import com.shun.business.config.RabbitMQConfig;
import lombok.extern.slf4j.Slf4j;
import org.springframework.amqp.core.Message;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Component;
/**
*
*
* @author
* @since 2023/6/21 21:43
*/
@Component
@Slf4j
public class BusinessListener {
@RabbitListener(queues = {RabbitMQConfig.BUSINESS_QUEUE})
public void consume(String msg, Channel channel, Message message) throws Exception {
// 预扣除优惠券
Thread.sleep(400);
log.info("优惠券预扣除成功! msg:{}",msg);
// 手动ACK
channel.basicAck(message.getMessageProperties().getDeliveryTag(), false);
}
}

@ -6,14 +6,4 @@ spring:
cloud:
nacos:
discovery:
server-addr: 127.0.0.1:8848
rabbitmq:
host: 192.168.48.128
port: 5672
username: admin
password: admin
virtual-host: /
listener:
simple:
# 手动 ack
acknowledge-mode: manual
server-addr: 127.0.0.1:8848

@ -18,11 +18,4 @@
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-amqp</artifactId>
</dependency>
</dependencies>
</project>

@ -1,56 +0,0 @@
package com.shun.coupon.config;
import org.springframework.amqp.core.*;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
/**
* @author
* @since 2023/6/21 21:08
*/
@Configuration
public class RabbitMQConfig {
/**
*
*/
public static final String PLACE_ORDER_EXCHANGE = "place_order_exchange";
/**
* Queue
*/
public static final String COUPON_QUEUE = "coupon_queue";
public static final String USER_POINTS_QUEUE = "user_points_queue";
public static final String BUSINESS_QUEUE = "business_queue";
@Bean
public Exchange placeOrderExchange(){
return ExchangeBuilder.fanoutExchange(PLACE_ORDER_EXCHANGE).build();
}
@Bean
public Queue couponQueue(){
return QueueBuilder.durable(COUPON_QUEUE).build();
}
@Bean
public Queue userPointsQueue(){
return QueueBuilder.durable(USER_POINTS_QUEUE).build();
}
@Bean
public Queue businessQueue(){
return QueueBuilder.durable(BUSINESS_QUEUE).build();
}
@Bean
public Binding couponBinding(Exchange placeOrderExchange,Queue couponQueue){
return BindingBuilder.bind(couponQueue).to(placeOrderExchange).with("").noargs();
}
@Bean
public Binding userPointsBinding(Exchange placeOrderExchange,Queue userPointsQueue){
return BindingBuilder.bind(userPointsQueue).to(placeOrderExchange).with("").noargs();
}
@Bean
public Binding businessBinding(Exchange placeOrderExchange,Queue businessQueue){
return BindingBuilder.bind(businessQueue).to(placeOrderExchange).with("").noargs();
}
}

@ -1,29 +0,0 @@
package com.shun.coupon.listener;
import com.rabbitmq.client.AMQP;
import com.rabbitmq.client.Channel;
import com.shun.coupon.config.RabbitMQConfig;
import lombok.extern.slf4j.Slf4j;
import org.springframework.amqp.core.Message;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Component;
/**
*
*
* @author
* @since 2023/6/21 21:43
*/
@Component
@Slf4j
public class CouponListener {
@RabbitListener(queues = {RabbitMQConfig.COUPON_QUEUE})
public void consume(String msg, Channel channel, Message message) throws Exception {
// 预扣除优惠券
Thread.sleep(400);
log.info("优惠券预扣除成功! msg:{}",msg);
// 手动ACK
channel.basicAck(message.getMessageProperties().getDeliveryTag(), false);
}
}

@ -6,14 +6,4 @@ spring:
cloud:
nacos:
discovery:
server-addr: 127.0.0.1:8848
rabbitmq:
host: 192.168.48.128
port: 5672
username: admin
password: admin
virtual-host: /
listener:
simple:
# 手动 ack
acknowledge-mode: manual
server-addr: 127.0.0.1:8848

@ -18,11 +18,4 @@
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-amqp</artifactId>
</dependency>
</dependencies>
</project>

@ -1,57 +0,0 @@
package com.shun.integral.config;
import org.springframework.amqp.core.*;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
/**
* @author
* @since 2023/6/21 21:08
*/
@Configuration
public class RabbitMQConfig {
/**
*
*/
public static final String PLACE_ORDER_EXCHANGE = "place_order_exchange";
/**
* Queue
*/
public static final String COUPON_QUEUE = "coupon_queue";
public static final String USER_POINTS_QUEUE = "user_points_queue";
public static final String BUSINESS_QUEUE = "business_queue";
@Bean
public Exchange placeOrderExchange(){
return ExchangeBuilder.fanoutExchange(PLACE_ORDER_EXCHANGE).build();
}
@Bean
public Queue couponQueue(){
return QueueBuilder.durable(COUPON_QUEUE).build();
}
@Bean
public Queue userPointsQueue(){
return QueueBuilder.durable(USER_POINTS_QUEUE).build();
}
@Bean
public Queue businessQueue(){
return QueueBuilder.durable(BUSINESS_QUEUE).build();
}
@Bean
public Binding couponBinding(Exchange placeOrderExchange, Queue couponQueue){
return BindingBuilder.bind(couponQueue).to(placeOrderExchange).with("").noargs();
}
@Bean
public Binding userPointsBinding(Exchange placeOrderExchange,Queue userPointsQueue){
return BindingBuilder.bind(userPointsQueue).to(placeOrderExchange).with("").noargs();
}
@Bean
public Binding businessBinding(Exchange placeOrderExchange,Queue businessQueue){
return BindingBuilder.bind(businessQueue).to(placeOrderExchange).with("").noargs();
}
}

@ -1,7 +1,5 @@
package com.shun.integral.controller;
import org.springframework.amqp.core.Message;
import org.springframework.transaction.annotation.Transactional;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;
@ -21,31 +19,4 @@ public class IntegralController {
Thread.sleep(400);
System.out.println("扣除用户积分成功!!");
}
private final String ID_NAME = "spring_returned_message_correlation";
// @Transactional
// public void consume(Message message) {
// // 获取生产者提供的CorrelationId要基于header去获取。
// String id = message.getMessageProperties().getHeader(ID_NAME);
// //1、查询幂等表是否存在当前消息标识
// int count = userPointsIdempotentMapper.findById(id);
// //2、如果存在直接return结束
// if(count == 1){
// log.info("消息已经被消费!!!无需重复消费!");
// return;
// }
// //3、如果不存在插入消息标识到幂等表
// userPointsIdempotentMapper.save(id);
// //4、执行消费逻辑
// // 预扣除用户积分
// try {
// Thread.sleep(400);
// } catch (InterruptedException e) {
// e.printStackTrace();
// }
// System.out.println("扣除用户积分成功!!");
// }
}

@ -1,28 +0,0 @@
package com.shun.integral.listener;
import com.rabbitmq.client.Channel;
import com.shun.integral.config.RabbitMQConfig;
import lombok.extern.slf4j.Slf4j;
import org.springframework.amqp.core.Message;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Component;
/**
*
*
* @author
* @since 2023/6/21 21:43
*/
@Component
@Slf4j
public class IntegralListener {
@RabbitListener(queues = {RabbitMQConfig.USER_POINTS_QUEUE})
public void consume(String msg, Channel channel, Message message) throws Exception {
// 预扣除优惠券
Thread.sleep(400);
log.info("优惠券预扣除成功! msg:{}",msg);
// 手动ACK
channel.basicAck(message.getMessageProperties().getDeliveryTag(), false);
}
}

@ -6,14 +6,4 @@ spring:
cloud:
nacos:
discovery:
server-addr: 127.0.0.1:8848
rabbitmq:
host: 192.168.48.128
port: 5672
username: admin
password: admin
virtual-host: /
listener:
simple:
# 手动 ack
acknowledge-mode: manual
server-addr: 127.0.0.1:8848

@ -18,11 +18,4 @@
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-amqp</artifactId>
</dependency>
</dependencies>
</project>

@ -1,52 +0,0 @@
package com.shun.order.config;
import lombok.extern.slf4j.Slf4j;
import org.springframework.amqp.core.*;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
/**
* @author
* @since 2023/6/24 17:31
*/
@Configuration
@Slf4j
public class RabbitMQConfig {
public static final String ORDER_EXCHANGE = "order_exchange";
public static final String ORDER_QUEUE = "order_queue";
public static final String DEAD_EXCHANGE = "dead_exchange";
public static final String DEAD_QUEUE = "dead_queue";
@Bean
public Exchange orderExchange(){
return ExchangeBuilder.fanoutExchange(ORDER_EXCHANGE).build();
}
@Bean
public Queue orderQueue(){
return QueueBuilder.durable(ORDER_QUEUE).deadLetterExchange(DEAD_EXCHANGE).build();
}
@Bean
public Exchange deadExchange(){
return ExchangeBuilder.fanoutExchange(DEAD_EXCHANGE).build();
}
@Bean
public Queue deadQueue(){
return QueueBuilder.durable(DEAD_QUEUE).build();
}
@Bean
public Binding orderBinding(Exchange orderExchange,Queue orderQueue){
return BindingBuilder.bind(orderQueue).to(orderExchange).with("").noargs();
}
@Bean
public Binding deadBinding(Exchange deadExchange,Queue deadQueue){
return BindingBuilder.bind(deadQueue).to(deadExchange).with("").noargs();
}
}

@ -1,16 +1,8 @@
package com.shun.order.controller;
import com.shun.order.config.RabbitMQConfig;
import jakarta.annotation.Resource;
import org.springframework.amqp.AmqpException;
import org.springframework.amqp.core.Message;
import org.springframework.amqp.core.MessagePostProcessor;
import org.springframework.amqp.rabbit.core.RabbitTemplate;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;
import java.util.UUID;
/**
* @author
* @since 2023/6/19 15:54
@ -18,9 +10,6 @@ import java.util.UUID;
@RestController
public class OrderController {
@Resource
RabbitTemplate rabbitTemplate;
/**
*
* @throws InterruptedException
@ -29,24 +18,6 @@ public class OrderController {
public void create() throws InterruptedException {
Thread.sleep(400);
System.out.println("创建订单成功!");
save();
}
public void save() {
// 生成主键ID
String id = UUID.randomUUID().toString();
// 创建订单
//orderMapper.save(id);
// 订单构建成功~
// 发送消息到RabbitMQ的死信队列
rabbitTemplate.convertAndSend(RabbitMQConfig.ORDER_EXCHANGE, "", id, new MessagePostProcessor() {
@Override
public Message postProcessMessage(Message message) throws AmqpException {
// 设置消息的生存时间为15s当然也可以在构建队列时指定队列的生存时间。
message.getMessageProperties().setExpiration("15000");
return message;
}
});
}
}

@ -1,42 +0,0 @@
package com.shun.order.listener;
import com.rabbitmq.client.Channel;
import com.shun.order.config.RabbitMQConfig;
import lombok.extern.slf4j.Slf4j;
import org.springframework.amqp.core.Message;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Component;
/**
*
*
* @author
* @since 2023/6/21 21:43
*/
@Component
@Slf4j
public class OrderListener {
@RabbitListener(queues = {RabbitMQConfig.DEAD_QUEUE})
public void consume(String msg, Channel channel, Message message) throws Exception {
//1、 调用Service实现订单状态的处理
// orderService.delayCancelOrder(id);
//2、 ack的干活~
channel.basicAck(message.getMessageProperties().getDeliveryTag(),false);
}
public void delayCancelOrder(String id) {
//1、基于id查询订单信息。 for update
// int orderState = orderMapper.findOrderStateByIdForUpdate(id);
// //2、判断订单状态
// if(orderState != 0){
// log.info("订单已经支付!!");
// return;
// }
// //3、修改订单状态
// log.info("订单未支付,修改订单状态为已取消");
// orderMapper.updateOrderStateById(-1,id);
}
}

@ -6,10 +6,4 @@ spring:
cloud:
nacos:
discovery:
server-addr: 127.0.0.1:8848
rabbitmq:
host: 192.168.48.128
port: 5672
username: admin
password: admin
virtual-host: /
server-addr: 127.0.0.1:8848

@ -23,10 +23,5 @@
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-loadbalancer</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-amqp</artifactId>
</dependency>
</dependencies>
</project>

@ -1,56 +0,0 @@
package com.shun.placeOrder.config;
import org.springframework.amqp.core.*;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
/**
* @author
* @since 2023/6/21 21:08
*/
@Configuration
public class RabbitMQConfig {
/**
*
*/
public static final String PLACE_ORDER_EXCHANGE = "place_order_exchange";
/**
* Queue
*/
public static final String COUPON_QUEUE = "coupon_queue";
public static final String USER_POINTS_QUEUE = "user_points_queue";
public static final String BUSINESS_QUEUE = "business_queue";
@Bean
public Exchange placeOrderExchange(){
return ExchangeBuilder.fanoutExchange(PLACE_ORDER_EXCHANGE).build();
}
@Bean
public Queue couponQueue(){
return QueueBuilder.durable(COUPON_QUEUE).build();
}
@Bean
public Queue userPointsQueue(){
return QueueBuilder.durable(USER_POINTS_QUEUE).build();
}
@Bean
public Queue businessQueue(){
return QueueBuilder.durable(BUSINESS_QUEUE).build();
}
@Bean
public Binding couponBinding(Exchange placeOrderExchange,Queue couponQueue){
return BindingBuilder.bind(couponQueue).to(placeOrderExchange).with("").noargs();
}
@Bean
public Binding userPointsBinding(Exchange placeOrderExchange,Queue userPointsQueue){
return BindingBuilder.bind(userPointsQueue).to(placeOrderExchange).with("").noargs();
}
@Bean
public Binding businessBinding(Exchange placeOrderExchange,Queue businessQueue){
return BindingBuilder.bind(businessQueue).to(placeOrderExchange).with("").noargs();
}
}

@ -1,99 +0,0 @@
package com.shun.placeOrder.config;
import com.shun.placeOrder.util.GlobalCache;
import com.shun.placeOrder.util.Mock;
import jakarta.annotation.Nullable;
import lombok.extern.slf4j.Slf4j;
import org.springframework.amqp.core.Message;
import org.springframework.amqp.core.ReturnedMessage;
import org.springframework.amqp.rabbit.connection.ConnectionFactory;
import org.springframework.amqp.rabbit.connection.CorrelationData;
import org.springframework.amqp.rabbit.core.RabbitTemplate;
import org.springframework.context.annotation.Bean;
import org.springframework.stereotype.Component;
import java.util.Arrays;
import java.util.Map;
import java.util.Objects;
/**
* @author
* @since 2023/6/24 14:35
*/
@Component
@Slf4j
public class RabbitTemplateConfig {
@Bean
public RabbitTemplate rabbitTemplate(ConnectionFactory connectionFactory){
//1、new出RabbitTemplate对象
RabbitTemplate rabbitTemplate = new RabbitTemplate();
//2、将connectionFactory设置到RabbitTemplate对象中
rabbitTemplate.setConnectionFactory(connectionFactory);
//3、设置confirm回调
rabbitTemplate.setConfirmCallback(confirmCallback());
//4、设置return回调
/*
old
rabbitTemplate.setReturnCallback(returnCallback());
*/
rabbitTemplate.setReturnsCallback(returnCallback());
//5、设置mandatory为true
rabbitTemplate.setMandatory(true);
//6、返回RabbitTemplate对象即可
return rabbitTemplate;
}
public RabbitTemplate.ConfirmCallback confirmCallback(){
return (correlationData, ack, cause) -> {
// 如果消息 ack 成功
if (correlationData == null) {
return;
}
String msgId = correlationData.getId();
if(ack){
log.info("\n消息发送到Exchange成功!! msgId = " + msgId);
GlobalCache.remove(msgId);
}else{
log.error("\n消息发送到Exchange失败!! msgId = " + msgId);
Map value = (Map) GlobalCache.get(msgId);
// 推荐自己玩的时候用service做增删改操作控制事务~
Mock.save(value);
}
};
}
public RabbitTemplate.ReturnsCallback returnCallback(){
return new RabbitTemplate.ReturnsCallback(){
/**
* Returned message callback.
*
* @param returned the returned message and metadata.
*/
@Override
public void returnedMessage(@Nullable ReturnedMessage returned) {
log.info("\n消息未路由到队列");
assert returned != null;
log.info("\nreturn消息为" + Arrays.toString(returned.getMessage().getBody()));
log.info("\nreturn交换机为" + returned.getExchange());
log.info("\nreturn路由为" + returned.getRoutingKey());
}
};
}
/**
* old
* @return
*/
// public RabbitTemplate.ReturnCallback returnCallback(){
// return new RabbitTemplate.ReturnCallback(){
// @Override
// public void returnedMessage(Message message, int replyCode, String replyText, String exchange, String routingKey) {
// System.out.println("消息未路由到队列");
// System.out.println("return消息为" + new String(message.getBody()));
// System.out.println("return交换机为" + exchange);
// System.out.println("return路由为" + routingKey);
// }
// };
// }
}

@ -1,15 +1,10 @@
package com.shun.placeOrder.contoller;
import com.shun.placeOrder.client.*;
import com.shun.placeOrder.config.RabbitMQConfig;
import com.shun.placeOrder.util.GlobalCache;
import jakarta.annotation.Resource;
import org.springframework.amqp.rabbit.core.RabbitTemplate;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;
import java.util.*;
/**
* @author
* @since 2023/6/19 15:46
@ -28,9 +23,6 @@ public class PlaceOrderController {
@Resource
StockClient stockClient;
@Resource
RabbitTemplate rabbitTemplate;
@GetMapping("po")
public String po(){
long start = System.currentTimeMillis();
@ -38,47 +30,15 @@ public class PlaceOrderController {
stockClient.delStock();
// 调用订单服务 创建订单
orderClient.create();
//feginToBu();
//mqToBo();
mqToBuMessageBz();
long end = System.currentTimeMillis();
System.out.println("耗时:" + (end - start));
return "PlaceOrderController finish";
}
/**
* MQ
*/
private void mqToBuMessageBz() {
String userAndOrderInfo = "用户信息&订单信息&优惠券信息等等…………";
// 生成当前消息的唯一标识
String id = UUID.randomUUID().toString();
// 封装消息信息
Map<String, Object> map = new HashMap<>();
map.put("message",userAndOrderInfo);
map.put("exchange",RabbitMQConfig.PLACE_ORDER_EXCHANGE);
map.put("routingKey","");
map.put("sendTime",new Date());
// 将id标识和消息存储到全局缓存中
GlobalCache.set(id,map);
// 将同步方式修改为基于RabbitMQ的异步方式
rabbitTemplate.convertAndSend(RabbitMQConfig.PLACE_ORDER_EXCHANGE,"",userAndOrderInfo);
}
private void mqToBo() {
String userAndOrderInfo = "用户信息&订单信息&优惠券信息等等…………";
// 将同步方式修改为基于RabbitMQ的异步方式
rabbitTemplate.convertAndSend(RabbitMQConfig.PLACE_ORDER_EXCHANGE,"",userAndOrderInfo);
}
private void feginToBu() {
// 调用优惠券服务,预扣除优惠券
couponClient.coupon();
// 调用用户积分服务,预扣除用户积分
integralClient.up();
// 调用商家服务,通知商家用户已下单
businessClient.notifyBusiness();
long end = System.currentTimeMillis();
System.out.println("耗时:" + (end - start));
return "PlaceOrderController finish";
}
}

@ -1,25 +0,0 @@
package com.shun.placeOrder.util;
import java.util.HashMap;
import java.util.Map;
/**
* cache
* @author
* @since 2023/6/24 15:07
*/
public class GlobalCache {
private static final Map<String,Object> MAP = new HashMap<>();
public static void set(String key,Object value){
MAP.put(key,value);
}
public static Object get(String key){
return MAP.get(key);
}
public static void remove(String key){
MAP.remove(key);
}
}

@ -1,18 +0,0 @@
package com.shun.placeOrder.util;
import lombok.extern.slf4j.Slf4j;
import java.util.Map;
/**
*
* @author
* @since 2023/6/24 15:25
*/
@Slf4j
public class Mock {
public static void save(Object value) {
log.info("保存");
}
}

@ -6,14 +6,4 @@ spring:
cloud:
nacos:
discovery:
server-addr: 127.0.0.1:8848
rabbitmq:
host: 192.168.48.128
port: 5672
username: admin
password: admin
virtual-host: /
# 设置发布者确认类型 使用 with CorrelationData 将确认与发送的消息相关联 也就是指定发送模式
publisher-confirm-type: correlated
# 开启回调处理
publisher-returns: true
server-addr: 127.0.0.1:8848

@ -28,6 +28,10 @@
<spring-cloud.version>2022.0.2</spring-cloud.version>
</properties>
<dependencies>
<!-- <dependency>-->
<!-- <groupId>org.springframework.boot</groupId>-->
<!-- <artifactId>spring-boot-starter-amqp</artifactId>-->
<!-- </dependency>-->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>

@ -1,3 +1 @@
RabbitMQ 模拟电商
支付 订单 商家 积分 库存 优惠券
基本逻辑
RabbitMQ 模拟电商
Loading…
Cancel
Save