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

Re: [PATCH v3] fetch: commit references fetched before backfilling tags

From
Justin Tobler <jltobler@gmail.com>
Date
Oct 21, 2026, 13:59 UTC
Message-ID
<atjAS1qQ7HyDYbxh@denethor>
In-Reply-To
<CAOLa=ZQ_sgz9e4JFWj61HNnKXx+pTvTYhENbbtRu+ATUbXxS9g@mail.gmail.com>
On 26/10/21 06:01AM, Karthik Nayak wrote:
Show 17 quoted lines
> Patrick Steinhardt <ps@pks.im> writes:
> > On Tue, Oct 20, 2026 at 06:05:22PM -0500, Justin Tobler wrote:
> >> Naively, I think it would be nice if it were possible supplement the
> >> backfill fetch "haves" with the non-committed references in the pending
> >> transaction directly. That would avoid having to commit the references
> >> in the middle and probably also fix it for atomic fetches too, but I'm
> >> uncertain if that would be a simple or reasonable thing to do.
> >
> > Hmm, I think that's a sensible idea. We should know about the ref
> > updates we have already scheduled into the transaction, so in theory we
> > could use their new object IDs in the negotiation. If that's possible it
> > would definitely be a much better fix.
>
> I'm a bit wary of going down ad we'd be exposing un-committed references
> which could fail as 'haves' to the server. This doesn't seem to be
> conceptually correct as we now expect GC to not clear the objects needed
> by relying on the .keep lock instead of durable references.

I'm not quite sure I follow why this would be conceptually problematic. Should it really matter in this particular scenario whether the tips the client advertises are committed or not? The required objects should already be present in the repository from the initial fetch.

Regarding the continued use of ".keep" lockfiles to prevent newly fetched packfiles from being GC'd, that still sounds reasonable to me. It is expected that the ".keep" lockfiles remain in place until the reference transaction is committed any way. To me, conceptually all we are doing is allowing the current inflight state of the transaction to be used to affect another operation being performed within the very same transaction.

> But seems like we have negotiation_include_tips in the transport
> structure which seems like the right fit?

At a quick glance, this seems like it could be a good way for the client to advertise to the sever the tips of the uncommitted references it has.

-Justin
Previous: Karthik NayakNext: Karthik Nayak
Message 13 of 36 in “fetch: commit references fetched before backfilling tags”
  1. fetch: commit references fetched before backfilling tagsKarthik Nayak, Oct 8, 2026
  2. Patrick SteinhardtOct 9, 2026
  3. Justin ToblerOct 9, 2026
  4. Karthik NayakOct 9, 2026
  5. Karthik NayakOct 9, 2026
  6. fetch: commit references fetched before backfilling tagsKarthik Nayak, Oct 12, 2026
  7. Junio C HamanoOct 12, 2026
  8. Karthik NayakOct 15, 2026
  9. fetch: commit references fetched before backfilling tagsKarthik Nayak, Oct 15, 2026
  10. Justin ToblerOct 20, 2026
  11. Patrick SteinhardtOct 21, 2026
  12. Karthik NayakOct 21, 2026
  13. Justin ToblerOct 21, 2026
  14. Karthik NayakOct 22, 2026
  15. Karthik NayakOct 21, 2026
  16. fetch: advertise fetched refs when backfilling tagsKarthik Nayak, Oct 22, 2026
  17. Patrick SteinhardtOct 23, 2026
  18. Karthik NayakOct 23, 2026
  19. Patrick SteinhardtOct 23, 2026
  20. Karthik NayakOct 23, 2026
  21. Karthik NayakOct 23, 2026
  22. 0/3 fetch: advertise fetched refs when backfilling tagsKarthik Nayak, Oct 28, 2026
  23. 1/3 transport: add `transport_options_release()`Karthik Nayak, Oct 28, 2026
  24. Patrick SteinhardtOct 28, 2026
  25. Karthik NayakOct 28, 2026
  26. Patrick SteinhardtOct 29, 2026
  27. Karthik NayakOct 29, 2026
  28. 2/3 fetch: advertise fetched refs when backfilling tagsKarthik Nayak, Oct 28, 2026
  29. 3/3 t5510: cover upstream info update on fetch failureKarthik Nayak, Oct 28, 2026
  30. Patrick SteinhardtOct 28, 2026
  31. Karthik NayakOct 28, 2026
  32. 0/3 fetch: advertise fetched refs when backfilling tagsKarthik Nayak, Oct 29, 2026
  33. 1/3 t5510: cover upstream info update on fetch failureKarthik Nayak, Oct 29, 2026
  34. 2/3 transport: add `transport_options_release()`Karthik Nayak, Oct 29, 2026
  35. 3/3 fetch: advertise fetched refs when backfilling tagsKarthik Nayak, Oct 29, 2026
  36. Patrick SteinhardtOct 29, 2026

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.