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

Re: Mercurial 0.4e vs git network pull

From
MMMatt Mackall <mpm@selenic.com>
Date
May 13, 2005, 02:44 UTC
Message-ID
<20050513024427.GL5914@waste.org>
In-Reply-To
<Pine.LNX.4.21.0505122148480.30848-100000@iabervon.org>
On Thu, May 12, 2005 at 10:23:01PM -0400, Daniel Barkalow wrote:
Show 21 quoted lines
> On Thu, 12 May 2005, Matt Mackall wrote:
> 
> > On Thu, May 12, 2005 at 08:33:56PM -0400, Daniel Barkalow wrote:
> >
> > > Yes, although that also includes pulling the commits, and may be
> > > interleaved with pulling the trees and objects to cover the
> > > latency. (I.e., one round trip gets the new head hash; the second gets
> > > that commit; on the third the tree and the parent(s) can be requested at
> > > once; on the fouth the contents of the tree and the grandparents, at
> > > which point the bandwidth will probably be the limiting factor for the
> > > rest of the operation.)
> > 
> > What if a changeset is smaller than the bandwidth-delay product of
> > your link? As an extreme example, Mercurial is currently at a point
> > where its -entire repo- changegroup (set of all changesets) can be in
> > flight on the wire on a typical link.
> 
> If this is common for the repository in question, then it will be forced
> to wait for the parent to come in, true. If you have a number of merges,
> however, you start using more total bandwidth relative to latency while
> tracking them in parallel.
No, you're missing my point. If you can request all the files in a
changeset in less than a round-trip time, you have a pipeline stall.
Let's say a changeset is 10k and round trip time is 100ms. That means
you'll stall on any pipe with more than 100k/s. You won't know what
changeset to request next as it'll still be in flight.
 
Show 19 quoted lines
> > > I must be misunderstanding your numbers, because 6 HTTP responses is more
> > > than 1K, ignoring any actual content from the server, and 1K for 800
> > > commits is less than 2 bytes per commit.
> > 
> > 1k of application-level data, sorry. And my whole point is that I
> > don't send those 800 commit identifiers (which are 40 bytes each as
> > hex). I send about 30 or so. It's basically a negotiation to find the
> > earliest commits not known to the client with a minimum of round trips
> > and data exchange.
> 
> Does this rely on the history being entirely linear? I suppose that
> requesting a rev-list from the server (which could have it as a static
> file generated when a new head was pushed) could jumpstart the
> process. The client could request all of the commits it doesn't have in
> rapid succession, and then request trees as the commits started coming
> in. Of course, this would get inefficient if you were, for example,
> pulling a merge with a branch with a long history, since you'd get a ton
> of old mainline (which you already have) interleaved with occasional new
> things.

I don't depend on history being linear (I'm not reinventing CVS here) and I don't grab a list of all revisions (the point is to be scalable). In fact, I do something fairly clever, and something I don't think will work with git, because, yet again, it lacks the metadata.

Show 16 quoted lines
> > > I'm also worried about testing on 800 linear commits, since the projects
> > > under consideration tend to have very non-linear histories. 
> > 
> > Not true at all. Dumps from Andrew to Linus via patch bombs will
> > result in runs of hundreds of linear commits on a regular basis.
> > Linear patch series are the preferred way to make changes and series
> > of 30 or 40 small patches are not at all uncommon.
> 
> It has sounded like Andrew had some interest in using git, and a number of
> other developers are using it already. If this becomes still more common,
> it may be the case that, instead of sending patch bombs, Andrew will point
> Linus at authors' original series, in which case the mainline would be
> merges of a hundred linear series of various lengths. I had the
> impression, although I never looked carefully, that this was happening on
> a smaller scale with BK, where work by BK users got included using BK,
> rather than as patches applied out of a bomb.

Andrew already uses git, in a manner much like he used BK. He does a pull from a repo, generates a patch of that repo vs mainline, and puts that in -mm. And never passes that stuff on to Linus.

-- 
Mathematics is the supreme nostalgia of our time.
Previous: Daniel BarkalowNext: Petr Baudis
Message 11 of 14 in “Mercurial 0.4e vs git network pull”
  1. Matt MackallMay 12, 2005
  2. Petr BaudisMay 12, 2005
  3. Matt MackallMay 12, 2005
  4. Petr BaudisMay 12, 2005
  5. Matt MackallMay 12, 2005
  6. Daniel BarkalowMay 12, 2005
  7. Matt MackallMay 12, 2005
  8. Daniel BarkalowMay 13, 2005
  9. Matt MackallMay 13, 2005
  10. Daniel BarkalowMay 13, 2005
  11. Matt MackallMay 13, 2005
  12. Petr BaudisMay 13, 2005
  13. Petr BaudisMay 15, 2005
  14. Ingo MolnarMay 15, 2005

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.