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

Re: [PATCH] send-pack: use OBJECT_INFO_QUICK to check negative objects

From
Junio C Hamano <gitster@pobox.com>
Date
Dec 4, 2019, 21:37 UTC
Message-ID
<xmqqr21j3h7e.fsf@gitster-ct.c.googlers.com>
In-Reply-To
<20191204205353.118168-1-jonathantanmy@google.com>
Jonathan Tan <jonathantanmy@google.com> writes:
Show 9 quoted lines
> As for whether we should do it in the first place, I think that having 2
> orthogonal flags is clearer than having 1 that controls fetch
> (SKIP_FETCH) and 1 that does both (QUICK) without any that recheck
> packed, but I'm quite familiar with this part of the code, so perhaps
> I'm the wrong person to ask - we should optimize for the typical Git
> developer who just wants to access the object store. Judging from the
> frequency in which we encounter this issue (as Peff says), maybe we
> should go ahead and make QUICK imply SKIP_FETCH but not the other way
> around.
Thanks for thinking this through.  I am OK with that direction.
> (It is also possible just to make both imply the other and unify
> QUICK and SKIP_FETCH into one flag - I am not opposed to that -
> although read my email that Peff linked to see why bidirectional
> implication is correct in one sense but incorrect in another.)
Yup, also from the old message:
Show 6 quoted lines
> Having said that, perhaps we should consider promisor-remote.c as
> low-level code and expect it to know that objects are fetched into a
> packfile (as opposed to loose objects), so it can safely use QUICK
> (which is documented as checking packed after packed and loose). If no
> one disagrees, I can make such a patch after jt/push-avoid-lazy-fetch is
> merged to master (as is the plan, according to What's Cooking [1]).

I agree that it makes sense to treat promisor-remote.c as the low-level implementation detail that is allowed to be intimately familiar with how its behaviour would interact with QUICK and SKIP_FETCH options.

Thanks.
Previous: Jonathan TanNext: Jonathan Nieder
Message 8 of 12 in “Push a ref to a remote with many refs”
  1. Patrick Marlier (pamarlie)Nov 19, 2019
  2. Patrick Marlier (pamarlie)Nov 25, 2019
  3. send-pack: use OBJECT_INFO_QUICK to check negative objectsJeff King, Nov 27, 2019
  4. Patrick Marlier (pamarlie)Nov 29, 2019
  5. Junio C HamanoNov 30, 2019
  6. Jeff KingDec 3, 2019
  7. Jonathan TanDec 4, 2019
  8. Junio C HamanoDec 4, 2019
  9. Jonathan NiederDec 4, 2019
  10. Jeff KingDec 4, 2019
  11. Patrick Marlier (pamarlie)Dec 10, 2019
  12. Jeff KingDec 10, 2019

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.