Custom Data setup on Bitmovin Player v3 for Android and iOS

Bitmovin Player v3 on Android and iOS introduced a playlist feature, which enables customers to connect multiple different sources. Through using the Bitmovin Analytics collector for Bitmovin Player v3 it is now possible to setup values for custom data 1-7 fields for each item in the playlist individually.

Starting from the v2 Analytics collector for Android and iOS it's possible to setup custom data values in two different ways:

  1. Setting custom data in BitmovinAnalyticsConfig which continues to function the same way as in previous versions.
  2. Setting custom data as SourceMetadata for a specific source in the playlist. If some source has custom data values setup as SourceMetadata those values will be used when a player is playing the source. If there are no SourceMetadata values set up for a source, then custom data values from BitmovinAnalyticsConfig will be used.

Custom data in both cases can be changed by calling either the setCustomData and the setCustomDataOnce methods in the analytics collector. Depending on where custom data information is set (BitmovinAnalyticsConfig or SourceMetadata) two different cases are possible:

Case 1: When only BitmovinAnalyticsConfig is available, calling the setCustomData method will permanently change the config values.
The setCustomDataOnce method call will only trigger sending one sample with the desired values for the custom data fields. No values will be permanently changed. This means subsequent sent samples will use the initially configured customData from BitmovinAnalyticsConfig.

Case 2: When SourceMetadata is available, the collector use the data from this configuration method (a null for some custom data field will not fall back to the BitmovinAnalyticsConfig value). Calling the setCustomData method will permanently update the SourceMetadata values, but will not change values of the BitmovinAnalyticsConfig. Same as in the first case, calling setCustomDataOnce will only trigger the sending of one sample with the desired values for the custom data fields, and no values will be permanently changed.

It's possible to directly change the custom data values in SourceMetadata and BitmovinAnalyticsConfig objects, but then there will be no additional samples sent.