Browse Source

加强判断

master
jianjun 4 years ago
parent
commit
d7373ee97d
  1. 5
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/mq/ProjectChangedCustomListener.java
  2. 6
      epmet-module/resi-group/resi-group-server/src/main/java/com/epmet/mq/GroupAchievementCustomListener.java

5
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/mq/ProjectChangedCustomListener.java

@ -56,12 +56,11 @@ public class ProjectChangedCustomListener implements MessageListenerConcurrently
private void consumeMessage(String msg) {
logger.info("receive customerId:{}", JSON.toJSONString(msg));
if (StringUtils.isBlank(msg)){
ProjectChangedMQMsg msgObj = JSON.parseObject(msg, ProjectChangedMQMsg.class);
if (msgObj == null){
log.warn("consumeMessage msg body is blank");
return;
}
ProjectChangedMQMsg msgObj = JSON.parseObject(msg, ProjectChangedMQMsg.class);
DistributedLock distributedLock = null;
RLock lock = null;
try {

6
epmet-module/resi-group/resi-group-server/src/main/java/com/epmet/mq/GroupAchievementCustomListener.java

@ -48,12 +48,12 @@ public class GroupAchievementCustomListener implements MessageListenerConcurren
private void consumeMessage(MessageExt messageExt) {
logger.info("receive msg:{}", JSON.toJSONString(messageExt));
String msg = new String(messageExt.getBody());
if (StringUtils.isBlank(msg)){
GroupAchievementMQMsg msgObj = JSON.parseObject(msg, GroupAchievementMQMsg.class);
if (msgObj == null){
log.warn("consumeMessage msg body is blank");
return;
}
GroupAchievementMQMsg msgObj = JSON.parseObject(msg, GroupAchievementMQMsg.class);
DistributedLock distributedLock = null;
RLock lock = null;

Loading…
Cancel
Save