monotone-devel
[Top][All Lists]
Advanced

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

[Monotone-devel] "prune-branch" cert implementation issues.


From: Michael Stone
Subject: [Monotone-devel] "prune-branch" cert implementation issues.
Date: Sun, 05 Jun 2005 17:53:07 -0400
User-agent: Mozilla Thunderbird 1.0.2 (X11/20050528)

I'm attempting to give people a clean way to mark a revision as
"no-longer-a-head-for-branch-X".  There are two use cases for a feature
like this one:

1) To ignore old branches which have subsequently been merged into the
mainline.
2) To mark revisions as unsuitable for merging.

However, it is unclear whether these use cases should be combined or
should be handled separately.  In discussions on IRC, we decided to try
to implement at least the first case with a new certificate type,
tentatively named a "prune-branch" certificate by dscherger.  The
functionality is currently implemented by modifying the
get_branch_heads() function in cert.cc. 

Algorithmically speaking the changes is from the present:
Find all revisions with branch certs with value X.
Remove revisions which are ancestors.

to the new:
Find all revisions with branch certs with value X.
Remove revisions which are ancestors.
Find all prune-branch certs with value X.
For each revision, discard if it has an attached prune-branch cert.

Applying prune-branch certs is easy: you just run
monotone cert REVID prune-branch BRANCH.

Two questions remain:
How should the selection of update targets behave in the presence of
prune-branch certs?
How should this certificate affect commands which rely on the old
behavior of get_branch_heads()?

Comments, criticisms, and suggestions would be very welcome.

Thanks,
Michael





reply via email to

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