Compare commits
2 Commits
10f3396b8c
...
cf28b6c8ea
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
cf28b6c8ea | ||
|
|
c9215b2e70 |
@@ -45,7 +45,7 @@ public class MessageConsumerService implements RocketMQListener<JSONObject> {
|
|||||||
// 处理消息
|
// 处理消息
|
||||||
try {
|
try {
|
||||||
rateLimiter.acquire(); // 请求许可。如果超过速率,则此方法会阻塞
|
rateLimiter.acquire(); // 请求许可。如果超过速率,则此方法会阻塞
|
||||||
//logger.info("消费到消息:{}", jsonObject);
|
logger.info("消费到消息:{}", jsonObject);
|
||||||
String body = jsonObject.getString("body");
|
String body = jsonObject.getString("body");
|
||||||
byte[] decodedBody = Base64.getDecoder().decode(body);
|
byte[] decodedBody = Base64.getDecoder().decode(body);
|
||||||
String decodedBodyStr = new String(decodedBody, StandardCharsets.UTF_8);
|
String decodedBodyStr = new String(decodedBody, StandardCharsets.UTF_8);
|
||||||
|
|||||||
@@ -565,7 +565,7 @@ public class JDUtil {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 打印方法调用和开始结束时间
|
// 打印方法调用和开始结束时间
|
||||||
logger.info(" {} --- 拉取订单, 分钟还是秒 {} , 开始时间:{} --- 结束时间:{}", appKey.substring(appKey.length()-4) ,hourMinuteTag, startTime.format(DATE_TIME_FORMATTER), endTime.format(DATE_TIME_FORMATTER));
|
//logger.info(" {} --- 拉取订单, 分钟还是秒 {} , 开始时间:{} --- 结束时间:{}", appKey.substring(appKey.length()-4) ,hourMinuteTag, startTime.format(DATE_TIME_FORMATTER), endTime.format(DATE_TIME_FORMATTER));
|
||||||
|
|
||||||
return unionOpenOrderRowQueryResponse;
|
return unionOpenOrderRowQueryResponse;
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
|
|||||||
@@ -4,7 +4,6 @@ import cn.hutool.core.util.ObjectUtil;
|
|||||||
import cn.hutool.http.HttpRequest;
|
import cn.hutool.http.HttpRequest;
|
||||||
import cn.van.business.enums.WXReqType;
|
import cn.van.business.enums.WXReqType;
|
||||||
import cn.van.business.mq.MessageProducerService;
|
import cn.van.business.mq.MessageProducerService;
|
||||||
import cn.van.business.repository.OrderRowRepository;
|
|
||||||
import com.alibaba.fastjson2.JSON;
|
import com.alibaba.fastjson2.JSON;
|
||||||
import com.alibaba.fastjson2.JSONObject;
|
import com.alibaba.fastjson2.JSONObject;
|
||||||
import lombok.AllArgsConstructor;
|
import lombok.AllArgsConstructor;
|
||||||
@@ -13,12 +12,9 @@ import lombok.NoArgsConstructor;
|
|||||||
import org.slf4j.Logger;
|
import org.slf4j.Logger;
|
||||||
import org.slf4j.LoggerFactory;
|
import org.slf4j.LoggerFactory;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.context.annotation.Lazy;
|
|
||||||
import org.springframework.core.env.Environment;
|
import org.springframework.core.env.Environment;
|
||||||
import org.springframework.data.redis.core.StringRedisTemplate;
|
|
||||||
import org.springframework.stereotype.Component;
|
import org.springframework.stereotype.Component;
|
||||||
|
|
||||||
import javax.annotation.Resource;
|
|
||||||
import java.util.*;
|
import java.util.*;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -6,6 +6,7 @@ import cn.van.business.model.wx.WxMessage;
|
|||||||
import cn.van.business.repository.SettingRepository;
|
import cn.van.business.repository.SettingRepository;
|
||||||
import cn.van.business.repository.WxMessageDataForChatRepository;
|
import cn.van.business.repository.WxMessageDataForChatRepository;
|
||||||
import cn.van.business.repository.WxUserRepository;
|
import cn.van.business.repository.WxUserRepository;
|
||||||
|
import com.alibaba.fastjson2.JSON;
|
||||||
import com.alibaba.fastjson2.JSONArray;
|
import com.alibaba.fastjson2.JSONArray;
|
||||||
import org.slf4j.Logger;
|
import org.slf4j.Logger;
|
||||||
import org.slf4j.LoggerFactory;
|
import org.slf4j.LoggerFactory;
|
||||||
@@ -245,7 +246,7 @@ public class WxMessageConsumer {
|
|||||||
private void handlePrivateMessage(WxMessage wxMessage) throws Exception {
|
private void handlePrivateMessage(WxMessage wxMessage) throws Exception {
|
||||||
Integer msgType = 1;
|
Integer msgType = 1;
|
||||||
// 做业务处理
|
// 做业务处理
|
||||||
//logger.info("处理消息: {}", JSON.toJSONString(wxMessage));
|
logger.info("处理消息: {}", JSON.toJSONString(wxMessage));
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* {
|
* {
|
||||||
|
|||||||
Reference in New Issue
Block a user