| 
						
						
							
								
							
						
						
					 | 
				
				 | 
				
					@ -10,6 +10,7 @@ import com.epmet.commons.tools.redis.RedisKeys; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import com.epmet.commons.tools.redis.RedisUtils; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import com.epmet.commons.tools.utils.SpringContextUtils; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import com.epmet.service.StatsResiWarnService; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import lombok.extern.slf4j.Slf4j; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import org.apache.commons.lang.StringUtils; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import org.apache.rocketmq.client.consumer.listener.ConsumeConcurrentlyContext; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import org.apache.rocketmq.client.consumer.listener.ConsumeConcurrentlyStatus; | 
				
			
			
		
	
	
		
			
				
					| 
						
						
						
							
								
							
						
					 | 
				
				 | 
				
					@ -27,6 +28,7 @@ import java.util.concurrent.TimeUnit; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					 * @author wxz | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					 * @date 2021.10.13 15:21:48 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					*/ | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					@Slf4j | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					public class ICWarnStatsEventListener implements MessageListenerConcurrently { | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					    private Logger logger = LoggerFactory.getLogger(getClass()); | 
				
			
			
		
	
	
		
			
				
					| 
						
							
								
							
						
						
							
								
							
						
						
					 | 
				
				 | 
				
					@ -53,13 +55,14 @@ public class ICWarnStatsEventListener implements MessageListenerConcurrently { | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        // msg即为消息体
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        // tags为SystemMessageType.java中的项,为具体的操作,此处拿到tags,判断是创建还是变更,来做响应的后续操作即可
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        String msg = new String(messageExt.getBody()); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        log.info("msg is {}",msg); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        String topic = messageExt.getTopic(); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        String tags = messageExt.getTags(); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        String pendingMsgLabel = messageExt.getUserProperty(MQUserPropertys.BLOCKED_MSG_LABEL); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        logger.info("【开放数据事件监听器】-居民信息变动-收到消息内容:{},操作:{}", msg, tags); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        IcResiUserAddMQMsg obj = JSON.parseObject(msg, IcResiUserAddMQMsg.class); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        log.info("obj is {}",JSON.toJSONString(obj)); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        DistributedLock distributedLock = null; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        RLock lock = null; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        try { | 
				
			
			
		
	
	
		
			
				
					| 
						
							
								
							
						
						
						
					 | 
				
				 | 
				
					
  |