Commit e8770eec36cb7294899ee96f0f66028e9358caf8
Merge branch '2.6.9' into wvp-28181-2.0
Showing
15 changed files
with
32 additions
and
2 deletions
src/main/java/com/genersoft/iot/vmp/service/impl/DeviceAlarmServiceImpl.java
| 1 | package com.genersoft.iot.vmp.service.impl; | 1 | package com.genersoft.iot.vmp.service.impl; |
| 2 | 2 | ||
| 3 | +import com.baomidou.dynamic.datasource.annotation.DS; | ||
| 3 | import com.genersoft.iot.vmp.gb28181.bean.DeviceAlarm; | 4 | import com.genersoft.iot.vmp.gb28181.bean.DeviceAlarm; |
| 4 | import com.genersoft.iot.vmp.media.zlm.dto.StreamProxyItem; | 5 | import com.genersoft.iot.vmp.media.zlm.dto.StreamProxyItem; |
| 5 | import com.genersoft.iot.vmp.service.IDeviceAlarmService; | 6 | import com.genersoft.iot.vmp.service.IDeviceAlarmService; |
| @@ -12,6 +13,7 @@ import org.springframework.stereotype.Service; | @@ -12,6 +13,7 @@ import org.springframework.stereotype.Service; | ||
| 12 | import java.util.List; | 13 | import java.util.List; |
| 13 | 14 | ||
| 14 | @Service | 15 | @Service |
| 16 | +@DS("master") | ||
| 15 | public class DeviceAlarmServiceImpl implements IDeviceAlarmService { | 17 | public class DeviceAlarmServiceImpl implements IDeviceAlarmService { |
| 16 | 18 | ||
| 17 | @Autowired | 19 | @Autowired |
src/main/java/com/genersoft/iot/vmp/service/impl/DeviceChannelServiceImpl.java
| 1 | package com.genersoft.iot.vmp.service.impl; | 1 | package com.genersoft.iot.vmp.service.impl; |
| 2 | 2 | ||
| 3 | +import com.baomidou.dynamic.datasource.annotation.DS; | ||
| 3 | import com.genersoft.iot.vmp.common.InviteInfo; | 4 | import com.genersoft.iot.vmp.common.InviteInfo; |
| 4 | import com.genersoft.iot.vmp.common.InviteSessionType; | 5 | import com.genersoft.iot.vmp.common.InviteSessionType; |
| 5 | import com.genersoft.iot.vmp.gb28181.bean.Device; | 6 | import com.genersoft.iot.vmp.gb28181.bean.Device; |
| @@ -27,6 +28,7 @@ import java.util.concurrent.CopyOnWriteArrayList; | @@ -27,6 +28,7 @@ import java.util.concurrent.CopyOnWriteArrayList; | ||
| 27 | * @author lin | 28 | * @author lin |
| 28 | */ | 29 | */ |
| 29 | @Service | 30 | @Service |
| 31 | +@DS("master") | ||
| 30 | public class DeviceChannelServiceImpl implements IDeviceChannelService { | 32 | public class DeviceChannelServiceImpl implements IDeviceChannelService { |
| 31 | 33 | ||
| 32 | private final static Logger logger = LoggerFactory.getLogger(DeviceChannelServiceImpl.class); | 34 | private final static Logger logger = LoggerFactory.getLogger(DeviceChannelServiceImpl.class); |
src/main/java/com/genersoft/iot/vmp/service/impl/DeviceServiceImpl.java
| 1 | package com.genersoft.iot.vmp.service.impl; | 1 | package com.genersoft.iot.vmp.service.impl; |
| 2 | 2 | ||
| 3 | +import com.baomidou.dynamic.datasource.annotation.DS; | ||
| 3 | import com.genersoft.iot.vmp.common.VideoManagerConstants; | 4 | import com.genersoft.iot.vmp.common.VideoManagerConstants; |
| 4 | import com.genersoft.iot.vmp.conf.DynamicTask; | 5 | import com.genersoft.iot.vmp.conf.DynamicTask; |
| 5 | import com.genersoft.iot.vmp.conf.UserSetting; | 6 | import com.genersoft.iot.vmp.conf.UserSetting; |
| @@ -45,6 +46,7 @@ import java.util.concurrent.TimeUnit; | @@ -45,6 +46,7 @@ import java.util.concurrent.TimeUnit; | ||
| 45 | * 设备业务(目录订阅) | 46 | * 设备业务(目录订阅) |
| 46 | */ | 47 | */ |
| 47 | @Service | 48 | @Service |
| 49 | +@DS("master") | ||
| 48 | public class DeviceServiceImpl implements IDeviceService { | 50 | public class DeviceServiceImpl implements IDeviceService { |
| 49 | 51 | ||
| 50 | private final static Logger logger = LoggerFactory.getLogger(DeviceServiceImpl.class); | 52 | private final static Logger logger = LoggerFactory.getLogger(DeviceServiceImpl.class); |
src/main/java/com/genersoft/iot/vmp/service/impl/GbStreamServiceImpl.java
| 1 | package com.genersoft.iot.vmp.service.impl; | 1 | package com.genersoft.iot.vmp.service.impl; |
| 2 | 2 | ||
| 3 | +import com.baomidou.dynamic.datasource.annotation.DS; | ||
| 3 | import com.genersoft.iot.vmp.gb28181.bean.*; | 4 | import com.genersoft.iot.vmp.gb28181.bean.*; |
| 4 | import com.genersoft.iot.vmp.gb28181.event.EventPublisher; | 5 | import com.genersoft.iot.vmp.gb28181.event.EventPublisher; |
| 5 | import com.genersoft.iot.vmp.gb28181.event.subscribe.catalog.CatalogEvent; | 6 | import com.genersoft.iot.vmp.gb28181.event.subscribe.catalog.CatalogEvent; |
| @@ -25,6 +26,7 @@ import java.util.ArrayList; | @@ -25,6 +26,7 @@ import java.util.ArrayList; | ||
| 25 | import java.util.List; | 26 | import java.util.List; |
| 26 | 27 | ||
| 27 | @Service | 28 | @Service |
| 29 | +@DS("master") | ||
| 28 | public class GbStreamServiceImpl implements IGbStreamService { | 30 | public class GbStreamServiceImpl implements IGbStreamService { |
| 29 | 31 | ||
| 30 | private final static Logger logger = LoggerFactory.getLogger(GbStreamServiceImpl.class); | 32 | private final static Logger logger = LoggerFactory.getLogger(GbStreamServiceImpl.class); |
src/main/java/com/genersoft/iot/vmp/service/impl/InviteStreamServiceImpl.java
| 1 | package com.genersoft.iot.vmp.service.impl; | 1 | package com.genersoft.iot.vmp.service.impl; |
| 2 | 2 | ||
| 3 | import com.alibaba.fastjson2.JSON; | 3 | import com.alibaba.fastjson2.JSON; |
| 4 | +import com.baomidou.dynamic.datasource.annotation.DS; | ||
| 4 | import com.genersoft.iot.vmp.common.InviteInfo; | 5 | import com.genersoft.iot.vmp.common.InviteInfo; |
| 5 | import com.genersoft.iot.vmp.common.InviteSessionStatus; | 6 | import com.genersoft.iot.vmp.common.InviteSessionStatus; |
| 6 | import com.genersoft.iot.vmp.common.InviteSessionType; | 7 | import com.genersoft.iot.vmp.common.InviteSessionType; |
| @@ -20,6 +21,7 @@ import java.util.concurrent.ConcurrentHashMap; | @@ -20,6 +21,7 @@ import java.util.concurrent.ConcurrentHashMap; | ||
| 20 | import java.util.concurrent.CopyOnWriteArrayList; | 21 | import java.util.concurrent.CopyOnWriteArrayList; |
| 21 | 22 | ||
| 22 | @Service | 23 | @Service |
| 24 | +@DS("master") | ||
| 23 | public class InviteStreamServiceImpl implements IInviteStreamService { | 25 | public class InviteStreamServiceImpl implements IInviteStreamService { |
| 24 | 26 | ||
| 25 | private final Logger logger = LoggerFactory.getLogger(InviteStreamServiceImpl.class); | 27 | private final Logger logger = LoggerFactory.getLogger(InviteStreamServiceImpl.class); |
src/main/java/com/genersoft/iot/vmp/service/impl/LogServiceImpl.java
| 1 | package com.genersoft.iot.vmp.service.impl; | 1 | package com.genersoft.iot.vmp.service.impl; |
| 2 | 2 | ||
| 3 | +import com.baomidou.dynamic.datasource.annotation.DS; | ||
| 3 | import com.genersoft.iot.vmp.gb28181.bean.DeviceAlarm; | 4 | import com.genersoft.iot.vmp.gb28181.bean.DeviceAlarm; |
| 4 | import com.genersoft.iot.vmp.service.ILogService; | 5 | import com.genersoft.iot.vmp.service.ILogService; |
| 5 | import com.genersoft.iot.vmp.storager.dao.LogMapper; | 6 | import com.genersoft.iot.vmp.storager.dao.LogMapper; |
| @@ -12,6 +13,7 @@ import org.springframework.stereotype.Service; | @@ -12,6 +13,7 @@ import org.springframework.stereotype.Service; | ||
| 12 | import java.util.List; | 13 | import java.util.List; |
| 13 | 14 | ||
| 14 | @Service | 15 | @Service |
| 16 | +@DS("master") | ||
| 15 | public class LogServiceImpl implements ILogService { | 17 | public class LogServiceImpl implements ILogService { |
| 16 | 18 | ||
| 17 | @Autowired | 19 | @Autowired |
src/main/java/com/genersoft/iot/vmp/service/impl/MediaServerServiceImpl.java
| @@ -3,6 +3,7 @@ package com.genersoft.iot.vmp.service.impl; | @@ -3,6 +3,7 @@ package com.genersoft.iot.vmp.service.impl; | ||
| 3 | import com.alibaba.fastjson2.JSON; | 3 | import com.alibaba.fastjson2.JSON; |
| 4 | import com.alibaba.fastjson2.JSONArray; | 4 | import com.alibaba.fastjson2.JSONArray; |
| 5 | import com.alibaba.fastjson2.JSONObject; | 5 | import com.alibaba.fastjson2.JSONObject; |
| 6 | +import com.baomidou.dynamic.datasource.annotation.DS; | ||
| 6 | import com.genersoft.iot.vmp.common.CommonCallback; | 7 | import com.genersoft.iot.vmp.common.CommonCallback; |
| 7 | import com.genersoft.iot.vmp.common.VideoManagerConstants; | 8 | import com.genersoft.iot.vmp.common.VideoManagerConstants; |
| 8 | import com.genersoft.iot.vmp.conf.DynamicTask; | 9 | import com.genersoft.iot.vmp.conf.DynamicTask; |
| @@ -53,6 +54,7 @@ import java.util.concurrent.ExecutionException; | @@ -53,6 +54,7 @@ import java.util.concurrent.ExecutionException; | ||
| 53 | * 媒体服务器节点管理 | 54 | * 媒体服务器节点管理 |
| 54 | */ | 55 | */ |
| 55 | @Service | 56 | @Service |
| 57 | +@DS("master") | ||
| 56 | public class MediaServerServiceImpl implements IMediaServerService { | 58 | public class MediaServerServiceImpl implements IMediaServerService { |
| 57 | 59 | ||
| 58 | private final static Logger logger = LoggerFactory.getLogger(MediaServerServiceImpl.class); | 60 | private final static Logger logger = LoggerFactory.getLogger(MediaServerServiceImpl.class); |
| @@ -306,7 +308,6 @@ public class MediaServerServiceImpl implements IMediaServerService { | @@ -306,7 +308,6 @@ public class MediaServerServiceImpl implements IMediaServerService { | ||
| 306 | 308 | ||
| 307 | @Override | 309 | @Override |
| 308 | public MediaServerItem getDefaultMediaServer() { | 310 | public MediaServerItem getDefaultMediaServer() { |
| 309 | - | ||
| 310 | return mediaServerMapper.queryDefault(); | 311 | return mediaServerMapper.queryDefault(); |
| 311 | } | 312 | } |
| 312 | 313 |
src/main/java/com/genersoft/iot/vmp/service/impl/PlatformChannelServiceImpl.java
| 1 | package com.genersoft.iot.vmp.service.impl; | 1 | package com.genersoft.iot.vmp.service.impl; |
| 2 | 2 | ||
| 3 | +import com.baomidou.dynamic.datasource.annotation.DS; | ||
| 3 | import com.genersoft.iot.vmp.gb28181.bean.*; | 4 | import com.genersoft.iot.vmp.gb28181.bean.*; |
| 4 | import com.genersoft.iot.vmp.gb28181.event.EventPublisher; | 5 | import com.genersoft.iot.vmp.gb28181.event.EventPublisher; |
| 5 | import com.genersoft.iot.vmp.gb28181.event.subscribe.catalog.CatalogEvent; | 6 | import com.genersoft.iot.vmp.gb28181.event.subscribe.catalog.CatalogEvent; |
| @@ -27,6 +28,7 @@ import java.util.Map; | @@ -27,6 +28,7 @@ import java.util.Map; | ||
| 27 | * @author lin | 28 | * @author lin |
| 28 | */ | 29 | */ |
| 29 | @Service | 30 | @Service |
| 31 | +@DS("master") | ||
| 30 | public class PlatformChannelServiceImpl implements IPlatformChannelService { | 32 | public class PlatformChannelServiceImpl implements IPlatformChannelService { |
| 31 | 33 | ||
| 32 | private final static Logger logger = LoggerFactory.getLogger(PlatformChannelServiceImpl.class); | 34 | private final static Logger logger = LoggerFactory.getLogger(PlatformChannelServiceImpl.class); |
src/main/java/com/genersoft/iot/vmp/service/impl/PlatformServiceImpl.java
| 1 | package com.genersoft.iot.vmp.service.impl; | 1 | package com.genersoft.iot.vmp.service.impl; |
| 2 | 2 | ||
| 3 | +import com.baomidou.dynamic.datasource.annotation.DS; | ||
| 3 | import com.genersoft.iot.vmp.conf.DynamicTask; | 4 | import com.genersoft.iot.vmp.conf.DynamicTask; |
| 4 | import com.genersoft.iot.vmp.conf.UserSetting; | 5 | import com.genersoft.iot.vmp.conf.UserSetting; |
| 5 | import com.genersoft.iot.vmp.gb28181.bean.*; | 6 | import com.genersoft.iot.vmp.gb28181.bean.*; |
| @@ -38,6 +39,7 @@ import java.util.*; | @@ -38,6 +39,7 @@ import java.util.*; | ||
| 38 | * @author lin | 39 | * @author lin |
| 39 | */ | 40 | */ |
| 40 | @Service | 41 | @Service |
| 42 | +@DS("master") | ||
| 41 | public class PlatformServiceImpl implements IPlatformService { | 43 | public class PlatformServiceImpl implements IPlatformService { |
| 42 | 44 | ||
| 43 | private final static String REGISTER_KEY_PREFIX = "platform_register_"; | 45 | private final static String REGISTER_KEY_PREFIX = "platform_register_"; |
src/main/java/com/genersoft/iot/vmp/service/impl/PlayServiceImpl.java
| @@ -2,6 +2,7 @@ package com.genersoft.iot.vmp.service.impl; | @@ -2,6 +2,7 @@ package com.genersoft.iot.vmp.service.impl; | ||
| 2 | 2 | ||
| 3 | import com.alibaba.fastjson2.JSONArray; | 3 | import com.alibaba.fastjson2.JSONArray; |
| 4 | import com.alibaba.fastjson2.JSONObject; | 4 | import com.alibaba.fastjson2.JSONObject; |
| 5 | +import com.baomidou.dynamic.datasource.annotation.DS; | ||
| 5 | import com.genersoft.iot.vmp.common.InviteInfo; | 6 | import com.genersoft.iot.vmp.common.InviteInfo; |
| 6 | import com.genersoft.iot.vmp.common.InviteSessionStatus; | 7 | import com.genersoft.iot.vmp.common.InviteSessionStatus; |
| 7 | import com.genersoft.iot.vmp.common.InviteSessionType; | 8 | import com.genersoft.iot.vmp.common.InviteSessionType; |
| @@ -53,6 +54,7 @@ import java.util.Vector; | @@ -53,6 +54,7 @@ import java.util.Vector; | ||
| 53 | 54 | ||
| 54 | @SuppressWarnings(value = {"rawtypes", "unchecked"}) | 55 | @SuppressWarnings(value = {"rawtypes", "unchecked"}) |
| 55 | @Service | 56 | @Service |
| 57 | +@DS("master") | ||
| 56 | public class PlayServiceImpl implements IPlayService { | 58 | public class PlayServiceImpl implements IPlayService { |
| 57 | 59 | ||
| 58 | private final static Logger logger = LoggerFactory.getLogger(PlayServiceImpl.class); | 60 | private final static Logger logger = LoggerFactory.getLogger(PlayServiceImpl.class); |
src/main/java/com/genersoft/iot/vmp/service/impl/RoleServerImpl.java
| 1 | package com.genersoft.iot.vmp.service.impl; | 1 | package com.genersoft.iot.vmp.service.impl; |
| 2 | 2 | ||
| 3 | +import com.baomidou.dynamic.datasource.annotation.DS; | ||
| 3 | import com.genersoft.iot.vmp.service.IRoleService; | 4 | import com.genersoft.iot.vmp.service.IRoleService; |
| 4 | import com.genersoft.iot.vmp.storager.dao.RoleMapper; | 5 | import com.genersoft.iot.vmp.storager.dao.RoleMapper; |
| 5 | import com.genersoft.iot.vmp.storager.dao.dto.Role; | 6 | import com.genersoft.iot.vmp.storager.dao.dto.Role; |
| @@ -9,6 +10,7 @@ import org.springframework.stereotype.Service; | @@ -9,6 +10,7 @@ import org.springframework.stereotype.Service; | ||
| 9 | import java.util.List; | 10 | import java.util.List; |
| 10 | 11 | ||
| 11 | @Service | 12 | @Service |
| 13 | +@DS("master") | ||
| 12 | public class RoleServerImpl implements IRoleService { | 14 | public class RoleServerImpl implements IRoleService { |
| 13 | 15 | ||
| 14 | @Autowired | 16 | @Autowired |
src/main/java/com/genersoft/iot/vmp/service/impl/StreamProxyServiceImpl.java
| @@ -2,6 +2,7 @@ package com.genersoft.iot.vmp.service.impl; | @@ -2,6 +2,7 @@ package com.genersoft.iot.vmp.service.impl; | ||
| 2 | 2 | ||
| 3 | import com.alibaba.fastjson2.JSONArray; | 3 | import com.alibaba.fastjson2.JSONArray; |
| 4 | import com.alibaba.fastjson2.JSONObject; | 4 | import com.alibaba.fastjson2.JSONObject; |
| 5 | +import com.baomidou.dynamic.datasource.annotation.DS; | ||
| 5 | import com.genersoft.iot.vmp.common.GeneralCallback; | 6 | import com.genersoft.iot.vmp.common.GeneralCallback; |
| 6 | import com.genersoft.iot.vmp.common.StreamInfo; | 7 | import com.genersoft.iot.vmp.common.StreamInfo; |
| 7 | import com.genersoft.iot.vmp.conf.DynamicTask; | 8 | import com.genersoft.iot.vmp.conf.DynamicTask; |
| @@ -53,6 +54,7 @@ import java.util.stream.Collectors; | @@ -53,6 +54,7 @@ import java.util.stream.Collectors; | ||
| 53 | * 视频代理业务 | 54 | * 视频代理业务 |
| 54 | */ | 55 | */ |
| 55 | @Service | 56 | @Service |
| 57 | +@DS("master") | ||
| 56 | public class StreamProxyServiceImpl implements IStreamProxyService { | 58 | public class StreamProxyServiceImpl implements IStreamProxyService { |
| 57 | 59 | ||
| 58 | private final static Logger logger = LoggerFactory.getLogger(StreamProxyServiceImpl.class); | 60 | private final static Logger logger = LoggerFactory.getLogger(StreamProxyServiceImpl.class); |
src/main/java/com/genersoft/iot/vmp/service/impl/StreamPushServiceImpl.java
| @@ -4,6 +4,7 @@ import com.alibaba.fastjson2.JSON; | @@ -4,6 +4,7 @@ import com.alibaba.fastjson2.JSON; | ||
| 4 | import com.alibaba.fastjson2.JSONArray; | 4 | import com.alibaba.fastjson2.JSONArray; |
| 5 | import com.alibaba.fastjson2.JSONObject; | 5 | import com.alibaba.fastjson2.JSONObject; |
| 6 | import com.alibaba.fastjson2.TypeReference; | 6 | import com.alibaba.fastjson2.TypeReference; |
| 7 | +import com.baomidou.dynamic.datasource.annotation.DS; | ||
| 7 | import com.genersoft.iot.vmp.conf.MediaConfig; | 8 | import com.genersoft.iot.vmp.conf.MediaConfig; |
| 8 | import com.genersoft.iot.vmp.conf.UserSetting; | 9 | import com.genersoft.iot.vmp.conf.UserSetting; |
| 9 | import com.genersoft.iot.vmp.gb28181.bean.*; | 10 | import com.genersoft.iot.vmp.gb28181.bean.*; |
| @@ -36,6 +37,7 @@ import java.util.*; | @@ -36,6 +37,7 @@ import java.util.*; | ||
| 36 | import java.util.stream.Collectors; | 37 | import java.util.stream.Collectors; |
| 37 | 38 | ||
| 38 | @Service | 39 | @Service |
| 40 | +@DS("master") | ||
| 39 | public class StreamPushServiceImpl implements IStreamPushService { | 41 | public class StreamPushServiceImpl implements IStreamPushService { |
| 40 | 42 | ||
| 41 | private final static Logger logger = LoggerFactory.getLogger(StreamPushServiceImpl.class); | 43 | private final static Logger logger = LoggerFactory.getLogger(StreamPushServiceImpl.class); |
src/main/java/com/genersoft/iot/vmp/service/impl/UserServiceImpl.java
| 1 | package com.genersoft.iot.vmp.service.impl; | 1 | package com.genersoft.iot.vmp.service.impl; |
| 2 | 2 | ||
| 3 | +import com.baomidou.dynamic.datasource.annotation.DS; | ||
| 3 | import com.genersoft.iot.vmp.service.IUserService; | 4 | import com.genersoft.iot.vmp.service.IUserService; |
| 4 | import com.genersoft.iot.vmp.storager.dao.UserMapper; | 5 | import com.genersoft.iot.vmp.storager.dao.UserMapper; |
| 5 | import com.genersoft.iot.vmp.storager.dao.dto.User; | 6 | import com.genersoft.iot.vmp.storager.dao.dto.User; |
| @@ -12,6 +13,7 @@ import org.springframework.util.DigestUtils; | @@ -12,6 +13,7 @@ import org.springframework.util.DigestUtils; | ||
| 12 | import java.util.List; | 13 | import java.util.List; |
| 13 | 14 | ||
| 14 | @Service | 15 | @Service |
| 16 | +@DS("master") | ||
| 15 | public class UserServiceImpl implements IUserService { | 17 | public class UserServiceImpl implements IUserService { |
| 16 | 18 | ||
| 17 | @Autowired | 19 | @Autowired |
src/main/java/com/genersoft/iot/vmp/vmanager/cloudRecord/CloudRecordController.java
| @@ -197,7 +197,10 @@ public class CloudRecordController { | @@ -197,7 +197,10 @@ public class CloudRecordController { | ||
| 197 | @RequestParam(required = false) String mediaServerId, | 197 | @RequestParam(required = false) String mediaServerId, |
| 198 | @RequestParam(required = false) Boolean isEnd | 198 | @RequestParam(required = false) Boolean isEnd |
| 199 | ){ | 199 | ){ |
| 200 | - return cloudRecordService.queryTask(app, stream, callId, taskId, mediaServerId, isEnd); | 200 | + if (ObjectUtils.isEmpty(mediaServerId)) { |
| 201 | + mediaServerId = null; | ||
| 202 | + } | ||
| 203 | + return cloudRecordService.queryTask(app, stream, callId, taskId, mediaServerId, isEnd); | ||
| 201 | } | 204 | } |
| 202 | 205 | ||
| 203 | @ResponseBody | 206 | @ResponseBody |