git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: Jonathan Nieder <jrnieder@gmail.com>
Cc: Elijah Newren <newren@gmail.com>,
	Git Mailing List <git@vger.kernel.org>,
	Derrick Stolee <stolee@gmail.com>,
	Jonathan Tan <jonathantanmy@google.com>,
	Minh Thai <mthai@google.com>
Subject: Re: Huge push upload despite only having a tiny change
Date: Wed, 03 Jun 2020 13:39:28 -0700	[thread overview]
Message-ID: <xmqqpnafriin.fsf@gitster.c.googlers.com> (raw)
In-Reply-To: <20200603015314.GA253041@google.com> (Jonathan Nieder's message of "Tue, 2 Jun 2020 18:53:14 -0700")

Jonathan Nieder <jrnieder@gmail.com> writes:

> There is one trick a server can use to mitigate this: advertise some
> refs that don't exist!  If you advertise a ref ".have", then Git
> will understand that the server has that object but it is not an
> actual ref.  Gerrit uses this trick in its HackPushNegotiateHook[1]
> to advertise a few recent commits.
> ...
> Summary: (1) try fetching first (2) let's improve
> HackPushNegotiateHook#advertiseRefs (3) let's improve "git push"
> protocol to make this a problem of the past.

In the meantime, perhaps we can teach receive-pack the same "let's
advertise a few recent commits as if they exist as tips of refs" as
well?

      parent reply	other threads:[~2020-06-03 20:39 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-06-02 19:21 Huge push upload despite only having a tiny change Elijah Newren
2020-06-02 19:40 ` Derrick Stolee
2020-06-03  1:35   ` Elijah Newren
2020-06-03  1:53 ` Jonathan Nieder
2020-06-03  2:36   ` Elijah Newren
2020-06-03 20:39   ` Junio C Hamano [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=xmqqpnafriin.fsf@gitster.c.googlers.com \
    --to=gitster@pobox.com \
    --cc=git@vger.kernel.org \
    --cc=jonathantanmy@google.com \
    --cc=jrnieder@gmail.com \
    --cc=mthai@google.com \
    --cc=newren@gmail.com \
    --cc=stolee@gmail.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).