Skip to content

VPAAMP-737: Playback fails when played DASH VOD assets#1708

Merged
pstroffolino merged 9 commits into
dev_sprint_25_2from
feature/VPAAMP-737
Jul 15, 2026
Merged

VPAAMP-737: Playback fails when played DASH VOD assets#1708
pstroffolino merged 9 commits into
dev_sprint_25_2from
feature/VPAAMP-737

Conversation

@psiva01

@psiva01 psiva01 commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

This pull request refines how SegmentBase content is fetched in the StreamAbstractionAAMP_MPD::FetchFragment method to address race conditions during asynchronous fragment downloads, especially during ABR (Adaptive Bitrate) profile switches. The main change ensures that all SegmentBase downloads (not just initialization segments) are handled synchronously to maintain consistency between the URL, IDX, and byte range, preventing partial fragment downloads that can confuse downstream parsers.

Improvements to SegmentBase fragment handling:

  • Changed the logic so that all SegmentBase content (both initialization and media segments using byte-range requests) is now fetched synchronously, rather than only initialization segments, to prevent race conditions and ensure consistency during ABR switches.
  • Updated comments to explain the rationale for synchronous handling, specifically addressing issues where asynchronous jobs could lead to mismatched offsets and partial fragment downloads, which caused parser errors (e.g., VPAAMP-614).

Reason for change: If bandwidth has changed after async download job submitted & new IDX is not yet
loaded (the transient window), fall back to the submission-time URL so URL and range stay paired.

Signed-off-by: psiva01 <sivasubramanian.patchaiperumal@ltts.com>
@psiva01
psiva01 requested a review from a team as a code owner July 9, 2026 07:26
@psiva01
psiva01 requested a review from Copilot July 9, 2026 07:26

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Fixes a DASH SegmentBase transient ABR-switch window where an async media-segment download could pair a new-profile URL with an old-profile byte range, causing incorrect byte-range fetches and downstream demux failures.

Changes:

  • Add a guarded URL selection fallback in MediaStreamContext::DownloadFragment() to keep URL and byte-range paired when bandwidth changes but IDX is still cleared/not yet reloaded.
  • Add clarifying comment in the MPD fragment collector about SegmentBase parallel download behavior and where the URL/range race is handled.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
MediaStreamContext.cpp Adds a submission-time bandwidth fallback for URL lookup when IDX is empty during an ABR switch to keep URL/range consistent.
fragmentcollector_mpd.cpp Adds documentation clarifying SegmentBase parallel download behavior and pointing to the race fix location.

Comment thread MediaStreamContext.cpp Outdated
Comment thread MediaStreamContext.cpp Outdated

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated 2 comments.

Comment thread fragmentcollector_mpd.cpp Outdated
Comment thread fragmentcollector_mpd.cpp
@psiva01 psiva01 changed the title VPAAMP-737: [Xumo] Playback fails when played DASH VOD assets VPAAMP-737: Playback fails when played DASH VOD assets Jul 14, 2026
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated 1 comment.

Comment thread fragmentcollector_mpd.cpp Outdated
psiva01 and others added 2 commits July 15, 2026 11:13
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated 1 comment.

Comment thread fragmentcollector_mpd.cpp
@psiva01

psiva01 commented Jul 15, 2026

Copy link
Copy Markdown
Contributor Author

@copilot implement this review comment - #1708 (comment)

Reason for change: Added L1 tests to verify DASH Init & SegmentBase downloads
are serialized

Signed-off-by: psiva01 <sivasubramanian.patchaiperumal@ltts.com>
@pstroffolino
pstroffolino merged commit f6f5060 into dev_sprint_25_2 Jul 15, 2026
9 checks passed
@pstroffolino
pstroffolino deleted the feature/VPAAMP-737 branch July 15, 2026 20:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants