| | |
| | | @Autowired
|
| | | private UserSetup userSetup;
|
| | |
|
| | | public enum SessionType {
|
| | | play,
|
| | | playback,
|
| | | download
|
| | | }
|
| | |
|
| | | /**
|
| | | * 添加一个点播/回放的事务信息
|
| | | * 后续可以通过流Id/callID
|
| | |
| | | * @param mediaServerId 所使用的流媒体ID
|
| | | * @param transaction 事务
|
| | | */
|
| | | public void put(String deviceId, String channelId, String callId, String stream, String ssrc, String mediaServerId, ClientTransaction transaction){
|
| | | public void put(String deviceId, String channelId, String callId, String stream, String ssrc, String mediaServerId, ClientTransaction transaction, SessionType type){
|
| | | SsrcTransaction ssrcTransaction = new SsrcTransaction();
|
| | | ssrcTransaction.setDeviceId(deviceId);
|
| | | ssrcTransaction.setChannelId(channelId);
|
| | |
| | | ssrcTransaction.setCallId(callId);
|
| | | ssrcTransaction.setSsrc(ssrc);
|
| | | ssrcTransaction.setMediaServerId(mediaServerId);
|
| | | ssrcTransaction.setType(type);
|
| | |
|
| | | redisUtil.set(VideoManagerConstants.MEDIA_TRANSACTION_USED_PREFIX + userSetup.getServerId()
|
| | | + "_" + deviceId + "_" + channelId + "_" + callId + "_" + stream, ssrcTransaction);
|