Skip to content

perf: consolidate paths to parent path when threshold exceeded for fsevents watcher#60

Merged
sapphi-red merged 1 commit intomainfrom
12-19-perf_consolidate_paths_to_parent_path_when_threshold_exceeded_for_fsevents_watcher
Dec 19, 2025
Merged

perf: consolidate paths to parent path when threshold exceeded for fsevents watcher#60
sapphi-red merged 1 commit intomainfrom
12-19-perf_consolidate_paths_to_parent_path_when_threshold_exceeded_for_fsevents_watcher

Conversation

@sapphi-red
Copy link
Member

If more than 10 paths are watched, watch the parent path instead.
This behavior was inspired by chokidar:
https://github.com/paulmillr/chokidar/blob/7c50e25d10a497ce4409f6e52eb630f0d7647b97/lib/fsevents-handler.js#L113-L119

@sapphi-red sapphi-red merged commit ca91535 into main Dec 19, 2025
9 checks passed
@sapphi-red sapphi-red deleted the 12-19-perf_consolidate_paths_to_parent_path_when_threshold_exceeded_for_fsevents_watcher branch December 19, 2025 11:20
@Boshen Boshen mentioned this pull request Dec 19, 2025
graphite-app bot pushed a commit to rolldown/rolldown that referenced this pull request Dec 22, 2025
Now that I implemented some improvements (rolldown/notify#59, rolldown/notify#60), it doesn't error on large projects. kqueue doesn't have a way to watch recursively, so it's faster to use fsevent which supports recursive watches.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant