修复通道位置的展示

This commit is contained in:
648540858
2024-04-17 17:56:36 +08:00
parent bf6e09d231
commit 313243195e
10 changed files with 75 additions and 23 deletions

View File

@@ -186,6 +186,18 @@ public class DeviceChannel {
@Schema(description = "纬度")
private double latitude;
/**
* 经度
*/
@Schema(description = "自定义经度")
private double customLongitude;
/**
* 纬度
*/
@Schema(description = "自定义纬度")
private double customLatitude;
/**
* 经度 GCJ02
*/
@@ -586,4 +598,20 @@ public class DeviceChannel {
public void setStreamIdentification(String streamIdentification) {
this.streamIdentification = streamIdentification;
}
public double getCustomLongitude() {
return customLongitude;
}
public void setCustomLongitude(double customLongitude) {
this.customLongitude = customLongitude;
}
public double getCustomLatitude() {
return customLatitude;
}
public void setCustomLatitude(double customLatitude) {
this.customLatitude = customLatitude;
}
}

View File

@@ -117,7 +117,6 @@ public class AckRequestProcessor extends SIPRequestProcessorParent implements In
if (parentPlatform != null) {
Map<String, Object> param = getSendRtpParam(sendRtpItem);
if (!userSetting.getServerId().equals(sendRtpItem.getServerId())) {
// redisCatchStorage.sendStartSendRtp(sendRtpItem);
WVPResult wvpResult = redisRpcService.startSendRtp(sendRtpItem);
if (wvpResult.getCode() == 0) {
MessageForPushChannel messageForPushChannel = MessageForPushChannel.getInstance(0, sendRtpItem.getApp(), sendRtpItem.getStream(),

View File

@@ -138,10 +138,10 @@ public class ByeRequestProcessor extends SIPRequestProcessorParent implements In
redisCatchStorage.sendPlatformStopPlayMsg(sendRtpItem, platform);
if (!userSetting.getServerId().equals(sendRtpItem.getServerId())) {
redisRpcService.stopSendRtp(sendRtpItem);
redisCatchStorage.deleteSendRTPServer(null, null, sendRtpItem.getCallId(), null);
}else {
MediaServerItem mediaInfo = mediaServerService.getOne(sendRtpItem.getMediaServerId());
redisCatchStorage.deleteSendRTPServer(sendRtpItem.getPlatformId(), sendRtpItem.getChannelId(),
callIdHeader.getCallId(), null);
redisCatchStorage.deleteSendRTPServer(null, null, callIdHeader.getCallId(), null);
zlmServerFactory.stopSendRtpStream(mediaInfo, param);
if (userSetting.getUseCustomSsrcForParentInvite()) {
mediaServerService.releaseSsrc(mediaInfo.getId(), sendRtpItem.getSsrc());

View File

@@ -775,7 +775,7 @@ public class InviteRequestProcessor extends SIPRequestProcessorParent implements
redisRpcService.waitePushStreamOnline(sendRtpItem, (sendRtpItemFromRedis) -> {
dynamicTask.stop(sendRtpItem.getCallId());
if (sendRtpItemFromRedis.getServerId().equals(userSetting.getServerId())) {
logger.info("[级联点播] 等待的推流在本平台上线 {}/{}", sendRtpItem.getApp(), sendRtpItem.getStream());
int localPort = sendRtpPortManager.getNextPort(mediaServerItem);
if (localPort == 0) {
logger.warn("上级点时创建sendRTPItem失败可能是服务器端口资源不足");
@@ -827,7 +827,7 @@ public class InviteRequestProcessor extends SIPRequestProcessorParent implements
* 来自其他wvp的推流
*/
private void otherWvpPushStream(SendRtpItem sendRtpItem, SIPRequest request, ParentPlatform platform) {
logger.info("[级联点播]直播流来自其他平台发送redis消息");
logger.info("[级联点播] 来自其他wvp的推流 {}/{}", sendRtpItem.getApp(), sendRtpItem.getStream());
sendRtpItem = redisRpcService.getSendRtpItem(sendRtpItem);
// 写入redis 超时时回复
sendRtpItem.setStatus(1);

View File

@@ -180,6 +180,13 @@ public class NotifyRequestProcessor extends SIPRequestProcessorParent implements
logger.warn("[mobilePosition移动位置Notify] 未找到通道{}所属的设备", channelId);
return;
}
// 兼容设备部分设备上报是通道编号与设备编号一致的情况
if(deviceId.equals(channelId)) {
List<DeviceChannel> deviceChannels = deviceChannelService.queryChaneListByDeviceId(deviceId);
if (deviceChannels.size() == 1) {
channelId = deviceChannels.get(0).getChannelId();
}
}
if (!ObjectUtils.isEmpty(device.getName())) {
mobilePosition.setDeviceName(device.getName());
}