临时提交

This commit is contained in:
panlinlin
2024-08-07 23:45:29 +08:00
parent fbbb4cb704
commit 3e220a2c1e
15 changed files with 302 additions and 79 deletions

View File

@@ -97,9 +97,6 @@ public class ParentPlatform {
@Schema(description = "是否作为消息通道")
private boolean asMessageChannel;
@Schema(description = "是否作为消息通道")
private boolean autoPushChannel;
@Schema(description = "点播回复200OK使用次IP")
private String sendStreamIp;

View File

@@ -32,6 +32,7 @@ import io.swagger.v3.oas.annotations.security.SecurityRequirement;
import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.util.Assert;
import org.springframework.util.ObjectUtils;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.context.request.async.DeferredResult;
@@ -90,9 +91,8 @@ public class PlayController {
@PathVariable String channelId) {
log.info("[开始点播] deviceId{}, channelId{}, ", deviceId, channelId);
if (ObjectUtils.isEmpty(deviceId) || ObjectUtils.isEmpty(channelId)) {
throw new ControllerException(ErrorCode.ERROR400);
}
Assert.notNull(deviceId, "设备国标编号不可为NULL");
Assert.notNull(channelId, "通道国标编号不可为NULL");
// 获取可用的zlm
Device device = deviceService.getDevice(deviceId);
MediaServer newMediaServerItem = playService.getNewMediaServerItem(device);

View File

@@ -24,6 +24,7 @@ import com.genersoft.iot.vmp.media.bean.MediaServer;
import com.genersoft.iot.vmp.media.event.hook.Hook;
import com.genersoft.iot.vmp.media.event.hook.HookSubscribe;
import com.genersoft.iot.vmp.media.event.hook.HookType;
import com.genersoft.iot.vmp.media.event.media.MediaArrivalEvent;
import com.genersoft.iot.vmp.media.service.IMediaServerService;
import com.genersoft.iot.vmp.media.zlm.SendRtpPortManager;
import com.genersoft.iot.vmp.media.zlm.dto.hook.OnStreamChangedHookParam;
@@ -597,10 +598,10 @@ public class InviteRequestProcessor extends SIPRequestProcessorParent implements
sendRtpItem.setPlayType(InviteStreamType.PUSH);
if (streamPushItem != null) {
// 从redis查询是否正在接收这个推流
OnStreamChangedHookParam pushListItem = redisCatchStorage.getPushListItem(gbStream.getApp(), gbStream.getStream());
if (pushListItem != null) {
sendRtpItem.setServerId(pushListItem.getSeverId());
sendRtpItem.setMediaServerId(pushListItem.getMediaServerId());
MediaArrivalEvent mediaArrivalEvent = redisCatchStorage.getPushListItem(gbStream.getApp(), gbStream.getStream());
if (mediaArrivalEvent != null) {
sendRtpItem.setServerId(mediaArrivalEvent.getServerId());
sendRtpItem.setMediaServerId(mediaArrivalEvent.getMediaServer().getId());
redisCatchStorage.updateSendRTPSever(sendRtpItem);
// 开始推流