Repository navigation
Instream/banner example: use a working JW Player library and a mocked video bid - #6996
Open
patmmccann wants to merge 1 commit into
Open
patmmccann wants to merge 1 commit into
patmmccann wants to merge 1 commit into
Conversation
… video bid The example loaded content.jwplatform.com/libraries/72xIKEe6.js, which now returns 403, so jwplayer was undefined and no video played. It also relied on live test bids and an illustrative Prebid Cache URL. - Load the JW Player library the JW Platform instream example uses (cdn.jwplayer.com/libraries/dNV4UKpE.js) and play oceans.mp4 instead of a playlist feed that now returns 404. - Cache locally (cache.useLocal) and fetch the VAST with pbjs.adServers.gam.getVastXml, like the other instream examples. - Simulate the video bid with _includes/video/mock-video-bid.html, which now takes an optional adUnitCode so banner bids aren't mocked. Closes prebid#6904 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
👷 Deploy request for prebid-docs-preview pending review.Visit the deploys page to approve it
|
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #6904
The Instream Video and Banner example loaded
https://content.jwplatform.com/libraries/72xIKEe6.js, which returns 403, sojwplayerwas undefined and no video played. Its playlist feed (content.jwplatform.com/feeds/ae4tmw2D.json) returns 404, it relied on livemsfttest bids, and it pointed at the illustrativehttps://my-pbs.example.com/cache.Player choice
I kept JW Player and switched to
https://cdn.jwplayer.com/libraries/dNV4UKpE.js, the library the JW Player (Platform) instream example already uses. A headless run showed that example playing the mocked ad today. This doesn't need a new library URL from JW Player. It keeps the page's point (one Prebid config with banner ad units and an instream video ad unit) with the smallest change, and the page now matches the existing JW instream examples:https://vjs.zencdn.net/v/oceans.mp4, set withfile, instead of the dead playlist.advertising.schedule[].vastxml.I also checked Video.js 6.4.0 with videojs-vast-vpaid. Its scripts return 200, but it would mean rewriting the example around another player, and the JW route was the one I could confirm plays the ad.
Caching and bids
cache: { useLocal: true }replaces the illustrative Prebid Cache URL. The video VAST is fetched withpbjs.adServers.gam.getVastXml(GAM ad unit/41758329/localcache), the same way the other instream examples do it.buildVideoUrlcan't return a playable tag for a locally cached bid.bidsBackHandler. GPT display still usesinitAdserverwith its failsafe._includes/video/mock-video-bid.htmlto simulate the video bid, asmulti-format-example.mddoes. The code listing is unchanged.adUnitCodeparameter. This page passesadUnitCode="video1", so only the video ad unit's bids are mocked. Without it, the banner ad units would get video bids too. Pages that don't pass the parameter still mock every bid (when: {}), so nothing changes for them.Other JW Player pages checked
None of them use the dead
72xIKEe6library, so this PR leaves them unchanged:examples/video/instream/jwplayer/pb-ve-jwplayer-platform.html(_includes/video/pb-is-jw01.html):cdn.jwplayer.com/libraries/dNV4UKpE.jsreturns 200, and the mocked ad plays in a headless run.examples/video/instream/jwplayer/pb-ve-jwplayer-hosted.html(_includes/video/pb-is-jw02.html):ssl.p.jwpcdn.com/player/v/8.0.5/jwplayer.jsreturns 200, and the mocked ad plays. The code listing shows 7.2.4, which also returns 200.prebid-video/video-module/integration-examples/jwplayer.html:cdn.jwplayer.com/libraries/l5MchIxB.jsreturns 200 and the player loads (idle). It still uses a liveixbid, which returned no bid.dev-docs/publisher-api-reference/adServers.gam.getVastXml.md: a code snippet only. Its playlistcdn.jwplayer.com/v2/media/hWF9vG66returns 200._layouts/pb-video-template.html: loadsdNV4UKpE.js(200). No page in the repo uses this layout.Verification
markdownlint-cli2@0.20.0 --config .markdownlint.json.jwplayeris defined, and no page errors occurred.bidResponse:video1,mediaType: video,cpm=1withvastXml. The banner ad units weren't mocked and got no live bid.getVastXmlmade the GAM request. JW Player reportedbuffering, thenplayingwith the ad flag set, and requested the mock creativestatic.adplayer.pro/video/demo_v2.mp4./dev-docs/examples/instream-banner-mix.html.🤖 Generated with Claude Code