From: Jeff King <peff@peff.net>
To: Junio C Hamano <gitster@pobox.com>
Cc: Bryan Turner <bturner@atlassian.com>,
Jonathan Nieder <jrnieder@gmail.com>,
Git Users <git@vger.kernel.org>
Subject: Re: http-protocol question
Date: Tue, 2 Dec 2014 14:50:51 -0500 [thread overview]
Message-ID: <20141202195050.GA23461@peff.net> (raw)
In-Reply-To: <xmqqzjb6kkt9.fsf@gitster.dls.corp.google.com>
On Tue, Dec 02, 2014 at 09:45:06AM -0800, Junio C Hamano wrote:
> Jeff King <peff@peff.net> writes:
>
> > For a public repository, it might make sense to provide a config option
> > to loosen the is_our_ref check completely (i.e., to just has_sha1_file).
> > But such an option does not yet exist.
>
> In principle, yes, but that cannot be has_sha1_file(); it has to
> have a fully connected healthy history behind it.
I thought about that, but I wonder if it matters whether we check up
front. We are not advertising it, but only trying our best to fulfill
the "want" from the other side. So either:
1. We check immediately whether we have the full history behind it,
and reject the "want" otherwise.
2. We start pack-objects on it, and the first thing it will do is
collect the full set of objects to send. If it doesn't have them,
it will barf.
Probably (1) would produce nicer error messages, but (2) is a lot more
efficient.
I dunno. I am not volunteering to implement, so I will leave thinking on
it more to somebody who wants to do so. :)
-Peff
prev parent reply other threads:[~2014-12-02 19:50 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-12-02 2:17 http-protocol question Bryan Turner
2014-12-02 3:34 ` Jonathan Nieder
2014-12-02 4:28 ` Bryan Turner
2014-12-02 4:29 ` Bryan Turner
2014-12-02 4:45 ` Jonathan Nieder
2014-12-02 5:04 ` Bryan Turner
2014-12-02 5:17 ` Jonathan Nieder
2014-12-02 5:30 ` Duy Nguyen
2014-12-02 5:37 ` Duy Nguyen
2014-12-02 5:33 ` Jeff King
2014-12-02 5:47 ` Bryan Turner
2014-12-02 5:52 ` Jeff King
2014-12-02 17:45 ` Junio C Hamano
2014-12-02 19:50 ` 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=20141202195050.GA23461@peff.net \
--to=peff@peff.net \
--cc=bturner@atlassian.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=jrnieder@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).