[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: FS copy model

From: Karl Fogel <kfogel_at_galois.collab.net>
Date: 2001-01-03 14:32:44 CET

Greg Stein <gstein@lyra.org> writes:
> Question: should /B/foo and /B/bar know that they came from /A/foo? To put
> it another way, when somebody pulls up a change log for /B/foo:

The first answer is, "Yes, they do".

But the real answer is: individual nodes know nothing, the repository
knows everything. When you generate a changelog, all the information
you need to establish copy/rename/delete history is *available*, the
only question is whether the log generation process used all of that
information.

So this question:

> 1) they will see the changes from 73.1 thru 73.4
> 2) will they *also* see that /B/foo was copied from /A/foo?

Well, the file's themselves don't "know" anything, but, yes, if your
changelog generation process uses data from other sources (such as the
parent directories), then it will reflect this history.

> I think another way to phrase the question is:
>
> Do we record a copy from one location to another in the FS? If so, then
> how is it recorded? Is there a machine-readable marker? (the checkin
> comment is not machine-readable)

Yes. We record it by virtue of the fact that a node is linked to from
place X in one revision, and from both X and Y in some higher
revision. In that case, it must have been copied to Y.

One might respond, "But it could be an expensive exhaustive search to
find that out". To which I would answer

   1. It's the usual `update' problem -- find the places where one
      tree in the repository differs from another, and how exactly.

   2. If it is expensive, it can be cached using non-historical
      properties.

Does that help?

-K
Received on Sat Oct 21 14:36:19 2006

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.