monotone-devel
[Top][All Lists]
Advanced

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

Re: [Monotone-devel] db kill_rev_local, how to handle manifests?


From: Derek Scherger
Subject: Re: [Monotone-devel] db kill_rev_local, how to handle manifests?
Date: Sun, 17 Apr 2005 09:29:06 -0600
User-agent: Mozilla Thunderbird 1.0.2 (X11/20050403)

Sebastian Spaeth wrote:
> autotests for "db kill_rev_local <revid> " are in the repository
> 
> njs,after locally killing a revision, the manifest will of course not be
> valid anymore. Right now we kill: revisions, revision_certs, and
> revision_ancestry.

the manifest is valid, but it'll be unreferenced by any revision and db
check should point this out.

> Are there more entries which we need to delete? And should we also kill
> the original manifest? Is that a very bad thing? I don't know enough
> about monotone internals to see how we should handle that properly.

I'm wondering about delta reconstruction, which fortunately, doesn't
apply to revisions. you certainly can't just delete the manifest though,
as if it is in the "manifests" table it will quite likely be referenced
as the base of some entry in manifest_deltas. similarly any changed
files in the new (and now unreferenced) manifest will also quite likely
suffer this same problem.

currently db check doesn't look for delta references to files and
manifests and doesn't go to the trouble of trying to reconstruct things
by every possible path.

it's possible, I suppose, to re-jig the delta references so that
everything makes sense but you'll need to rebuild files and manifests
from their deltas before deleting the base, then remove the deltas and
the base and re-store the files and manifests as full base entries.

> After a successful local kill this leads "db check" to say:
> monotone: manifest d4a678593f8d3011b76302b7dadbd7adeda188cc unreferenced
> monotone: warning: 1 unreferenced manifests
> monotone: check complete: 2 files; 2 manifests; 1 revisions; 1 keys; 4 certs
> monotone: total problems detected: 1 (0 serious)

exactly.

Cheers,
Derek




reply via email to

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