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

enableHeartBeatTimer not reliably running #11614

Closed
poblabs opened this issue Apr 13, 2017 · 2 comments
Closed

enableHeartBeatTimer not reliably running #11614

poblabs opened this issue Apr 13, 2017 · 2 comments
Labels
answered For when a question was asked and we referred to forum or answered it.

Comments

@poblabs
Copy link

poblabs commented Apr 13, 2017

I have the enableHeartBeatTimer setting enabled on my site, https://tornadochannel.com and I notice that it doesn't reliably run on every reload. I had a lot of visitors tonight based on the nginx server log, but Piwik saw only a fraction of that. I have Piwik on 11 sites, and this one seems to be giving me some trouble with accurate analytics.

I'm calling it with:

jQuery(document).ready(function() {
    _paq.push(["enableHeartBeatTimer", 15]); // Ping request for Piwik to get more accurate "Time on Page" metrics. Default 15s
    //_paq.push(["enableHeartBeatTimer", 30]); // Ping request for Piwik to get more accurate "Time on Page" metrics. Default 15s, we set to 30s
});

I know 15 is default, but I added it there because I'm not seeing reliable ping happening in Chrome dev tools Network tab.

Some page loads will have the ?ping=1&idsite=11 in the Chrome Network tab, and other page loads won't run it at all.

Anything I can check into?

Piwik version: 3.0.3
MySQL version: 5.5.52
PHP version: 5.6.30
@poblabs
Copy link
Author

poblabs commented Apr 16, 2017

Update: I've moved the _paq.push(['enableHeartBeatTimer']); into the <script> tag in my header (as opposed to my external js app) to see if this helps. Still too early to tell, but wanted to update this issue with latest info

@poblabs
Copy link
Author

poblabs commented Apr 24, 2017

I understand now that AJAX calls are to be tracked as pageviews, and to use the pageview javascript call on each load.

@poblabs poblabs closed this as completed Apr 24, 2017
@mattab mattab added the answered For when a question was asked and we referred to forum or answered it. label May 16, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
answered For when a question was asked and we referred to forum or answered it.
Projects
None yet
Development

No branches or pull requests

2 participants