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

import/get: optimize LFS prefetching #10414

Merged
merged 1 commit into from
May 3, 2024

Conversation

sisp
Copy link
Contributor

@sisp sisp commented May 3, 2024

I've significantly optimized LFS prefetching performance. With this change, include in scmrepo.git.lfs.fetch() is now a single-item list with either a Unix filename pattern like <subdir>/** or a file path. scmrepo.git.lfs.fetch._collect_objects() still enumerates all files in the repo with fs.find("/") (that's quite fast even with many files) but scmrepo.git.lfs.fetch._filter_paths() only matches those files against a single pattern.

Partially fixes iterative/scmrepo#338.

/cc @shcheklein

@shcheklein shcheklein merged commit a7c0f6e into iterative:main May 3, 2024
19 checks passed
@sisp sisp deleted the lfs/prefetch-perf branch May 3, 2024 16:01
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.

lfs: internal _filter_paths() function is prohibitively slow
2 participants