Skip to content

Improve performance of Process::isSupported by caching it #18152

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

Merged
merged 5 commits into from
Oct 18, 2021

Conversation

tsteur
Copy link
Member

@tsteur tsteur commented Oct 14, 2021

Description:

This can improve archiving using CLI by approx 1-2%. We're calling isSupported very often. Ideally we would cache this across core:archive commands to have a bigger impact but then we would need to clear the cache when viewing system check etc and didn't want to make code too complicated for this.

Review

@tsteur tsteur added the Needs Review PRs that need a code review label Oct 14, 2021
@tsteur tsteur added this to the 4.6.0 milestone Oct 14, 2021
@tsteur tsteur changed the title Improve performance of Process::isSupported Improve performance of Process::isSupported by caching it Oct 14, 2021
@tsteur tsteur added c: Performance For when we could improve the performance / speed of Matomo. and removed Needs Review PRs that need a code review labels Oct 14, 2021
@tsteur tsteur added the Needs Review PRs that need a code review label Oct 14, 2021
Copy link
Member

@sgiehl sgiehl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code looks fine. Failing test seem to be unrelated

@sgiehl sgiehl merged commit 76a120b into 4.x-dev Oct 18, 2021
@sgiehl sgiehl deleted the cache_is_supported branch October 18, 2021 08:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c: Performance For when we could improve the performance / speed of Matomo. Needs Review PRs that need a code review
Development

Successfully merging this pull request may close these issues.

2 participants