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

feat: SegmentIndex minimal interface #6095

Merged
merged 1 commit into from
Jan 12, 2024

Conversation

tykus160
Copy link
Member

Motivation: we (Sky/Peacock) were working on custom manifest parser and we wanted to use similar approach to shaka.dash.TimelineSegmentIndex but adjusted to our needs and data structure.

So similar to that, we extended base SegmentIndex class with our implementation, but MetaSegmentIndex didn't work correctly with this implementation due to 2 issues:

  1. MetaSegmentIndex uses protected numEvicted_ field that we cannot modify externally in any way.
  2. Even adding exported getNumEvicted() method wasn't enough, because Closure Compiler optimization was aliasing internal call to this method in MetaSegmentIndex for some reason.

By moving crucial APIs to extern we can overcome this issue. Still, preferred way of using own SegmentIndex implementation is by extending base class, as it offers SegmentIterator out of the box.

@tykus160 tykus160 changed the title fix: SegmentIndex minimal interface feat: SegmentIndex minimal interface Jan 12, 2024
@avelad avelad added type: enhancement New feature or request priority: P3 Useful but not urgent labels Jan 12, 2024
@avelad avelad added this to the v5.0 milestone Jan 12, 2024
@avelad avelad requested review from theodab and littlespex January 12, 2024 10:18
@avelad avelad merged commit f064811 into shaka-project:main Jan 12, 2024
16 of 20 checks passed
@shaka-bot shaka-bot added the status: archived Archived and locked; will not be updated label Mar 12, 2024
@shaka-project shaka-project locked as resolved and limited conversation to collaborators Mar 12, 2024
@tykus160 tykus160 deleted the wt-segment-index branch June 11, 2024 13:27
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
priority: P3 Useful but not urgent status: archived Archived and locked; will not be updated type: enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants