Aayush Bhasin
09/24/2024, 2:17 AM.lakefs_ref.yml
file generated by lakectl local
is part of a git repository. And the git repo is the source of truth. This results in a 3 step commit process
1. commit .lakefs_ref.yml
from feature branch to main
2. update .lakefs_ref.yml
with a commit from main
3. and merge git feature branch to git main
Couple of solutions we're thinking about -
1. merge to git-main while .lakefs_ref.yml
still points to a feature branch. Essentially forget that lakefs has a main branch, and treat it as a chain of commits.
2. do the above, but have a post-merge action on git main that will merge the lakefs feature branch to the lakefs main branch. This would be much easier to reason about if lakefs had a fast forward merge strategy, and we didn't need a merge commit
Are there any other workflows recommended for this? Open to all alternatives, thanks!Ariel Shaqed (Scolnicov)
09/24/2024, 8:01 AMAayush Bhasin
09/24/2024, 6:34 PM.lake_ref.yml
file in the git repo). We'd like to reference lakefs main in the git repo, and we'd like to merge the lakefs feature branch to main when the git feature branch merges to git main. Alternatively - if this is an anti-pattern and we're using lakefs incorrectly/sub-optimally, that would also be great to know!Ariel Shaqed (Scolnicov)
09/25/2024, 4:22 AMAaron Taylor
09/25/2024, 4:48 AMbest practice is to use a specially formatted comment, or hold the data in a file with a known nameCould the
.lalefs_ref.yaml
file serve this purpose?
I would probably keep the entire lake_ref mapping only as an optimization but not as the source of truth. My source of truth would be a commit digest.Not sure I fully understand this, are you referring to a git commit digest or LakeFS commit digest? Our current thinking had been to consider the LakeFS commit hash in the lakefs_ref file as the "source of truth" for what the code at that point in the git history produced.
Ariel Shaqed (Scolnicov)
09/25/2024, 5:20 AMAayush Bhasin
09/27/2024, 2:53 AM