-
Notifications
You must be signed in to change notification settings - Fork 4
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
e2e_regression: Manage RPC cache with git-lfs #608
Conversation
b032d22
to
a806938
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fwiw I haven't had noticable pain points from the cache file size. Also, git-lfs knows to automatically fetch the files from github? or do we have to configure that in our local env?
du -sh ./* andrewlow@Beleriand
38M ./consensus
1.9M ./emerald
@@ -1,2 +1,4 @@ | |||
# A hint to GitHub to show autogenerated files (*.gen.go) less prominently in diffs | |||
*.gen.go linguist-generated=true | |||
tests/e2e_regression/rpc-cache/**/*.pix filter=lfs diff=lfs merge=lfs -text |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should we check in the .pmt
files so that everything in rpc-cache is in lfs?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🤷 I don't see a big benefit either way. This felt a tiny bit more future proof in case we store any "normal" files under rpc-cache/
, e.g. a README.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
oh we only need the .psg files right? pogreb scans them and generates the rest. could save time to deliver these pix files. what's pmt?
The cache itself is not huge. But the repo stores the entire history, and every time the cache contents change just a tiny bit, git stores a whole new 38MB blob. Times ~20 versions of the cache is ... a lot. And we're considering adding more e2e regressions (against multiple history ranges).
It's all automatic and transparent, but you do have to install git-lfs first. And then maybe you have to call |
this is it, an excuse to install git-lfs |
This PR removes all the large RPC-cache files from the regular git repo, and re-adds them as git-lfs-tracked files. This means that the files in the repo will contain just a textual pointer to a LFS server, which will store the actual data.
I did not move the RPC caches to git-lfs for old commits. That would require rewriting our entire history.
Storage of LSF-tracked files is on GitHub. My understanding is that LFS-managed files also keep counting against the same storage quota for our repo. The main advantages that I see are:
However, it also makes offline commiting and checkouts impossible?I tested, offline works fine, git-lfs keeps a local copy of un-uploaded changes.Note to developers: To use LFS-managed files (i.e. to run e2e_regression locally), you have to have git-lfs installed.