Esempio n. 1
0
        public void Post(ReportPlaybackStopped request)
        {
            request.SessionId = GetSession().Result.Id;

            var task = _sessionManager.OnPlaybackStopped(request);

            Task.WaitAll(task);
        }
Esempio n. 2
0
        public async Task Post(ReportPlaybackStopped request)
        {
            Logger.LogDebug("ReportPlaybackStopped PlaySessionId: {0}", request.PlaySessionId ?? string.Empty);

            if (!string.IsNullOrWhiteSpace(request.PlaySessionId))
            {
                await ApiEntryPoint.Instance.KillTranscodingJobs(_authContext.GetAuthorizationInfo(Request).DeviceId, request.PlaySessionId, s => true);
            }

            request.SessionId = GetSession(_sessionContext).Id;

            await _sessionManager.OnPlaybackStopped(request);
        }
Esempio n. 3
0
        public void Post(ReportPlaybackStopped request)
        {
            if (!string.IsNullOrWhiteSpace(request.PlaySessionId))
            {
                ApiEntryPoint.Instance.KillTranscodingJobs(AuthorizationContext.GetAuthorizationInfo(Request).DeviceId, request.PlaySessionId, s => true);
            }

            request.SessionId = GetSession().Result.Id;

            var task = _sessionManager.OnPlaybackStopped(request);

            Task.WaitAll(task);
        }