Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[JS] Allow playerName to be set per-tracker instance #83

Closed
arm22 opened this issue Nov 13, 2024 · 11 comments
Closed

[JS] Allow playerName to be set per-tracker instance #83

arm22 opened this issue Nov 13, 2024 · 11 comments
Assignees

Comments

@arm22
Copy link

arm22 commented Nov 13, 2024

I have an application where there is the potential for > 1 video player to be present on a single page. With the v3 JS SDK I cannot set the playerName to a distinct value for the discrete tracker instances created.

    var Media = ADB.Media;
    var MediaConfig = ADB.MediaConfig;

    // Create MediaConfig object (same as above)
    var mediaConfig = new MediaConfig();
    mediaConfig.trackingServer = "tracking_server";
    // Don't set playerName on the global configuration
    mediaConfig.channel = "sample_channel";
    mediaConfig.appVersion = "app_version";
    mediaConfig.debugLogging = true;
    mediaConfig.ssl = true;

    // Configuration is only done once per page
    // and applies to all tracker instances created.
    Media.configure(mediaConfig, appMeasurement);

    // Tracker creation.
    var streamingVideoTracker = Media.getInstance({"media.playerName": "linear_player_tech"}); // contrived example
    var vodVideoTracker = Media.getInstance({"media.playerName": "vod_player_tech"});          // contrived example

The SDK defaults both trackers to report playerName as "unknown"
Streaming Video Session Start payload

{
  "eventType": "sessionStart",
  "playerTime": { "playhead": 0, "ts": 1731519114698 },
  "customMetadata": {},
  "params": {
    "media.id": "5676009166762707117",
    "media.name": "...",
    "media.length": 86400,
    "media.contentType": "live",
    "media.streamType": "video",
    "media.resume": false,
    "media.assetId": "2007524",
    "analytics.trackingServer": "...",
    "analytics.reportSuite": "...",
    "analytics.enableSSL": true,
    "visitor.marketingCloudOrgId": "...",
    "visitor.marketingCloudUserId": "...",
    "visitor.aamLocationHint": 9,
    "media.channel": "On-Domain",
    "media.playerName": "unknown",
    "media.sdkVersion": "4.1.4",
    "media.libraryVersion": "js-3.0.2"
  }
}

VOD Video Session Start payload

{
  "eventType": "sessionStart",
  "playerTime": { "playhead": 0, "ts": 1731519272815 },
  "customMetadata": {},
  "params": {
    "media.id": "241112",
    "media.name": "...",
    "media.length": 175,
    "media.contentType": "vod",
    "media.streamType": "video",
    "media.resume": false,
    "media.assetId": "not available",
    "analytics.trackingServer": "...",
    "analytics.reportSuite": "...",
    "analytics.enableSSL": true,
    "visitor.marketingCloudOrgId": "...",
    "visitor.marketingCloudUserId": "...",
    "visitor.aamLocationHint": 9,
    "media.channel": "On-Domain",
    "media.playerName": "unknown",
    "media.sdkVersion": "4.1.4",
    "media.libraryVersion": "js-3.0.2"
  }
}
@addb addb self-assigned this Nov 14, 2024
@addb
Copy link
Collaborator

addb commented Nov 17, 2024

Hi @arm22,

Currently the SDK doesn't support overriding playerName. Only channel can be overridden per tracker instance.

There is new way to implement Media Analytics tracking Web SDK. This solution uses the new XDM format for data and send s data to Adobe Experience Platform where it can be used with AA, CJA, etc.
Docs: https://experienceleague.adobe.com/en/docs/experience-platform/web-sdk/commands/configure/streamingmedia

If you are not ready to migrate and want to use the 3.X JS SDKs, please raise a feature request from your side. In the meantime I will also bring this to the Media Analytics Product team.

Thanks,
Arjun

@arm22
Copy link
Author

arm22 commented Nov 19, 2024

Hello @addb,

I appreciate the insight. This application is not currently being migrated to the new "Edge" solution.

Can you provide more details regarding raising a feature request? Is that something done via a Pull Request, or via the Adobe Analytics UI?

Best,
Austin

@addb
Copy link
Collaborator

addb commented Nov 19, 2024

@arm22 I have conveyed this request to the Product team, I will let you know about the updates or if anything needs to be done from your side.

Thanks,
Arjun

@arm22
Copy link
Author

arm22 commented Nov 20, 2024

Thank you @addb! Please keep me posted. If it's appropriate to close this issue, feel free to do so.

@elleryvelope
Copy link

Hello @addb are there any updates regardin this issue? Let us know if anything comes up and if anything should be done on our side. Thank you

@addb
Copy link
Collaborator

addb commented Dec 9, 2024

Hello @elleryvelope, @arm22,

We have added this feature request in our roadmap. I will get back as soon as I have an ETA on this.

@elleryvelope
Copy link

Understood @addb please let us know. Thank you

@elleryvelope
Copy link

Hello @addb are ther eany updates on an ETA fo rthis issue just so that we can have an idea of where it could be expected? Let us know i fthere's an update. Thank you

@addb
Copy link
Collaborator

addb commented Dec 13, 2024

Hi @elleryvelope,

We are in a release restriction period currently, so we will release the new version of the SDK with the updates in January.

@elleryvelope
Copy link

Hi @elleryvelope,

We are in a release restriction period currently, so we will release the new version of the SDK with the updates in January.

Hello @addb thank you for the response. Do you have an ETA for when in January the new version of SDK might be released?

@addb
Copy link
Collaborator

addb commented Jan 6, 2025

Hello @elleryvelope @arm22,

We have released the Media JS SDK v3.1.0 with the feature to override the player name similar to channel. We have also expose constants to use for configuration.

Sample:

const trackerConfig = {
            [Media.TrackerConfig.Channel]: "custom_channel_name",
            [Media.TrackerConfig.PlayerName]: "custom_player_name",
}
        
let mediaTracker = Media.getInstance(trackerConfig);

Thanks,
Arjun

@addb addb closed this as completed Jan 6, 2025
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

No branches or pull requests

3 participants