Migrating from the standalone Media SDK to Adobe Launch - Web (JS)

NOTE
Adobe Experience Platform Launch has been rebranded as a suite of data collection technologies in Experience Platform. Several terminology changes have rolled out across the product documentation as a result. Please refer to the following document for a consolidated reference of the terminology changes.

Feature differences

  • Launch - Launch provides you with a UI that walks you through setting up, configuring, and deploying your web-based media tracking solutions. Launch improves upon Dynamic Tag Management (DTM).
  • Media SDK - The Media SDK provides you with media tracking libraries designed for specific platforms (e.g.: Android, iOS, etc.). Adobe recommends Media SDK for tracking media usage in your Mobile Apps.

Configuration

Standalone Media SDK

In the standalone Media SDK, you configure the tracking configuration in the app
and pass it to the SDK when you create the tracker.

//Media Heartbeat initialization
var mediaConfig = new MediaHeartbeatConfig();
mediaConfig.trackingServer = "namespace.hb.omtrdc.net";
mediaConfig.playerName = "html5-player";
mediaConfig.channel = "sample-channel";
mediaConfig.ovp = "video-provider";
mediaConfig.appVersion = "v2.0.0"
mediaConfig.ssl = true;
mediaConfig.debugLogging = true;

In addition to the MediaHeartbeat configuration, the page must configure and pass
the AppMeasurement instance and VisitorAPI instance for media tracking in order
to work properly.

Launch Extension

  1. In Experience Platform Launch, click the Extensions tab for your
    web property.

  2. On the Catalog tab, locate the Adobe Media Analytics for Audio and
    Video extension, and click Install.

  3. In the extension settings page, configure the tracking parameters.
    The Media extension will use the configured parameters for tracking.

Launch User Guide - Install & configure the media extension

Tracker creation differences

Media SDK

  1. Add the Media Analytics library to your development project.
  2. Create a config object (MediaHeartbeatConfig).
  3. Implement the delegate protocol, exposing the getQoSObject() and getCurrentPlaybackTime() functions.
  4. Create a Media Heartbeat instance (MediaHeartbeat).
// Media Heartbeat initialization
var mediaConfig = new MediaHeartbeatConfig();
...
// Configuration settings
mediaConfig.trackingServer = Configuration.HEARTBEAT.TRACKING_SERVER;
...
// Implement Media Delegate (Quality of Service and Playhead)
var mediaDelegate = new MediaHeartbeatDelegate();
...
mediaDelegate.getQoSObject = function() {
    return MediaHeartbeat.createQoSObject(<bitrate>, <startuptime>, <fps>, <droppedFrames>);
    ...
}
...
// Create your tracker
this.mediaHeartbeat = new MediaHeartbeat(mediaDelegate, mediaConfig, appMeasurement);

Launch

Launch offers two approaches to creating the tracking infrastructure. Both approaches use the Media Analytics Launch Extension:

  1. Use the media tracking APIs from a web page.

    In this scenario, the Media Analytics Extension exports the media tracking APIs to a configured variable in the global window object:

    code language-none
    window["CONFIGURED_VARIABLE_NAME"].MediaHeartbeat.getInstance
    
  2. Use the media tracking APIs from another Launch extension.

    In this scenario, you use the media tracking APIs exposed by the get-instance and media-heartbeat Shared Modules.

    note note
    NOTE
    Shared Modules are not available for use in web pages. You can only use Shared Modules from another extension.

    Create a MediaHeartbeat instance using the get-instance Shared Module.
    Pass a delegate object to get-instance that exposes getQoSObject() and getCurrentPlaybackTime() functions.

    code language-none
    var getMediaHeartbeatInstance =
    turbine.getSharedModule('adobe-video-analytics', 'get-instance');
    

    Access MediaHeartbeat constants via the media-heartbeat Shared Module.

Media SDK

Launch

recommendation-more-help
c8eee520-cef5-4f8c-a38a-d4952cfae4eb