From c859fe228ccc7d9e83d89e3c2513ae3548d4425f Mon Sep 17 00:00:00 2001
From: 648540858 <648540858@qq.com>
Date: 星期五, 30 九月 2022 09:25:15 +0800
Subject: [PATCH] 更新文档
---
src/main/java/com/genersoft/iot/vmp/service/impl/MediaServiceImpl.java | 12 ++++++++----
1 files changed, 8 insertions(+), 4 deletions(-)
diff --git a/src/main/java/com/genersoft/iot/vmp/service/impl/MediaServiceImpl.java b/src/main/java/com/genersoft/iot/vmp/service/impl/MediaServiceImpl.java
index 3e9b530..4785afe 100644
--- a/src/main/java/com/genersoft/iot/vmp/service/impl/MediaServiceImpl.java
+++ b/src/main/java/com/genersoft/iot/vmp/service/impl/MediaServiceImpl.java
@@ -25,7 +25,11 @@
private IRedisCatchStorage redisCatchStorage;
@Autowired
+ private IVideoManagerStorage storager;
+
+ @Autowired
private IMediaServerService mediaServerService;
+
@Autowired
private MediaConfig mediaConfig;
@@ -50,9 +54,10 @@
if (mediaInfo == null) {
return null;
}
+ String calld = null;
StreamAuthorityInfo streamAuthorityInfo = redisCatchStorage.getStreamAuthorityInfo(app, stream);
- if (streamAuthorityInfo == null) {
- return null;
+ if (streamAuthorityInfo != null) {
+ calld = streamAuthorityInfo.getCallId();
}
JSONObject mediaList = zlmresTfulUtils.getMediaList(mediaInfo, app, stream);
if (mediaList != null) {
@@ -64,11 +69,10 @@
JSONObject mediaJSON = JSON.parseObject(JSON.toJSONString(data.get(0)), JSONObject.class);
JSONArray tracks = mediaJSON.getJSONArray("tracks");
if (authority) {
- streamInfo = getStreamInfoByAppAndStream(mediaInfo, app, stream, tracks, addr,streamAuthorityInfo.getCallId(), true);
+ streamInfo = getStreamInfoByAppAndStream(mediaInfo, app, stream, tracks, addr, calld, true);
}else {
streamInfo = getStreamInfoByAppAndStream(mediaInfo, app, stream, tracks, addr,null, true);
}
-
}
}
return streamInfo;
--
Gitblit v1.8.0