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
Improve tracker performance when using custom dimensions (one less update query per tracking request) #17521
Conversation
if (!$isNewVisit && $processor instanceof ActionsRequestProcessor) { | ||
// already processed earlier when handling exisitng visit see {@link self::handleExistingVisit()} | ||
continue; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
could this be put in ActionsRequestProcessor? ie, return if conditions are met?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
oh i see, this has to be done before updating a visit... seems like it would all be clearer if this was all in ActionsRequestProcessor, though i'm not sure if that's possible
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I know it's not really clear which is why I'm not sure yet if it's worth merging it. Problem is for new visits we have to execute the actions processor later vs for existing visits we have to execute it before updating a visit...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not sure if there's anything else to do here, but this looks good to merge
Description:
Performance improvement to have one less update on log_visit for existing visits if action dimensions are used: fix #17173
New visit scenario
Before this PR
idVisit
idlink_va
idlink_va
on the columnlast_idlink_va
.After this PR
Same logic as before. We always have to create visit first before creating any log link action.
Existing visit scenario
Before this PR
idlink_va
idlink_va
on the columnlast_idlink_va
.After this PR
idlink_va
idlink_va
on the columnlast_idlink_va
.Review