From: Phil Hord <hordp@cisco.com>
To: david@lang.hm
Cc: Nicolas Pitre <nico@fluxnic.net>,
George Spelvin <linux@horizon.com>,
anthonyvdgent@gmail.com, git@vger.kernel.org,
torvalds@linux-foundation.org
Subject: Re: Git commit generation numbers
Date: Wed, 20 Jul 2011 20:39:28 -0400 [thread overview]
Message-ID: <4E277540.7080408@cisco.com> (raw)
In-Reply-To: <alpine.DEB.2.02.1107201714140.6412@asgard.lang.hm>
On 07/20/2011 08:18 PM, david@lang.hm wrote:
> On Wed, 20 Jul 2011, Phil Hord wrote:
>
>> On 07/20/2011 07:36 PM, Nicolas Pitre wrote:
>>> On Wed, 20 Jul 2011, david@lang.hm wrote:
>>>
>>>> If the generation number is part of the repository then it's going to
>>>> be the same for everyone.
>>> The actual generation number will be, and has to be, the same for
>>> everyone with the same repository content, regardless of the cache
>>> used.
>>> It is a well defined number with no room to interpretation.
>>
>> Nonsense.
>>
>> Even if the generation number is well-defined and shared by all
>> clients, the only quasi-essential definition is "for each A in
>> ancestors_of(B), gen(A) < gen(B)".
>>
>> In practice, the actual generation number *will be the same* for
>> everyone with the same repository content, unless and until someone
>> develops a different calculation method. But there is no reason to
>> require that the number *has to be* the same for everyone unless you
>> expect (or require) everyone to share their gen-caches.
>
> and I think this is why Linus is not happy with a cache. He is seeing
> this as something that has significantly more value if it is going to
> be consistant in a distributed manner than if it's just something
> calculated locally that can be different from other systems.
It will only be used locally, so it needn't be consistent with anyone
else's.
>
> if it's just locally generated, then I could easily see generation
> numbers being different on different people's ssstems, dependin on the
> order that they see commits (either locally generated or pulled from
> others)
>
> If it's part of the commit, then as that commit gets propogated the
> generation number gets propogated as well, and every repository will
> agree on what the generation number is for any commit that's shared.
>
> I agree that this consistancy guarantee seems to be valuable.
I can't see why.
>> Surely there will be a competent and efficient gen-cache API. But
>> most code can just ask if B --contains A or even just use rev-list
>> and benefit from the increased speed of the answer. Because most
>> code doesn't really care about the gen numbers themselves, but only
>> the speed of determining ancestry.
>
> in that case, why bother with generation numbers at all? the improved
> data based heristic seems to solve that problem.
Does it? Surely the ruckus would've died down in that case. But I
haven't been reading pu.
It seems to me that the main drawback to a gen-cache is that it slows
down the first operation after even a local clone (with just hardlinks).
On the other hand, I see too many nails in the distributed-gen-numbers
coffin: legacy commits can't catch up (and therefore suffer), and
legacy clients can trash or corrupt even "new-style" commits.
Phil
next prev parent reply other threads:[~2011-07-21 0:39 UTC|newest]
Thread overview: 89+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-07-17 18:27 Git commit generation numbers George Spelvin
2011-07-17 19:00 ` Long, Martin
2011-07-17 19:30 ` Linus Torvalds
2011-07-17 23:39 ` George Spelvin
2011-07-17 23:58 ` Linus Torvalds
2011-07-18 5:13 ` George Spelvin
2011-07-18 10:28 ` Anthony Van de Gejuchte
2011-07-18 11:48 ` George Spelvin
2011-07-20 20:51 ` Nicolas Pitre
2011-07-20 22:16 ` George Spelvin
2011-07-20 23:26 ` david
2011-07-20 23:36 ` Nicolas Pitre
2011-07-21 0:08 ` Phil Hord
2011-07-21 0:18 ` david
2011-07-21 0:37 ` Shawn Pearce
2011-07-21 0:47 ` Phil Hord
2011-07-21 4:26 ` david
2011-07-21 12:43 ` George Spelvin
2011-07-21 19:19 ` Jakub Narebski
2011-07-21 20:27 ` George Spelvin
2011-07-21 20:33 ` Shawn Pearce
2011-07-22 12:18 ` Jakub Narebski
2011-07-22 13:09 ` Nicolas Pitre
2011-07-22 18:02 ` david
2011-07-22 18:34 ` Jakub Narebski
2011-07-22 19:06 ` Linus Torvalds
2011-07-22 22:02 ` Jeff King
2011-07-28 15:00 ` Felipe Contreras
2011-09-06 10:02 ` Ramkumar Ramachandra
2011-07-22 19:08 ` david
2011-07-22 19:40 ` Nicolas Pitre
2011-07-22 18:02 ` david
2011-07-21 0:39 ` Phil Hord [this message]
2011-07-21 0:58 ` Nicolas Pitre
2011-07-21 1:09 ` Phil Hord
2011-07-21 12:03 ` Drew Northup
2011-07-21 12:55 ` George Spelvin
2011-07-21 15:57 ` Drew Northup
2011-07-21 16:24 ` Phil Hord
2011-07-21 22:40 ` Pēteris Kļaviņš
2011-07-22 9:30 ` Christian Couder
2011-07-21 17:36 ` George Spelvin
-- strict thread matches above, loose matches on Subject: below --
2011-07-14 18:24 Linus Torvalds
2011-07-14 18:37 ` Jeff King
2011-07-14 18:47 ` Linus Torvalds
2011-07-14 18:55 ` Linus Torvalds
2011-07-14 19:12 ` Jeff King
2011-07-14 19:46 ` Ted Ts'o
2011-07-14 19:51 ` Linus Torvalds
2011-07-14 20:07 ` Jeff King
2011-07-14 20:08 ` Ted Ts'o
2011-07-14 19:08 ` Jeff King
2011-07-14 19:23 ` Linus Torvalds
2011-07-14 20:01 ` Jeff King
2011-07-14 20:19 ` Linus Torvalds
2011-07-14 20:31 ` Jeff King
2011-07-15 1:19 ` Linus Torvalds
2011-07-15 2:41 ` Geert Bosch
2011-07-15 7:46 ` Jeff King
2011-07-15 16:10 ` Linus Torvalds
2011-07-15 16:18 ` Shawn Pearce
2011-07-15 16:44 ` Linus Torvalds
2011-07-15 18:42 ` Ted Ts'o
2011-07-15 19:00 ` Linus Torvalds
2011-07-16 9:16 ` Christian Couder
2011-07-18 3:41 ` Jeff King
2011-07-19 4:14 ` Christian Couder
2011-07-19 20:00 ` Jeff King
2011-07-21 6:29 ` Christian Couder
2011-07-15 18:46 ` Tony Luck
2011-07-15 18:58 ` Linus Torvalds
2011-07-15 19:48 ` Jeff King
2011-07-15 20:07 ` Jeff King
2011-07-15 21:17 ` Linus Torvalds
2011-07-15 21:54 ` Jeff King
2011-07-15 23:10 ` Linus Torvalds
2011-07-15 23:16 ` Linus Torvalds
2011-07-15 23:36 ` Linus Torvalds
2011-07-16 0:42 ` Jeff King
2011-07-16 0:40 ` Jeff King
2011-07-15 9:12 ` Jakub Narebski
2011-07-15 9:17 ` Long, Martin
2011-07-15 15:33 ` Long, Martin
2011-07-15 16:15 ` Drew Northup
2011-07-14 18:52 ` Linus Torvalds
2011-07-14 19:08 ` Jakub Narebski
2011-07-14 20:26 ` Junio C Hamano
2011-07-14 20:41 ` Jeff King
2011-07-14 21:30 ` Junio C Hamano
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4E277540.7080408@cisco.com \
--to=hordp@cisco.com \
--cc=anthonyvdgent@gmail.com \
--cc=david@lang.hm \
--cc=git@vger.kernel.org \
--cc=linux@horizon.com \
--cc=nico@fluxnic.net \
--cc=torvalds@linux-foundation.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.