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

Re: [PATCH 2/2] fetch-pack: do not check links for partial fetch

From
JTJonathan Tan <jonathantanmy@google.com>
Date
Mar 14, 2018, 22:24 UTC
Message-ID
<20180314152429.df14adfb49b028e2e2a9001a@google.com>
In-Reply-To
<xmqqwoyexqy4.fsf@gitster-ct.c.googlers.com>

On Wed, 14 Mar 2018 14:55:31 -0700 Junio C Hamano <gitster@pobox.com> wrote:

Show 13 quoted lines
> Jonathan Tan <jonathantanmy@google.com> writes:
> 
> > When doing a partial clone or fetch with transfer.fsckobjects=1, use the
> > --fsck-objects instead of the --strict flag when invoking index-pack so
> > that links are not checked, only objects. This is because incomplete
> > links are expected when doing a partial clone or fetch.
> 
> It is expected that _some_ links are missing, but this makes me
> wonder if we can do better than disabling the connectivity check
> altogether.  Does "git fetch" lack sufficient information to attempt
> the connectivity check, and when (and only when) it hits a broken
> link, see if that is because the connectivity check traversal is
> crossing a "partial" fetch boundary, or something along that line?

Our only definition (currently) for the "partial" fetch boundary is whether an object in a promisor packfile (a packfile obtained from the promisor remote) references it, so I think that checking for crossing a "partial" fetch boundary does not add anything. This is because by that definition, any missing links observed from objects newly fetched from the promisor remote cross a "partial" fetch boundary (since all objects fetched in this way "promise" all objects that they refer to).

But it is true that we might be able to do better in checking, for example, that a packfile fetched using a blob size limit contains all referenced trees (that is, only blobs are allowed to be missing).

Previous: Junio C HamanoNext: Junio C Hamano
Message 5 of 6 in “Make partial clone/fetch work when transfer.fsckobjects=1”
  1. 0/2 Make partial clone/fetch work when transfer.fsckobjects=1Jonathan Tan, Mar 14, 2018
  2. 1/2 index-pack: support checking objects but not linksJonathan Tan, Mar 14, 2018
  3. 2/2 fetch-pack: do not check links for partial fetchJonathan Tan, Mar 14, 2018
  4. Junio C HamanoMar 14, 2018
  5. Jonathan TanMar 14, 2018
  6. Junio C HamanoMar 15, 2018

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.