monotone-devel
[Top][All Lists]
Advanced

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

[Monotone-devel] workspace migration improvements - no more database


From: Zack Weinberg
Subject: [Monotone-devel] workspace migration improvements - no more database
Date: Tue, 5 Sep 2006 14:11:44 -0700

I just pushed a revision of the workspace migration code which makes
it no longer need the database.  You should now be able to do "mtn
migrate_workspace" in an old-format workspace without specifying -d,
and your options file should come through intact.  I've beefed up the
testing of this to make sure it doesn't break again.

As a consequence of this change, the "new_manifest" field of the
revision in _MTN/revision is now *always* fake.  [Without the
database, it's impossible to compute a "correct" one; if I'd made
migration put a fake id there but not everything else, we would risk
things coming to rely on a real id there and thus breaking rarely -
only after a migration event - a very hard bug to track down.]  For
great defensiveness, I added a "made_for" tristate variable to struct
revision_t.  If you manufacture a revision by hand, you have to set
this to either made_for_workspace or made_for_database, and the
revision will be unacceptable to whichever consumer (the workspace or
the database) it is not made for.  [New code should be using
make_revision / make_revision_for_workspace; I'm aware that you can't
do everything with those, but the intent is to change that over on
.noconflict.  I might also turn them into real constructors.]

zw




reply via email to

[Prev in Thread] Current Thread [Next in Thread]