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

Re: [RFC 0/4] Shallow clones with on-demand fetch

From
JTJonathan Tan <jonathantanmy@google.com>
Date
Mar 6, 2017, 19:16 UTC
Message-ID
<c8788f30-263b-c96a-239d-940743b96b53@google.com>
In-Reply-To
<20170304191901.9622-1-markbt@efaref.net>
On 03/04/2017 11:18 AM, Mark Thomas wrote:
> I was inspired a bit by Microsoft's announcement of their Git VFS.  I
> saw that people have talked in the past about making git fetch objects
> from remotes as they are needed, and decided to give it a try.
For reference, one such conversation is [1]. (cc-ing Ben Peart also)
Show 7 quoted lines
> The patch series adds a "--on-demand" option to git clone, which, when
> used in conjunction with the existing shallow clone operations, clones
> the full history of the repository's commits, but only the files that
> would be included in the shallow clone.
>
> When a file that is missing is required, git requests the file on-demand
> from the remote, via a new 'upload-file' service.

A reachability check (of the blob) might be a good idea. The current Git implementation already supports fetching a blob (perhaps a bug) but has problems with reachability calculations that I tried to fix in [2], but found some bugs that weren't easily fixable.

As I said in [2], I think that proper fetching of blobs on demand is a prerequisite to any sort of missing object tolerance (like your on-demand clones), so I haven't thought much about the topics in the rest of your patch set.

[1] <20170113155253.1644-1-benpeart@microsoft.com> (you can search for emails by Message ID in online archives like https://public-inbox.org/git if you don't already have them) [2] <cover.1487984670.git.jonathantanmy@google.com>

Previous: Jeff KingNext: Stefan Beller
Message 8 of 9 in “[RFC 0/4] Shallow clones with on-demand fetch”
  1. Mark ThomasMar 4, 2017
  2. 3/4 upload-pack: Send all commits if client requests on-demandMark Thomas, Mar 4, 2017
  3. 4/4 clone: Request on-demand shallow clonesMark Thomas, Mar 4, 2017
  4. 1/4 upload-file: Add upload-file commandMark Thomas, Mar 4, 2017
  5. 2/4 on-demand: Fetch missing files from remoteMark Thomas, Mar 4, 2017
  6. Junio C HamanoMar 6, 2017
  7. Jeff KingMar 7, 2017
  8. Jonathan TanMar 6, 2017
  9. Stefan BellerMar 6, 2017

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.