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

Reloading ignores is hugely inefficient #3394

Closed
calmh opened this Issue Jul 8, 2016 · 3 comments

Comments

Projects
None yet
4 participants
@calmh
Copy link
Member

calmh commented Jul 8, 2016

We reload the ignores before each folder scan. This involves parsing and compiling the ignore patterns. If there are a lot of patterns that can be expensive. If running with syncthing-inotify we might get a lot of scan requests.

We should just check the .stignore file timestamp and not do anything unless it's changed.

It's a mystery to me why we don't already do this. I must have been drunk when I wrote this (or reviewed it, if someone else is responsible. I forget.).

@calmh calmh added the bug label Jul 8, 2016

@calmh calmh added this to the Planned milestone Jul 8, 2016

@syncthing syncthing locked and limited conversation to collaborators Jul 8, 2016

@syncthing syncthing unlocked this conversation Jul 8, 2016

@calmh

This comment has been minimized.

Copy link
Member Author

calmh commented Jul 23, 2016

For the record, it's not just

We should just check the .stignore file timestamp and not do anything unless it's changed.

as we also have included files and included files in included files etc that need to be checked.

@hashworks

This comment has been minimized.

Copy link

hashworks commented Jul 26, 2016

I guess it would be sufficient to save the timestamp of all included files, as soon as one of them changes there could be new included files.

@st-review st-review closed this in a2b8485 Nov 22, 2016

@guillaume-uH57J9

This comment has been minimized.

Copy link

guillaume-uH57J9 commented Dec 11, 2016

Thanks for working on the idle performance!
By default, scanning occurs every 60 seconds, so I'm guessing it'd improve a bit the idle performance of scanmem.

@syncthing syncthing locked and limited conversation to collaborators Nov 23, 2017

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
You can’t perform that action at this time.