]> git.ipfire.org Git - thirdparty/git.git/commit
reftable-backend: implement 'optimize' action
authorMeet Soni <meetsoni3017@gmail.com>
Fri, 19 Sep 2025 08:26:41 +0000 (13:56 +0530)
committerJunio C Hamano <gitster@pobox.com>
Fri, 19 Sep 2025 17:02:55 +0000 (10:02 -0700)
commitda0849a71e08ad072700b7cd1a0cb8b6fb89c50a
tree9097fe46be51c659d04ba9417b45dace2c64eb9b
parent1fd6067181703e9e65f602e6da27b9b1d8b783a2
reftable-backend: implement 'optimize' action

To make the new generic `optimize` API fully functional, provide an
implementation for the 'reftable' reference backend.

For the reftable backend, the 'optimize' action is to compact its
tables. The existing `reftable_be_pack_refs()` function already provides
this logic, so the new `reftable_be_optimize()` function simply calls
it.

Wire up the new function to the `optimize` slot in the reftable
backend's virtual table.

Mentored-by: Patrick Steinhardt <ps@pks.im>
Mentored-by: shejialuo <shejialuo@gmail.com>
Signed-off-by: Meet Soni <meetsoni3017@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
refs/reftable-backend.c