Hello,

I am using jstats on my website, but it does not seem to work. Either I am doing something wrong or the module isn't working. Perhaps someone has an idea what is wrong here:

Drupal 7.12 website running on apache, behind a varnish proxy
Drupal cron: runs every 1 hour (called from the operating system).

jStats Settings: Statistics lifetime 1 hour, Freshness 1 hour, Data expiration 1 day
I have jstats.php in my root

No errors in drupal or syslog.

For example: node/214321
My external statistics (piwik) says this node was viewed 198 times today.

Drupal internal statistics (with jstats):
today 0:01: total 24.017 views
today 17:00: total 24.021 views.
That makes 4 visitors today! (It could be that these are only the logged in users)

Am I doing something wrong or is this module not working at the moment?

Comments

DeFr’s picture

Status: Active » Postponed (maintainer needs more info)

What are you using to get the 24.017 / 24.021 numbers ? If that's the core field in the {node_counter} table, then they're not incremented by jStats (that would the feature request #1409522: Integrate Core Statistics (access log + node_counter)).

If that's what's in the jstats_node table, then it's weird : with your settings, it would mean jStats recorded 24.017 hits in the last hour.

Jake.M’s picture

Thanks for your answer.

The numbers 24.017 / 24.021 are the ones that are shown in the "links area" (bottom) of each node display or for example as field "Content statistics: Total views" in views. So I think they are the ones in the {node_counter} table.

I thought jstats would increment these (and was build exactly for this work -> "jStats could be seen as a bridge between the core Statistics module, that stores its data in Drupal but is incompatible with aggressive and external caching, and Google Analytics, that only adds a small JS fragment to the page and thus makes them perfectly cachable, but can't easily be accessed by Drupal modules")...

I need these number for example to show "node creators" how often their node was viewed. Or for example the top 5 viewed restaurants of all time ...
With varnish "in front of drupal", the core statistics alone of course do not work.

Feature Request #1409522 seems to be exactly what I am looking for. Any idea, when/if it will be integrated to jstats?

DeFr’s picture

Title: not working » jStats doesn't increment core node counters
Status: Postponed (maintainer needs more info) » Closed (duplicate)

There's nothing preventing that functionality from getting into jStats. No ETA, as can be seen on #1409522: Integrate Core Statistics (access log + node_counter), the current status is that the issue is waiting on @smoothify smaller patches.