git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH 2/2] refs/files: use heuristic to decide whether to repack with `--auto`

From
karthik nayak <karthik.188@gmail.com>
Date
Sep 5, 2024, 08:44 UTC
Message-ID
<CAOLa=ZRQW0sUXEVSs8weK-jke7a2rUmG=Bw5q4yZvtFP4wvQKw@mail.gmail.com>
In-Reply-To
<ZtgfIPOZO1p4_ExF@pks.im>
Patrick Steinhardt <ps@pks.im> writes:
Show 23 quoted lines
> On Tue, Sep 03, 2024 at 02:00:16AM -0700, karthik nayak wrote:
>> Patrick Steinhardt <ps@pks.im> writes:
>>
>> > The `--auto` flag for git-pack-refs(1) allows the ref backend to decide
>> > whether or not a repack is in order. This switch has been introduced
>> > mostly with the "reftable" backend in mind, which already knows to
>> > auto-compact its tables during normal operations. When the flag is set,
>> > then it will use the same auto-compaction mechanism and thus end up
>> > doing nothing in most cases.
>> >
>> > The "files" backend does not have any such heuristic yet and instead
>>
>> Nit: s/instead/will instead/
>>
>> > packs any loose references unconditionally. So we rewrite the complete
>> > "packed-refs" file even if there's only a single loose reference to be
>> > packed.
>
> Revisiting this: isn't the current version of this sentence correct?
> Replacing it with "will instead" certainly makes it incorrect without
> also changing "packs" to "pack".
>
> Patrick
You're right, I did missread.
Previous: Patrick SteinhardtNext: Patrick Steinhardt
Message 10 of 16 in “refs/files: use heuristic to decide whether to repack with `--auto`”
  1. 0/2 refs/files: use heuristic to decide whether to repack with `--auto`Patrick Steinhardt, Sep 2, 2024
  2. 1/2 t0601: merge tests for auto-packing of refsPatrick Steinhardt, Sep 2, 2024
  3. 2/2 refs/files: use heuristic to decide whether to repack with `--auto`Patrick Steinhardt, Sep 2, 2024
  4. karthik nayakSep 3, 2024
  5. Patrick SteinhardtSep 3, 2024
  6. Junio C HamanoSep 3, 2024
  7. Patrick SteinhardtSep 4, 2024
  8. Junio C HamanoSep 4, 2024
  9. Patrick SteinhardtSep 4, 2024
  10. karthik nayakSep 5, 2024
  11. 0/3 refs/files: use heuristics to decide whether to repack with `--auto`Patrick Steinhardt, Sep 4, 2024
  12. 1/3 wrapper: introduce `log2u()`Patrick Steinhardt, Sep 4, 2024
  13. 2/3 t0601: merge tests for auto-packing of refsPatrick Steinhardt, Sep 4, 2024
  14. 3/3 refs/files: use heuristic to decide whether to repack with `--auto`Patrick Steinhardt, Sep 4, 2024
  15. Junio C HamanoSep 4, 2024
  16. Patrick SteinhardtSep 5, 2024

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.