RTP分配端口 <= 0 为失败
This commit is contained in:
parent
20db882bf6
commit
f88ff28dc4
@ -484,6 +484,15 @@ public class InviteRequestProcessor extends SIPRequestProcessorParent implements
|
|||||||
String endTimeStr = DateUtil.urlFormatter.format(end);
|
String endTimeStr = DateUtil.urlFormatter.format(end);
|
||||||
String stream = device.getDeviceId() + "_" + channelId + "_" + startTimeStr + "_" + endTimeStr;
|
String stream = device.getDeviceId() + "_" + channelId + "_" + startTimeStr + "_" + endTimeStr;
|
||||||
SSRCInfo ssrcInfo = mediaServerService.openRTPServer(mediaServerItem, stream, null, device.isSsrcCheck(), true, 0, false, device.getStreamModeForParam());
|
SSRCInfo ssrcInfo = mediaServerService.openRTPServer(mediaServerItem, stream, null, device.isSsrcCheck(), true, 0, false, device.getStreamModeForParam());
|
||||||
|
if(ssrcInfo.getPort() <= 0){
|
||||||
|
logger.warn("服务器端口资源不足");
|
||||||
|
try {
|
||||||
|
responseAck(request, Response.BUSY_HERE);
|
||||||
|
} catch (SipException | InvalidArgumentException | ParseException e) {
|
||||||
|
logger.error("[命令发送失败] invite 服务器端口资源不足: {}", e.getMessage());
|
||||||
|
}
|
||||||
|
return;
|
||||||
|
}
|
||||||
sendRtpItem.setStreamId(ssrcInfo.getStream());
|
sendRtpItem.setStreamId(ssrcInfo.getStream());
|
||||||
// 写入redis, 超时时回复
|
// 写入redis, 超时时回复
|
||||||
redisCatchStorage.updateSendRTPSever(sendRtpItem);
|
redisCatchStorage.updateSendRTPSever(sendRtpItem);
|
||||||
|
Loading…
Reference in New Issue
Block a user