Re: [PATCH/RFC 4/6] transport: add refspec list parameters to functions
On Mon, 2016-04-18 at 11:45 -0700, Junio C Hamano wrote:
Show 29 quoted lines
> David Turner <dturner@twopensource.com> writes:
>
> > Add parameters for a list of refspecs to transport_get_remote_refs
> > and
> > get_refs_list. These parameters are presently unused -- soon, we
> > will
> > use them to implement fetches which only learn about a subset of
> > refs.
> >
> > Signed-off-by: David Turner <dturner@twopensource.com>
> > ---
>
> 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.
>
> As a POC it is OK, but I am moderately unhappy with the use of
> "refspec" here.
>
> At the transport layer, we shouldn't care what the receiving end
> intends to do with the objects that sits at the tip of the refs at
> the other end, so sending "refspecs" down feels somewhat wrong for
> this feature. At one layer up in the next patch, you do use
> "interesting refs" which makes it clear that only the left-hand-side
> of a refspec, i.e. what they call it, matters, and I think that is a
> much better phrasing of the concept (and the passed data should only
> be the left-hand-side of refspecs).
I will rename the parameter to "interesting_refs".