Skip to content

VPAAMP-684:Tech Fault error leads to Blue Screen when rewinding from …#1693

Open
varshnie wants to merge 1 commit into
dev_sprint_25_2from
feature/VPAAMP-684
Open

VPAAMP-684:Tech Fault error leads to Blue Screen when rewinding from …#1693
varshnie wants to merge 1 commit into
dev_sprint_25_2from
feature/VPAAMP-684

Conversation

@varshnie

@varshnie varshnie commented Jul 6, 2026

Copy link
Copy Markdown
Contributor

…live edge into CDAI ads

Reason for change:Init frag failure due to mismatched bandwitdh Risks: p1

@varshnie
varshnie requested a review from a team as a code owner July 6, 2026 12:01
@varshnie
varshnie force-pushed the feature/VPAAMP-684 branch 3 times, most recently from dc841f1 to 939f6d4 Compare July 8, 2026 14:44
Comment thread MediaStreamContext.cpp Outdated
uriInfo = dlInfo->uriList[dlInfo->bandwidth];
}
// Fallback to current descriptor bandwidth if request-scoped key is not present.
else if (dlInfo->uriList.find(fragmentDescriptor.Bandwidth) != dlInfo->uriList.end())

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.

Update dlInfo->bandwidth if there is a mismatch with fragmentDescriptor.Bandwidth as we have already selected the url for new bandwidth

…live edge into CDAI ads

Reason for change:Init frag failure due to mismatched bandwitdh
Risks: p1

Signed-off-by: varshnie <varshniblue14@gmail.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

Fixes a false “bitrate mismatch → rampdown” path that can cause init-fragment failure during live→CDAI ad transitions (e.g., rewind from live edge), by comparing the FOG-reported bitrate against the bandwidth captured at job submission time rather than a potentially updated fragmentDescriptor.Bandwidth.

Changes:

  • Update MediaStreamContext::CacheFragment() to compare FOG bitrate against an expectedBandwidth derived from mActiveDownloadInfo->bandwidth.
  • Add null-guards around AampCacheHandler access when retrieving/inserting init fragments.
  • Add focused unit tests covering the init-segment race scenario and ensuring genuine bitrate mismatches still trigger rampdown.

Reviewed changes

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

File Description
MediaStreamContext.cpp Implements expectedBandwidth comparison, adds cache-handler null checks, and adjusts bandwidth/URI selection logic.
test/utests/tests/CacheFragmentTests/CacheFragmentTests.cpp Adds new tests validating the expected-bandwidth behavior for init and media segments.

Comment thread MediaStreamContext.cpp
Comment on lines +76 to +80
BitsPerSecond expectedBandwidth = fragmentDescriptor.Bandwidth;
double downloadTimeS = 0;
AampMediaType actualType = (AampMediaType)(initSegment ? (eMEDIATYPE_INIT_VIDEO + mediaType) : mediaType); // Need to revisit the logic
if (mActiveDownloadInfo && mActiveDownloadInfo->bandwidth > 0)
{
Comment thread MediaStreamContext.cpp
Comment on lines +1069 to +1072
if (dlInfo->bandwidth != fragmentDescriptor.Bandwidth)
{
dlInfo->bandwidth = fragmentDescriptor.Bandwidth;
}
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