Snowplow Objective-C Tracker 0.9.0 released

31 October 2018  •  Mike Hadam

We are pleased to announce a new release of the Snowplow Objective-C Tracker.

Version 0.9.0 introduces an application context, and lifecycle event tracking.

Read on below the fold for:

  1. Application context
  2. Lifecycle tracking
  3. Updates and bug fixes
  4. Documentation
  5. Getting help

1. Application context

In this release we introduce an application context. This feature allows one to determine which version of an app sent a particular event.

This can be enabled in the tracker initialization, and doing so will send an application context with every event.

Include the setApplicationContext method as found on the bottom of this tracker builder block:

SPTracker *tracker = [SPTracker build:^(id<SPTrackerBuilder> builder) {
    [builder setEmitter:emitter]; // Required
    [builder setSubject:subject]; // Optional
    [builder setAppId:_appId]; // Optional
    [builder setTrackerNamespace:_namespace]; // Optional
    [builder setBase64Encoded:YES]; // Optional
    [builder setSessionContext:YES]; // Optional
    [builder setForegroundTimeout:300]; // Optional
    [builder setBackgroundTimeout:150]; // Optional
    [builder setCheckInterval:10]; // Optional
    [builder setApplicationContext:YES]; // Optional
}];

Documentation can be found here.

2. Introducing lifecycle tracking

App lifecycle tracking is a powerful auto-tracking capability. Events are automatically sent whenever the app is backgrounded or foregrounded.

Lifecycle tracking can be enabled through tracker initialization, see setLifecycleEvents below:

SPTracker *tracker = [SPTracker build:^(id<SPTrackerBuilder> builder) {
    [builder setEmitter:emitter]; // Required
    [builder setSubject:subject]; // Optional
    [builder setAppId:_appId]; // Optional
    [builder setTrackerNamespace:_namespace]; // Optional
    [builder setBase64Encoded:YES]; // Optional
    [builder setSessionContext:YES]; // Optional
    [builder setForegroundTimeout:300]; // Optional
    [builder setBackgroundTimeout:150]; // Optional
    [builder setCheckInterval:10]; // Optional
    [builder setLifecycleEvents:YES]; // Optional
}];

Documentation can be found here.

3. Updates and bug fixes

Other updates and fixes include:

  • Updating CocoaPods in the Travis build (issue #359)
  • Commiting the IDEWorkspaceChecks.plist file to the repository (issue #354)
  • Fixing the ConsentGranted builder argument type in tests (issue #361)
  • Updating the pods committed to repo (issue #360)
  • Adding SRCROOT to the project header search path (issue #362)

4. Documentation

You can find the latest Obj-C Tracker documentation on our wiki.

For more details on this release, please check out the Snowplow Obj-C Tracker v0.9.0 release notes on GitHub.

5. Getting help

For help on integrating the tracker please have a look at the setup guide.

If you have any questions or run into any problems, please visit our Discourse forum. As always, do raise any bugs in the Obj-C Tracker’s issues on GitHub.