Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tag EXT-X-DISCONTINUITY-SEQUENCE in media playlist #736

Open
javiercornejo opened this issue Nov 20, 2017 · 8 comments
Open

Tag EXT-X-DISCONTINUITY-SEQUENCE in media playlist #736

javiercornejo opened this issue Nov 20, 2017 · 8 comments

Comments

@javiercornejo
Copy link

Hi there.
First, I want to thank you this project.
We are using the "Continuous Live" feature and we implemented it with multi bitrate or multi mp4 quality for the same content. We have one and important issue, we noticed that EXT-X-DISCONTINUITY-SEQUENCE is not present in the playlist. Do you think there is a way to add this feature or is present modifying some parameter?
When this tag is not present cause a lot of buffer and playing issues in players because HLS standard said is client duty manage quality change looking for this sequence.
Hope you can help me.
Regards.

@erankor
Copy link
Contributor

erankor commented Nov 20, 2017

Hi,
That is correct, currently EXT-X-DISCONTINUITY-SEQUENCE is not being returned from this module. I think it should be quite easy to add it, need to verify.
But, which player are you using? live is working well for us without this tag, so I think the problem may be somewhere else (e.g. in the JSON you generate).
Also, is it easily reproducible? I may be able to create a branch for you with this tag to see if it helps

@javiercornejo
Copy link
Author

Hi @erankor
Thank you for you response. I missed the notification sorry for my delayed response.
We are using a player based on HLS.js. Yes it is easy reproducible, you just have to create two o more qualities (mp4s) for the same content and put them together in the same master.m3u8. Once you have it try to play this content with some hls.js demo and apply throttling with crhome.
I'll try to prepare some public demo and paste the link next.
@ghostnumber7 could you add extra info?
Regards.

@erankor
Copy link
Contributor

erankor commented Nov 23, 2017

We are using hls.js too, and it's working well for us, so I doubt it's related to this tag. Are you using the sample playlist.php to create the JSON, or you have your own implementation?

@ghostnumber7
Copy link

Hi @erankor
We are using our own implementation. Example JSON:

{  
   "playlistType":"live",
   "discontinuity":true,
   "initialSegmentIndex":3323,
   "initialClipIndex":58,
   "clipTimes":[  
      1511814517735
   ],
   "durations":[  
      1828000
   ],
   "sequences":[  
      {  
         "clips":[  
            {  
               "type":"source",
               "path":"/path/to/video/video-1-720p.mp4"
            }
         ]
      },
      {  
         "clips":[  
            {  
               "type":"source",
               "path":"/path/to/video/video-1-480p.mp4"
            }
         ]
      }
   ],
   "liveWindowDuration":40000
}

Normally sending only videos that should appear, ending in the last 10 seconds and / or starting in the next minute.

@erankor
Copy link
Contributor

erankor commented Nov 27, 2017

@ghostnumber7, as I wrote on some other issue recently, it's quite hard to get all the JSON parameters correctly for live. I suggest you try with the sample php script provided here -
https://github.com/kaltura/nginx-vod-module/blob/master/test/playlist.php
And assuming it works as expected, align your implementation with the logic of that script.

@javiercornejo
Copy link
Author

Thanks @erankor for your response and help. Anyway HLS RFC define EXT-X-DISCONTINUITY-SEQUENCE as a MUST in the Server Responsibility section. Manage this sequence is especially important when segments are removed from a playlist (Live).

If the server wishes to remove segments from a Media Playlist containing an EXT-X-DISCONTINUITY tag, the Media Playlist MUST contain an EXT-X-DISCONTINUITY-SEQUENCE tag. Without the EXT-X-DISCONTINUITY-SEQUENCE tag, it can be impossible for a client to locate corresponding segments between Renditions.
https://tools.ietf.org/html/rfc8216#section-6.2.1

Do you think we can add this feature to the module? Do you have some idea how this could be possible to implement?

Thank you!

@erankor
Copy link
Contributor

erankor commented Dec 3, 2017

Check out this pull - #751
However, as I previously wrote, I doubt this will fix the playback errors you are experiencing.

@erankor
Copy link
Contributor

erankor commented Dec 23, 2017

@javiercornejo, did you try the pull mentioned above?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

3 participants