From: Daniel Carosone <dan@geek.com.au>
To: Markus Schiltknecht <markus@bluegap.ch>,
monotone-devel@nongnu.org, dev@cvs2svn.tigris.org,
Git Mailing List <git@vger.kernel.org>
Subject: Re: cvs import
Date: Thu, 14 Sep 2006 09:21:39 +1000 [thread overview]
Message-ID: <20060913232139.GU29625@bcd.geek.com.au> (raw)
In-Reply-To: <20060913225200.GA10186@frances.vorpus.org>
[-- Attachment #1.1: Type: text/plain, Size: 3325 bytes --]
On Wed, Sep 13, 2006 at 03:52:00PM -0700, Nathaniel Smith wrote:
> This isn't trivial problem. I think the main thing you want to avoid
> is:
> 1 2 3 4
> | | | |
> --o--o--o--o----- <-- current frontier
> | | | |
> A B A C
> |
> A
> There are a lot of approaches one could take here, on up to pulling
> out a full-on optimal constraint satisfaction system (if we can route
> chips, we should be able to pick a good ordering for accepting CVS
> edits, after all). A really simple heuristic, though, would be to
> just pick the file whose next commit has the earliest timestamp, then
> group in all the other "next commits" with the same commit message,
> and (maybe) a similar timestamp.
Pick the earliest first, or more generally: take all the file commits
immediately below the frontier. Find revs further below the frontier
(up to some small depth or time limit) on other files that might match
them, based on changelog etc (the same grouping you describe, and we
do now). Eliminate any of those that are not entirely on the frontier
(ie, have some other revision in the way, as with file 2). Commit the
remaining set in time order. [*]
If you wind up with an empty set, then you need to split revs, but at
this point you have only conflicting revs on the frontier i.e. you've
already committed all the other revs you can that might have avoided
this need, whereas we currently might be doing this too often).
For time order, you could look at each rev as having a time window,
from the first to last commit matching. If the revs windows are
non-overlapping, commit them in order. If the rev windows overlap, at
this point we already know the file changes don't overlap - we *could*
commit these as parallel heads and merge them, to better model the
original developer's overlapping commits.
> Handling file additions could potentially be slightly tricky in this
> model. I guess it is not so bad, if you model added files as being
> present all along (so you never have to add add whole new entries to
> the frontier), with each file starting out in a pre-birth state, and
> then addition of the file is the first edit performed on top of that,
> and you treat these edits like any other edits when considering how to
> advance the frontier.
CVS allows resurrections too..
> I have no particular idea on how to handle tags and branches here;
> I've never actually wrapped my head around CVS's model for those :-).
> I'm not seeing any obvious problem with handling them, though.
Tags could be modelled as another 'event' in the file graph, like a
commit. If your frontier advances through both revisions and a 'tag
this revision' event, the same sequencing as above would work. If tags
had been moved, this would wind up with a sequence whereby commits
interceded with tagging, and we'd need to split the commits such that
we could end up with a revision matching the tagged content.
> In this approach, incremental conversion is cheap, easy, and robust --
> simply remember what frontier corresponded to the final revision
> imported, and restart the process directly at that frontier.
Hm. Except for the tagging idea above, because tags can be applied
behind a live cvs frontier.
--
Dan.
[-- Attachment #1.2: Type: application/pgp-signature, Size: 186 bytes --]
[-- Attachment #2: Type: text/plain, Size: 158 bytes --]
_______________________________________________
Monotone-devel mailing list
Monotone-devel@nongnu.org
http://lists.nongnu.org/mailman/listinfo/monotone-devel
next prev parent reply other threads:[~2006-09-13 23:21 UTC|newest]
Thread overview: 39+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <45084400.1090906@bluegap.ch>
2006-09-13 19:01 ` cvs import Jon Smirl
2006-09-13 20:41 ` Martin Langhoff
2006-09-13 21:04 ` Markus Schiltknecht
2006-09-13 21:15 ` Oswald Buddenhagen
2006-09-13 21:16 ` Martin Langhoff
2006-09-14 4:17 ` Michael Haggerty
2006-09-14 4:34 ` Jon Smirl
2006-09-14 5:02 ` Michael Haggerty
2006-09-14 5:21 ` Martin Langhoff
2006-09-14 5:35 ` Michael Haggerty
2006-09-14 5:30 ` Jon Smirl
2006-09-14 4:40 ` Martin Langhoff
2006-09-13 21:05 ` Markus Schiltknecht
2006-09-13 21:38 ` Jon Smirl
2006-09-14 5:36 ` Michael Haggerty
2006-09-14 15:50 ` Shawn Pearce
2006-09-14 16:04 ` Jakub Narebski
2006-09-14 16:18 ` Shawn Pearce
2006-09-14 16:27 ` Jon Smirl
2006-09-14 17:01 ` Michael Haggerty
2006-09-14 17:08 ` Jakub Narebski
2006-09-14 17:17 ` Jon Smirl
2006-09-15 7:37 ` Markus Schiltknecht
2006-09-16 3:39 ` Shawn Pearce
2006-09-16 6:04 ` Oswald Buddenhagen
2006-09-16 6:21 ` Nathaniel Smith
2006-09-13 22:52 ` Nathaniel Smith
2006-09-13 23:21 ` Daniel Carosone [this message]
2006-09-13 23:52 ` [Monotone-devel] " Daniel Carosone
2006-09-13 23:42 ` Keith Packard
2006-09-14 0:32 ` Nathaniel Smith
2006-09-14 0:57 ` [Monotone-devel] " Jon Smirl
2006-09-14 1:53 ` Daniel Carosone
2006-09-14 2:30 ` [Monotone-devel] " Shawn Pearce
2006-09-14 3:19 ` Daniel Carosone
2006-09-14 21:57 ` [Monotone-devel] " Petr Baudis
2006-09-14 22:04 ` Shawn Pearce
2006-09-14 2:35 ` Shawn Pearce
2009-02-16 9:17 CVS import Ferry Huberts (Pelagic)
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=20060913232139.GU29625@bcd.geek.com.au \
--to=dan@geek.com.au \
--cc=dev@cvs2svn.tigris.org \
--cc=git@vger.kernel.org \
--cc=markus@bluegap.ch \
--cc=monotone-devel@nongnu.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).