Kollective eCDN Plugin

In this topic, you will learn to implement the Kollective eCDN plugin.

Overview

This plugin is used to integrate a Brightcove Player with Kollective eCDN.

There are a number of docs from Brightcove's Integrations web site that pertain to Kollective eCDN. They are:

Implement using Players module

To implement the plugin in Studio's Players module, use the following steps:

  1. In Studio, select the Players module.
  2. Click the player to which you wish to add the Kollective eCDN plugin.
  3. In the left-navigation, click Plugins.
  4. Click Add a Plugin > Brightcove plugin.
    select brightcove plugin
  5. From the dropdown, select Kollective eCDN.
    select kollective ecdn
  6. Enter configuration Options, if using any, in JSON format. An example is shown.
    enter options
  7. Save then publish your player.

Note that you can also simply edit a player's JSON to implement the plugin. The follow steps guide you through that process:

  1. In Studio, select the Players module.
  2. Click the player to which you wish to add the Kollective eCDN plugin.
  3. In the left-navigation, click JSON editor.
  4. To the plugins section, add the highlighted section.
    JSON configuration
  5. Save then publish your player.

Implement with JSON Editor

For players 7.28.0 and newer, you can also follow these steps to add the plugin using the JSON editor:

In the Players module, navigate to the player you want to configure and click the link for the JSON Editor. Modify the "plugins" array to add the Kollective eCDN plugin.

  
    "plugins": [
    {
      "name": "kollective",
      "is_packaged": true,
      "options": {
        ...
      }
    }
  ]

Options

The items listed below are plugin options are used when configuring the Kollective eCDN plugin.

  • ksdkUrl: Used to provide a URL to a specific version of the Kollective SDK (KSDK). If unset, Kollective's latest version is used. If the KSDK is included in-page before the player, this option can be left off.
  • persistUserToken: If true, this saves/retrieves the otherwise randomly generated user token to localstorage.

Methods

There is one method available for use with the Kollective eCDN plugin:

  • loadVideo(videoId): Loads a single video by its ID or ref ID.
    • Data type is string.
    • Returns a promise, which resolves when the Brightcove Playback API responds.
      myPlayer.kollective().loadVideo('1234567890').then(data => {
        // Playback API request is complete, but KSDK.load might not be complete!
      });