From: Jeff King <peff@peff.net>
To: Junio C Hamano <gitster@pobox.com>
Cc: Stefan Beller <sbeller@google.com>,
Jason Paller-Rzepka <jasonpr@google.com>,
"git@vger.kernel.org" <git@vger.kernel.org>
Subject: Re: Multiple fetches when unshallowing a shallow clone
Date: Fri, 4 Dec 2015 17:10:09 -0500 [thread overview]
Message-ID: <20151204221009.GA23129@sigill.intra.peff.net> (raw)
In-Reply-To: <xmqqoae5ri5x.fsf@gitster.mtv.corp.google.com>
On Fri, Dec 04, 2015 at 01:57:30PM -0800, Junio C Hamano wrote:
> Jeff King <peff@peff.net> writes:
>
> > This seems to reproduce consistently for me:
> >
> > $ git clone --depth=1 git://github.com/git/git
> > Cloning into 'git'...
> > remote: Counting objects: 2925, done.
> > remote: Compressing objects: 100% (2602/2602), done.
> > remote: Total 2925 (delta 230), reused 2329 (delta 206), pack-reused 0
> > Receiving objects: 100% (2925/2925), 6.17 MiB | 10.80 MiB/s, done.
> > Resolving deltas: 100% (230/230), done.
> >
> > $ cd git
> > $ git fetch --unshallow
> > remote: Counting objects: 185430, done.
> > remote: Compressing objects: 100% (46933/46933), done.
> > remote: Total 185430 (delta 140505), reused 181589 (delta 136694), pack-reused 0
> > Receiving objects: 100% (185430/185430), 52.80 MiB | 10.84 MiB/s, done.
> > Resolving deltas: 100% (140505/140505), completed with 1784 local objects.
> > remote: Counting objects: 579, done.
> > remote: Compressing objects: 100% (579/579), done.
> > remote: Total 579 (delta 0), reused 579 (delta 0), pack-reused 0
> > Receiving objects: 100% (579/579), 266.85 KiB | 0 bytes/s, done.
> > [... fetch output ...]
> >
> > That looks like two packs being received for the --unshallow case.
>
> What is puzzling is that I do not seem to see this "two fetches"
> with the local transport. I only see "deepen 2147483647" in the
> protocol log.
Yeah, I do not ever see "deepen 0" from GIT_TRACE_PACKET output. FWIW,
here's the output I am using to reproduce this locally:
# do this once
git clone --bare git://github.com/git/git src.git
# do this for each test run
rm -rf repo
git clone --no-local --depth=1 src.git repo
cd repo
echo "==> unshallow" &&
git fetch --progress --unshallow 2>&1 | grep remote
And you can see that there are two separate sections (and I traced this
to backfill_tags() with gdb).
Note that the issue goes away if the shallow clone is done with "--bare"
(I guess because we pick up tags differently in the initial clone?).
-Peff
prev parent reply other threads:[~2015-12-04 22:10 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-11-30 19:35 Multiple fetches when unshallowing a shallow clone Jason Paller-Rzepka
2015-12-04 20:46 ` Stefan Beller
2015-12-04 21:27 ` Jeff King
2015-12-04 21:36 ` Stefan Beller
2015-12-04 21:38 ` Jason Paller-Rzepka
2015-12-04 21:50 ` Stefan Beller
2015-12-04 21:51 ` Jeff King
2015-12-04 22:45 ` Junio C Hamano
2015-12-05 5:33 ` Duy Nguyen
2015-12-06 4:00 ` Junio C Hamano
2015-12-06 6:37 ` Jeff King
2015-12-06 7:01 ` Jeff King
2015-12-06 10:46 ` Duy Nguyen
2015-12-07 19:57 ` Jason Paller-Rzepka
[not found] ` <CACs8u9RzUVWw2Ld1K7JeO7Eci114JEiML8bbGy96m4pZZk=FnA@mail.gmail.com>
2015-12-07 21:21 ` Duy Nguyen
2015-12-07 21:27 ` Junio C Hamano
2015-12-07 21:42 ` Jeff King
2015-12-04 21:57 ` Junio C Hamano
2015-12-04 22:10 ` Jeff King [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20151204221009.GA23129@sigill.intra.peff.net \
--to=peff@peff.net \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=jasonpr@google.com \
--cc=sbeller@google.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).