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

Clock syncing with CDN servers make the player go out of sync #205

Closed
kfwerf opened this issue Oct 15, 2015 · 3 comments
Closed

Clock syncing with CDN servers make the player go out of sync #205

kfwerf opened this issue Oct 15, 2015 · 3 comments
Assignees
Labels
status: archived Archived and locked; will not be updated type: bug Something isn't working correctly
Milestone

Comments

@kfwerf
Copy link

kfwerf commented Oct 15, 2015

The attempt in the ajax request to sync the player with date headers from the fragment servers causes issues when cdn servers are using the date header to indicate the time of the caching.

https://github.com/google/shaka-player/blob/master/lib/util/ajax_request.js#L457

For us that means that we have to outcomment this line as it makes our video player run out of sync. Is there a way to fix this easily?

@joeyparrish joeyparrish added the type: question A question from the community label Oct 15, 2015
@joeyparrish joeyparrish self-assigned this Oct 15, 2015
@joeyparrish
Copy link
Member

Hrm... based on my understanding of the Date header, it should always be the time at which the response is sent. Am I mistaken? It seems that the CDN is at fault on that.

While we debate the validity of what the CDN is doing, unfortunately, you'll have to comment out the clock sync code to work around it.

@joeyparrish
Copy link
Member

My colleague has just pointed me to his comment on #191:

Date gives the time when the content was created; not when it was transported (see https://tools.ietf.org/html/rfc7231#section-7.1.1.2).

So it looks like my Date-based sync may be fundamentally flawed. We will need to decide internally what to do about it. Sorry for the inconvenience.

@joeyparrish joeyparrish added type: bug Something isn't working correctly and removed type: question A question from the community labels Oct 15, 2015
@joeyparrish joeyparrish added this to the Future milestone Oct 22, 2015
@joeyparrish
Copy link
Member

The current plan is to abandon Date-based sync in v2.0. Since some CDNs seem to behave differently on this, and since we don't have an alternative clock sync mechanism ready, we will leave the current behavior for v1.x. Until v2.0 is ready, you may wish to customize your build of the library and remove Date-based sync.

@joeyparrish joeyparrish modified the milestones: v2.0.0, v2.0-beta Jan 5, 2016
joeyparrish pushed a commit that referenced this issue Jan 25, 2016
Closes #205
Closes #241

Change-Id: Ieb870466bc6c38ee4a4e4919afcf15164cf8e981
@shaka-project shaka-project locked and limited conversation to collaborators Mar 22, 2018
@shaka-bot shaka-bot added the status: archived Archived and locked; will not be updated label Apr 15, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
status: archived Archived and locked; will not be updated type: bug Something isn't working correctly
Projects
None yet
Development

No branches or pull requests

4 participants