|  |  | 
 |  |  | package com.genersoft.iot.vmp.conf;
 | 
 |  |  | 
 | 
 |  |  | import com.genersoft.iot.vmp.common.VideoManagerConstants;
 | 
 |  |  | import com.genersoft.iot.vmp.service.impl.RedisAlarmMsgListener;
 | 
 |  |  | import com.genersoft.iot.vmp.service.impl.RedisGPSMsgListener;
 | 
 |  |  | import org.apache.commons.lang3.StringUtils;
 | 
 |  |  | import org.springframework.beans.factory.annotation.Autowired;
 | 
 |  |  | 
 |  |  |    @Autowired
 | 
 |  |  |    private RedisGPSMsgListener redisGPSMsgListener;
 | 
 |  |  | 
 | 
 |  |  |    @Autowired
 | 
 |  |  |    private RedisAlarmMsgListener redisAlarmMsgListener;
 | 
 |  |  | 
 | 
 |  |  |    @Bean
 | 
 |  |  |    public JedisPool jedisPool() {
 | 
 |  |  |       if (StringUtils.isBlank(password)) {
 | 
 |  |  | 
 |  |  |         RedisMessageListenerContainer container = new RedisMessageListenerContainer();
 | 
 |  |  |         container.setConnectionFactory(connectionFactory);
 | 
 |  |  |       container.addMessageListener(redisGPSMsgListener, new PatternTopic(VideoManagerConstants.VM_MSG_GPS));
 | 
 |  |  |       container.addMessageListener(redisAlarmMsgListener, new PatternTopic(VideoManagerConstants.VM_MSG_SUBSCRIBE_ALARM_RECEIVE));
 | 
 |  |  |         return container;
 | 
 |  |  |     }
 | 
 |  |  | 
 |