Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Client Offline Analytics #126

Open
preexo opened this issue Jul 3, 2016 · 3 comments
Open

Client Offline Analytics #126

preexo opened this issue Jul 3, 2016 · 3 comments

Comments

@preexo
Copy link

preexo commented Jul 3, 2016

What happens if the client is offline (no connection to the internet) for a short period of time? What happens to the events and collected data from within that period?
Can the data somehow pushed later, once the client is back online?

Thanks for any hints, best regards

@arrygoo
Copy link
Contributor

arrygoo commented Jul 4, 2016

  • Keep in mind that this package is a wrap of Segment.io's analytics.js package.
  • As far as I have tested, we lose track of the user when they go offline until they come back online.
  • However, you can manually trigger any of the events that you want by manually storing user's information once they go offline, and using analytics.track or analytics.page when they come back up.

I'll close if you have no further questions. 😄

@preexo
Copy link
Author

preexo commented Jul 5, 2016

@arrygoo - thank you for the answer. I also thought about this, it would probably require another wrapper around this package to store all analytic events in a local storage first and push them only if the client is online, then remove them from the local storage. That way nothing would be lost.
Since you pointed me to the origins of this package I actually found an issue talking about this: segmentio/analytics.js#358

Thanks

@arrygoo
Copy link
Contributor

arrygoo commented Jul 5, 2016

@preexo - Interesting. I think you're proposed solution sounds like a step in the right direction. We welcome PRs, however it might make more sense to have this feature on Segment.io's package.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants