mirror of
https://gitee.com/pan648540858/wvp-GB28181-pro.git
synced 2026-05-15 10:07:50 +08:00
[集群-自动切换过国标级联] 修复BUG
This commit is contained in:
parent
0566bf916f
commit
347b2a6a4c
@ -117,10 +117,16 @@ public class PlatformServiceImpl implements IPlatformService {
|
||||
return;
|
||||
}
|
||||
serverIds.forEach(serverId -> {
|
||||
log.info("[集群] 检测到 {} 已离线", serverId);
|
||||
// 检查每个是否存活
|
||||
ServerInfo serverInfo = redisCatchStorage.queryServerInfo(serverId);
|
||||
if (serverInfo == null && userSetting.getServerId().equals(redisCatchStorage.chooseOneServer(serverId))) {
|
||||
if (serverInfo != null) {
|
||||
return;
|
||||
}else {
|
||||
log.info("[集群] 检测到 {} 已离线", serverId);
|
||||
String chooseServerId = redisCatchStorage.chooseOneServer(serverId);
|
||||
if (!userSetting.getServerId().equals(chooseServerId)){
|
||||
return;
|
||||
}
|
||||
// 此平台需要选择新平台处理, 确定由当前平台即开始处理
|
||||
List<Platform> platformList = platformMapper.queryByServerId(serverId);
|
||||
platformList.forEach(platform -> {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user