| | |
| | | |
| | | import com.genersoft.iot.vmp.conf.MediaConfig; |
| | | import com.genersoft.iot.vmp.media.zlm.ZLMServerConfig; |
| | | import com.genersoft.iot.vmp.media.zlm.dto.IMediaServerItem; |
| | | import com.genersoft.iot.vmp.media.zlm.dto.MediaServerItem; |
| | | import com.genersoft.iot.vmp.service.IMediaServerService; |
| | | import com.genersoft.iot.vmp.storager.IRedisCatchStorage; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.http.HttpStatus; |
| | |
| | | |
| | | @Autowired |
| | | private IRedisCatchStorage redisCatchStorage; |
| | | @Autowired |
| | | private IMediaServerService mediaServerService; |
| | | |
| | | @Autowired |
| | | private MediaConfig mediaConfig; |
| | |
| | | return null; |
| | | } |
| | | // 后续改为根据Id获取对应的ZLM |
| | | ZLMServerConfig mediaInfo = redisCatchStorage.getMediaInfo(); |
| | | IMediaServerItem mediaInfo = mediaServerService.getOne(mediaId); |
| | | if (mediaInfo == null) { |
| | | response.setStatus(HttpStatus.NOT_FOUND.value()); |
| | | return null; |
| | | } |
| | | String requestURI = String.format("http://%s:%s%s?%s", |
| | | mediaInfo.getSdpIp(), |
| | | mediaConfig.getRecordAssistPort(), |