Re: [PATCH v2 2/2] diff: batch fetching of missing blobs

2019-04-08 Thread Christian Couder
On Mon, Apr 8, 2019 at 9:59 AM Junio C Hamano wrote: > > Christian Couder writes: > > > I will at least add something telling that in most cases > > "repository_format_partial_clone" and fetch_objects() shouldn't be > > used directly anymore. > > Yes, that would be necessary not in the log, but i

Re: [PATCH v2 2/2] diff: batch fetching of missing blobs

2019-04-08 Thread Junio C Hamano
Christian Couder writes: > Patch 3f82acbca2 (Use promisor_remote_get_direct() and > has_promisor_remote(), 2019-04-01) in cc/multi-promisor starts with: > > Use promisor_remote_get_direct() and has_promisor_remote() > > Instead of using the repository_format_partial_clone global > and

Re: [PATCH v2 2/2] diff: batch fetching of missing blobs

2019-04-07 Thread Christian Couder
On Mon, Apr 8, 2019 at 8:03 AM Junio C Hamano wrote: > > Junio C Hamano writes: > > >>> #include "fetch-object.h" > >>> +#include "promisor-remote.h" > >> > >> Thanks. > > > > Together with "if we are forbidding the direct access to the > > repository_format_partial_clone variable and the fetch_

Re: [PATCH v2 2/2] diff: batch fetching of missing blobs

2019-04-07 Thread Christian Couder
On Mon, Apr 8, 2019 at 4:36 AM Junio C Hamano wrote: > > Christian Couder writes: > > > #ifdef NO_FAST_WORKING_DIRECTORY > > #define FAST_WORKING_DIRECTORY 0 > > @@ -6489,7 +6490,7 @@ static void add_if_missing(struct oid_array *to_fetch, > > > > void diffcore_std(struct diff_options *options)

Re: [PATCH v2 2/2] diff: batch fetching of missing blobs

2019-04-07 Thread Junio C Hamano
Junio C Hamano writes: >>> #include "fetch-object.h" >>> +#include "promisor-remote.h" >> >> Thanks. > > Together with "if we are forbidding the direct access to the > repository_format_partial_clone variable and the fetch_objects() > funciton, make it clear that is what is being done in the > m

Re: [PATCH v2 2/2] diff: batch fetching of missing blobs

2019-04-07 Thread Junio C Hamano
Junio C Hamano writes: > Christian Couder writes: > >> Thanks for investigating! Yeah, that's part of the problem. >> >> The fix I would suggest is: >> >> diff --git a/diff.c b/diff.c >> index f685ab10b5..a2b1241f83 100644 >> --- a/diff.c >> +++ b/diff.c >> @@ -26,6 +26,7 @@ >> #include "parse-

Re: [PATCH v2 2/2] diff: batch fetching of missing blobs

2019-04-07 Thread Junio C Hamano
Christian Couder writes: > Thanks for investigating! Yeah, that's part of the problem. > > The fix I would suggest is: > > diff --git a/diff.c b/diff.c > index f685ab10b5..a2b1241f83 100644 > --- a/diff.c > +++ b/diff.c > @@ -26,6 +26,7 @@ > #include "parse-options.h" > #include "help.h" > #in

Re: [PATCH v2 2/2] diff: batch fetching of missing blobs

2019-04-06 Thread Christian Couder
Hi, On Fri, Apr 5, 2019 at 3:38 PM Johannes Schindelin wrote: > On Thu, 4 Apr 2019, SZEDER Gábor wrote: > > > On Fri, Mar 29, 2019 at 02:39:28PM -0700, Jonathan Tan wrote: > > > diff --git a/t/t4067-diff-partial-clone.sh b/t/t4067-diff-partial-clone.sh > > > new file mode 100755 > > > index

Re: [PATCH v2 2/2] diff: batch fetching of missing blobs

2019-04-05 Thread Johannes Schindelin
Hi Jonathan, On Fri, 29 Mar 2019, Jonathan Tan wrote: > When running a command like "git show" or "git diff" in a partial clone, > batch all missing blobs to be fetched as one request. > > This is similar to c0c578b33c ("unpack-trees: batch fetching of missing > blobs", 2017-12-08), but for anoth

Re: [PATCH v2 2/2] diff: batch fetching of missing blobs

2019-04-05 Thread Johannes Schindelin
Hi, On Thu, 4 Apr 2019, SZEDER Gábor wrote: > On Fri, Mar 29, 2019 at 02:39:28PM -0700, Jonathan Tan wrote: > > diff --git a/t/t4067-diff-partial-clone.sh b/t/t4067-diff-partial-clone.sh > > new file mode 100755 > > index 00..349851be7d > > --- /dev/null > > +++ b/t/t4067-diff-partial-clo

Re: [PATCH v2 2/2] diff: batch fetching of missing blobs

2019-04-05 Thread Duy Nguyen
On Sat, Mar 30, 2019 at 4:40 AM Jonathan Tan wrote: > > When running a command like "git show" or "git diff" in a partial clone, > batch all missing blobs to be fetched as one request. > > This is similar to c0c578b33c ("unpack-trees: batch fetching of missing > blobs", 2017-12-08), but for anothe

Re: [PATCH v2 2/2] diff: batch fetching of missing blobs

2019-04-03 Thread SZEDER Gábor
On Fri, Mar 29, 2019 at 02:39:28PM -0700, Jonathan Tan wrote: > diff --git a/t/t4067-diff-partial-clone.sh b/t/t4067-diff-partial-clone.sh > new file mode 100755 > index 00..349851be7d > --- /dev/null > +++ b/t/t4067-diff-partial-clone.sh > @@ -0,0 +1,103 @@ > +#!/bin/sh > + > +test_descrip

[PATCH v2 2/2] diff: batch fetching of missing blobs

2019-03-29 Thread Jonathan Tan
When running a command like "git show" or "git diff" in a partial clone, batch all missing blobs to be fetched as one request. This is similar to c0c578b33c ("unpack-trees: batch fetching of missing blobs", 2017-12-08), but for another command. Signed-off-by: Jonathan Tan --- diff.c