Subject: Re: [PATCH v4] technical doc: add a design doc for hash function transition

From: Junio C Hamano <[email-masked]>
Date: Wed, 04 Oct 2017 10:44:13 +0900

Jonathan Nieder <[email-masked]> writes:

> +Alternatives considered
> +-----------------------
> +Upgrading everyone working on a particular project on a flag day
> +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> ...
> +Using hash functions in parallel
> +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> ...

Good that we are not doing these ;-)

> +Lazily populated translation table
> +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> +Some of the work of building the translation table could be deferred to
> +push time, but that would significantly complicate and slow down pushes.
> +Calculating the sha1-name at object creation time at the same time it is
> +being streamed to disk and having its newhash-name calculated should be
> +an acceptable cost.

And the version described in the body of the document hopefully
would be simpler.  It certainly would be, when SHA-1 content and
NewHash content are the same (i.e. blob).

THanks.