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

Log path strings directly instead of accumulating #7718

Merged
merged 2 commits into from
Jan 23, 2025

Conversation

Diff-fusion
Copy link
Contributor

Accumulating all discovery paths into one string causes major slowdowns: #7377
This fixes the issue by immediately writing the names out instead of accumulating them. Additionally a check is added to skip the loop entirely if logging is disabled for the given log level.

Copy link
Collaborator

@claucambra claucambra left a comment

Choose a reason for hiding this comment

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

Seems like a good idea to me, Wdyt @mgallien ?

Copy link
Collaborator

@mgallien mgallien left a comment

Choose a reason for hiding this comment

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

thanks a lot
please see my comment

});

qCInfo(lcEngine()) << "paths to discover locally" << allPaths;
if (lcEngine().isInfoEnabled()) {
Copy link
Collaborator

Choose a reason for hiding this comment

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

can you also add a check for _localDiscoveryPaths not being empty

@Diff-fusion
Copy link
Contributor Author

Thanks for looking at this. I added the change.

@mgallien mgallien merged commit 55059ec into nextcloud:master Jan 23, 2025
10 of 14 checks passed
@mgallien
Copy link
Collaborator

sorry @Diff-fusion for the delay
thanks for your contribution

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

Successfully merging this pull request may close these issues.

3 participants