Commit a12d4b9e authored by yanzg's avatar yanzg

修复等待时间

parent 774463e3
......@@ -84,9 +84,7 @@ public class MessageSendServiceImpl implements MessageSendService {
// 设置编号
CorrelationData correlationData = new CorrelationData();
correlationData.setId(finalMessageId);
rabbitTemplate.getRabbitTemplate().convertAndSend(req.getExchangeName(), req.getRouteKey(), req.getMessage(), new MessagePostProcessor() {
@Override
public Message postProcessMessage(Message message) throws AmqpException {
rabbitTemplate.getRabbitTemplate().convertAndSend(req.getExchangeName(), req.getRouteKey(), req.getMessage(), message -> {
// 设置队列消息持久化
MessageProperties properties = message.getMessageProperties();
// 设置持久化
......@@ -97,7 +95,6 @@ public class MessageSendServiceImpl implements MessageSendService {
properties.setExpiration(req.getDedTime() + "");
}
return message;
}
}, correlationData);
return req.getMessageId();
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment