Re: reftable & jgit compatibility
- From
Han-Wen Nienhuys <hanwenn@gmail.com>
- Date
- Apr 4, 2024, 06:44 UTC
- Message-ID
- <CAOw_e7Zzc2uLX0FtkJ3fB+wuNJt5piMmoYVes+ayApe8BEN3+g@mail.gmail.com>
- In-Reply-To
- <Zg5HXZrL_4BsyzfG@tanuki>
On Thu, Apr 4, 2024 at 8:23 AM Patrick Steinhardt <ps@pks.im> wrote:
Show 7 quoted lines
> > I think the easiest way to make this happen is if CGit would ship a > > command to dump a raw reftable in a release soonish. Then JGit could > > use that command to cross-check that a JGit-written reftable can be > > read correctly by the CGit code. By shipping just the dumper you > > avoid having to wait for proper reftable support to land in git. > > You do realize that "proper reftable support" has already landed, right?
I had not realized this, and that's great news!
> So you can just use Git to create a reftable-enabled repository, write > commits and then use JGit to access the whole repository instead of only > checking a single table.
For testing, it's probably easier if you can work in terms of individual tables (because that is where the complexity lies: different blocksizes, restart frequencies, with index, without index, with reflog, without reflog etc.), but one can create controlled individual tables by creating a whole repo and then compacting it. OTOH, this would necessitate exposing all writer options to the git CLI, which is maybe a bit much.
-- Han-Wen Nienhuys - hanwenn@gmail.com - http://www.xs4all.nl/~hanwen