-
Notifications
You must be signed in to change notification settings - Fork 1
Migration guides
Pierre-Yves B edited this page Jul 15, 2023
·
16 revisions
This page provides instructions for migration between major versions of SRGAnalytics.
SRGSSR's data analysts use a tagging tool, named Tag Commander, from the Commander Acts company.
- Since 2016, iOS V4 SDKs was used client side. Server side, Commander Acts server V1 was used.
- Since November 2019, to support
tvOS
, a fork of the V4 was created at SRGSSR and was used. - In 2023, SRGSSR moves to a new major version: iOS V5 SDKs are now used client side. Server side, Commander Acts server V2 is now used.
- Update the library to branch
feature/62-update-to-tag-commander-v5
. - If using SRGLetterbox, update the player library to
feature/283-update-to-commanders-act-version-5
.
-
SRGAnalyticsConfiguration
:- No more
container
(integer) andenvironmentMode
(boolean), justsourceKey
(string).- call
initWithBusinessUnitIdentifier:sourceKey:siteName:
instead ofinitWithBusinessUnitIdentifier:container:siteName:
.
- call
- Good practice: use two
sourceKey
s:- one for debug (and nighty and beta) builds.
- one for production builds.
- Ask
sourceKey
s to ADI team if you would like custom source keys. Otherwise, use default ones (same foriOS
andtvOS
):- iOS SDK - Debug:
39ae8f94-595c-4ca4-81f7-fb7748bd3f04
. - iOS SDK - Production:
1b30366c-9e8d-4720-8b12-4165f468f9ae
.
- iOS SDK - Debug:
- No more
-
SRGAnalyticsTracker
:- No more "hidden event", just "event":
- call
trackEventWithName:
instead oftrackHiddenEventWithName:
. - call
trackEventWithName:labels:
instead oftrackHiddenEventWithName:labels:
.
- call
- No more "hidden event", just "event":
-
SRGAnalyticsHiddenEventLabels
:- Use
SRGAnalyticsEventLabels
class instead ofSRGAnalyticsHiddenEventLabels
.
- Use
Commander Acts V5 SDKs (Apple and Android) now send a JSON
payload to the new server V2, instead of multipart/form-data
to previous server V1. New defined objects and property names changed.
- New SDK properties can have type (like integer for timestamps).
-
event_id
is an internal variable for the product: a UUID set by the SDK. -
event_name
is used in every sent events from sources:- page view:
page_view
(defined by the V5 SDK) - media events:
play
,pause
,seek
,eof
,stop
,pos
,uptime
,segment
. - events: the name given my the product which sent.
- page view:
- No more
navigation_environment
andmedia_embedding_environment
properties (prod
andpreprod
). Check thesourceKey
environment. - In page view events, use
page_type
instead ofcontent_title
. - Custom SRGSSR property names transferred throw the SDK don't change.
-
TC
properties have new names and are in thecontext
object:- V1: Mobile Apps event specificity iOS (same for Android).
- V2: Mobile App event specificity.
Other creations and transformations server side from V1 (internal variables or PHP transformations) are now in Data Cleansing V2 feature. Names don't change.
- page view:
event_name = "page_view"
("is" comparaison). - media events:
event_name IN ("play", "pause", "seek", "eof", "stop", "pos", "uptime", "segment")
("is" comparaison)- SRGSSR usually adds
AND EXISTS(media_urn)
("exists" comparaison) to have a unique id to group events from the same "visit session" / "install id".
- SRGSSR usually adds
- events:
event_name !IN ("page_view", "play", "pause", "seek", "eof", "stop", "pos", "uptime", "segment")
("isn't" comparaison).