Re: [PATCH 08/17] pack-objects: add --path-walk option

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



"Derrick Stolee via GitGitGadget" <gitgitgadget@xxxxxxxxx> writes:
> This new walk is incompatible with some features and is ignored by
> others:
> 
>  * Object filters are not currently integrated with the path-walk API,
>    such as sparse-checkout or tree depth. A blobless packfile could be
>    integrated easily, but that is deferred for later.
> 
>  * Server-focused features such as delta islands, shallow packs, and
>    using a bitmap index are incompatible with the path-walk API.
> 
>  * The path walk API is only compatible with the --revs option, not
>    taking object lists or pack lists over stdin. These alternative ways
>    to specify the objects currently ignores the --path-walk option
>    without even a warning.

It might be better to declare --path-walk as "internal use only" and
only supporting what send-pack.c (used by "git push") and "git repack"
needs. (From this list, it seems that there is a lot of incompatibility,
some of which can happen without a warning to the user, so it sounds
better to be up-front and say that we only support what send-pack.c
needs. This also makes reviewing easier, as we don't have to think about
the possible interactions with every other rev-list feature - only what
is used by send-pack.c.)

Also from a reviewer perspective, it might be better to restrict this
patch set to what send-pack.c needs and leave "git repack" for a future
patch set. This means that we would not need features such as blob
and tree exclusions, and possibly not even bitmap use or delta reuse
(assuming that the user would typically push recently-created objects
that have not been repacked).

> +		/* Skip objects that do not exist locally. */
> +		if (exclude_promisor_objects &&
> +		    oid_object_info_extended(the_repository, oid, &oi,
> +					     OBJECT_INFO_FOR_PREFETCH) < 0)
> +			continue;

This functionality is typically triggered by --missing=allow;
--exclude_promisor_objects means (among other things) that we allow
a missing link only if that object is known to be a promisor object
(because another promisor object refers to it) (see Documentation/
rev-list-options.txt, and also get_reference() and elsewhere in
revision.c - notice how is_promisor_object() is paired with it)

Having said that, we should probably just fail outright on missing
objects, whether or not we have exclude_promisor_objects. If we have
computed that we need to push an object, that object needs to exist.
(Same for repack.)




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux