-
-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Tracker: Delay log of page view/visit to include onload
metric
#20735
base: 5.x-dev
Are you sure you want to change the base?
Tracker: Delay log of page view/visit to include onload
metric
#20735
Conversation
7414fe1
to
c5cbf4d
Compare
onload
metriconload
metric
onload
metriconload
metric
For me this works as expected in production now. Especially when the Matomo tracking code is executed before Without this change implemented (day A):
SQL to reproduce statistics (click to open)Hint: SELECT
'with peformance data' as views,
COUNT(`idlink_va`) as total,
COUNT(`time_network`) as network,
COUNT(`time_server`) as server,
COUNT(`time_transfer`) as time_transfer,
COUNT(`time_dom_processing`) as processing,
COUNT(`time_dom_completion`) as dom_completion,
COUNT(`time_on_load`) as on_load
FROM `matomo_log_link_visit_action`
WHERE `idsite` = 1
AND `time_server` > 0 AND `time_server` IS NOT NULL
AND server_time > '2023-05-28 12:30:00' AND server_time < '2023-05-29 12:30:00'
UNION
SELECT
'without peformance data' as views,
COUNT(`idlink_va`) as total,
COUNT(`time_network`) as network,
0 as server,
COUNT(`time_transfer`) as time_transfer,
COUNT(`time_dom_processing`) as processing,
COUNT(`time_dom_completion`) as dom_completion,
COUNT(`time_on_load`) as on_load
FROM `matomo_log_link_visit_action`
WHERE `idsite` = 1
AND `time_server` IS NULL
AND server_time > '2023-05-28 12:30:00' AND server_time < '2023-05-29 12:30:00' With this change implemented (day B):
SQL to reproduce statistics (click to open)Hint: SELECT
'with peformance data' as views,
COUNT(`idlink_va`) as total,
COUNT(`time_network`) as network,
COUNT(`time_server`) as server,
COUNT(`time_transfer`) as time_transfer,
COUNT(`time_dom_processing`) as processing,
COUNT(`time_dom_completion`) as dom_completion,
COUNT(`time_on_load`) as on_load
FROM `matomo_log_link_visit_action`
WHERE `idsite` = 1
AND `time_server` > 0 AND `time_server` IS NOT NULL
AND server_time > '2023-05-29 12:45:00'
UNION
SELECT
'without peformance data' as views,
COUNT(`idlink_va`) as total,
COUNT(`time_network`) as network,
0 as server,
COUNT(`time_transfer`) as time_transfer,
COUNT(`time_dom_processing`) as processing,
COUNT(`time_dom_completion`) as dom_completion,
COUNT(`time_on_load`) as on_load
FROM `matomo_log_link_visit_action`
WHERE `idsite` = 1
AND `time_server` IS NULL
AND server_time > '2023-05-29 12:45:00' |
c926fb7
to
4cec8c7
Compare
If you don't want this PR to be closed automatically in 28 days then you need to assign the label 'Do not close'. |
This PR was last updated more than one month ago, maybe it's time to close it. Please check if there is anything we still can do or close this PR. ping @matomo-org/core-reviewers |
If you don't want this PR to be closed automatically in 28 days then you need to assign the label 'Do not close'. |
This PR was last updated more than one month ago, maybe it's time to close it. Please check if there is anything we still can do or close this PR. ping @matomo-org/core-reviewers |
Also resolves #22339 |
This might need an additional feature: |
This PR was last updated more than one month ago, maybe it's time to close it. Please check if there is anything we still can do or close this PR. ping @matomo-org/core-reviewers |
4cec8c7
to
4c5e244
Compare
4c5e244
to
ed79095
Compare
Description:
This PR delays logging of every page view/visit to whatever comes first:
load
event is firedThe PagePerformance metric
time_on_load
is only availible via JavaScript APIPerformanceTiming.loadEventEnd
in the browser after theload
event handler has finished.Related to #20726
Review