• /
  • EnglishEspañolFrançais日本語한국어Português
  • Log inStart now

Media agent for Video JS v4.2.0

June 19, 2026

Highlights

  • Explicit opt-in for AWS MediaTailor, with full support for custom CDN domains.
  • New config.ad.type API to choose between CSAI and SSAI (DAI, MT) ad tracking — no more URL-based guessing for SSAI.
  • End-to-end logging through nrvideo.Log, with active detection mode logged at startup.

Features

MediaTailor custom CDN support

Replaced URL-based auto-detection with explicit opt-in.

  • Enabled the tracker via mediatailor: true (or mediatailor: { trackingUrl, adSegmentPrefix }), supporting both default AWS hostnames and custom CDN domains.
  • Added MT_DEFAULT_AD_SEGMENT_PATH (/tm/) constant for AWS-recommended CDN ad-segment path; ad segments rewritten to a custom CDN domain under /tm/ are detected automatically.
  • Updated isMediaTailorSegment() to check the default AWS segments hostname, the /tm/ path, and an optional customer-supplied adSegmentPrefix.
  • Threaded adSegmentPrefix through HLS (VHS) and DASH manifest parsing.
  • Added explicit session initialization via mediatailor: { trackingUrl } for POST /v1/session/ flows.

Ad tracking configuration

Introduced config.ad.type to control ad tracker selection.

  • Exposed AD_TRACKING constant with CSAI (flat value covering IMA / Brightcove IMA / Freewheel / generic) and SSAI sub-types (DAI, MT).
  • Required an explicit sub-type for SSAI — each platform needs its own SDK and cannot be auto-detected.
  • Mapped SSAI.MT to imply mediatailor: true.
  • Added a fallback to CSAI auto-detection with a warning when config.ad.type is unset (backward compatible for v4.1.2 users).
  • Co-located segmentPrefix and trackingUrl under config.ad.
  • Added DaiAdsTracker to static exports.

Logging improvements

  • Exposed VideojsTracker.Log as a static so UMD callers can set log level.
  • Added logging of the active ad segment detection mode at tracker startup.
  • Added logging of the matched ad segment detection path on the first ad break (once per session).
  • Added logging of which CSAI framework was auto-detected (BrightcoveIma / IMA / Freewheel / generic).
  • Replaced console.log/warn/error with nrvideo.Log across MediaTailor files.

Bug fixes

  • Fixed buffer end handling in tracker.
  • Fixed register-plugin.js silently dropping the options object and not forwarding it to the TrackerJS constructor.

Documentation

  • Updated the README and SSAI docs for custom CDN support, clarified when trackingUrl and adSegmentPrefix overrides are needed, and cleaned up sessionId references.
  • Corrected adSegmentPrefix references to config.ad.segmentPrefix in the SSAI troubleshooting docs.

Upgrade from 4.1.x

  • No breaking changes for CSAI users. If config.ad.type is unset, the tracker still auto-detects CSAI frameworks (with a one-time warning).
  • MediaTailor users must opt in explicitly. Replace any URL-pattern reliance with one of:
    • mediatailor: true (default AWS hostnames + /tm/ path)
    • mediatailor: { trackingUrl, adSegmentPrefix } (custom CDN / explicit session init)
    • config.ad.type: AD_TRACKING.SSAI.MT
  • If you previously passed adSegmentPrefix at the top level, move it to config.ad.segmentPrefix.
Copyright © 2026 New Relic Inc.

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.