Offline trackingI would like to start a public discussion about offline tracking for mobile apps.
Please see my very recent discussion with Piwik core developers at the following URL – my username there is "stehlo":
This will give you an idea what I am after.
Technically speaking, solving the offline tracking may be simpler than one would think and thus it could be achievable with minimal changes of Clicky JS tracking client's code.
Your thoughts, Sean?
Posted Sat Nov 5 2016 5:30am by stehlo
OK, “never say never” sounds better. ;-)
When we solve this seemingly large undertaking by separating it into small bits, you will end up with having a whole new product (mobile apps analytics), whilst you already have the core product (web analytics). Technically speaking, mobile app tracking is just a small bolt-on for your already sophisticated software service.
Let’s analyse the “vast” statement.
When discussing this stuff with Piwik core developer, he came up with a large part of a solution within 30 minutes.
From your description, it looks like currently your system is NOT using local [device] timestamps.
From my point of view, this is the only thing that it holding the “offline tracking” back.
Once this is solved, the remainder is simple – happening largely on the [JS tracking] client side.
Now, how could this work?
When creating a new website (or Internet property), Piwik asks whether it is a website or a mobile app.
In your case, this kind of a question would trigger a switch:
- Websites will continue to use only the real-time timestamps of your server(s).
- Mobile apps will need to use either only the local [device] timestamps or the combination of both (for the sake of comparison for getting the timezone offset, unless this is gotten from GeoIP).
When the device is offline, the developer will say to your JS Tracking Client that we are offline and supply a storage mechanism into which your script will start storing the data (including the timestamp) instead of sending them to your server(s).
Once the device comes online (after an hour, a day, a week or a month), the JS tracking client will start sending the queued tracking logs (page views and events).
I don’t know whether your system supports batch requests. Piwik does, so this part was really simple.
That’s it – the offline tracking was born.
Enough for one e-mail.
Your thoughts so far?
Posted Tue Nov 8 2016 12:29am by stehlo