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

nb_hits is different for getPageUrl and getPageUrls API's for the same PAGE after re-processing #17710

Open
gauripadbidri opened this issue Jun 25, 2021 · 3 comments

Comments

@gauripadbidri
Copy link

I am invoking 2 Matomo API to display Total Views on a POST Page and Top Views for the week on every page in the sidebar. However, I observed that the Total Count for a Post and Top Views for the same Post are different.

Note: This has started to happen after I have re-processed my data (Invalidate entire data and trigger re-process)
Same code works (meaning top views and total Views for a post are same) well for other sites for which re-processing is NOT triggered.

Following are my queries :
I am trying to show top stories of the week based of Top Views. For which my query is as follows:
Eg : Startdate = 14th June End Date = 21st June

module=API&method=Actions.getPageUrls&filter_sort_column=nb_hits&filter_sort_order=desc&idSite=’ . $idSite . ‘&period=range&date=’ . $params[‘start-date’] . ‘,’ . $params[‘end-date’] . ‘&format=json&token_auth=’ . $this->auth_token

Total Views :
‘module=API&method=Actions.getPageUrl&pageUrl=’ . $pageUrl . ‘&idSite=’ . $idSite . ‘&period=range&date=’ . $atts[‘start_date’] . ‘,’ . $atts[‘end_date’] . ‘&format=json&token_auth=’ . $auth_token;

I have done following steps :

Reference URL - https://matomo.org/faq/troubleshooting/faq_141/

DB Snapshot / Backup that way we can revert when needed.

Update Matomo Version - Done

Re-Process Data - Ref URL : https://matomo.org/faq/how-to/faq_59/
a. Invalidate Historical Reports for a Site (with LOW Traffic) using Invalidte Reports Plugin (Al Historical Data) OR via
Console (https://matomo.org/faq/how-to/faq_155/)
Console path - var/www/matomo

b. Re-Process Data using Console - https://matomo.org/faq/how-to/faq_59/
./console core:archive --force-idsites=1,3,5 --url=https://analytics.sophiamedia.com/
Helpful Command for Console - cd /var/www/matomo > ./console help core:archive

Setup auto archiving for your reports - Done in Crontab already

What could have gone wrong in the processing ? Anything else remains in triggering re-processing ?

@diosmosis
Copy link
Member

Hi @gauripadbidri, can you provide the URLs for the API requests above with parameters filled out (except token auth) and the API results?

@gauripadbidri
Copy link
Author

gauripadbidri commented Jun 30, 2021 via email

@sgiehl
Copy link
Member

sgiehl commented Jun 30, 2021

Hi @gauripadbidri
I'm not sure if I understood your issue correctly. So the same report changes it's numbers after invalidating and reprocessing it?
You also mentioned something of an Matomo update? Did you update the Matomo version somewhere before reprocessing the data?

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

No branches or pull requests

4 participants