Re: [PATCH/RFC 4/6] transport: add refspec list parameters to functions
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Apr 19, 2016, 20:55 UTC
- Message-ID
- <xmqqlh49z5cg.fsf@gitster.mtv.corp.google.com>
- In-Reply-To
- <20160419071403.GA22577@sigill.intra.peff.net>
Jeff King <peff@peff.net> writes:
Show 14 quoted lines
>> What the code tries to do I am more than halfway happy. It is >> unfortunate that we cannot do this natively without upgrading the >> protocol in a fundamental way, but this is a nice way to work it >> around only for Git-over-HTTP transport without having to break the >> protocol. > > I dunno, I am a bit negative on bringing new features to Git-over-HTTP > (which is already less efficient than the other protocols!) without any > plan for supporting them in the other protocols. > > I thought Stefan's v2 protocol work looked quite good, but it seems to > have stalled. The hardest part of that topic is figuring out the upgrade > path. But for git-over-http, we can solve that in the same way that > David is passing in the extra refspecs.
Yeah, I had the same feeling.
Show 8 quoted lines
> So I'd rather see something like: > > 1. Support for v2 "capabilities only" initial negotiation, followed > by ref advertisement. > > 2. Support for refspec-limiting capability. > > 3. HTTP-only option from client to trigger v2 on the server.
I like that; reducing the initial scope of v2 so that we can do this new feature as its first use case would be a good way to move things forward.
Show 5 quoted lines
> That's still HTTP-specific, but it has a clear path for converging with > the ssh and git protocols eventually, rather than having to support > magic out-of-band capabilities forever. > > It does require an extra round of HTTP request/response, though.
Yes. And as we discussed before, we can do "upload-pack" that advertises "by the way, upload-pack-v2 is available next to me" and a separate "upload-pack-v2" that talks v2 (i.e. its initial message is limited to capabilities and nothing else) would probably be a sufficient migration path for native protocol.