P4DTI issue job000069

TitleNo resolver documentation
Assigned userRichard Brooksby
DescriptionEarlier releases of the P4DTI included a role of "resolver", to resolve conflicts between changes in the DT and changes in Perforce. The P4DTI now has a "defect tracker wins" policy, making the resolver redundant.
If we reintroduce the role of resolver, we must write documentation for it. For example, there are two ways of resolving conflicts: either set to "discard" or fix up the problem and set to "keep". Need to document both of these.
AnalysisAdd resolver documentation to the AG.
This whole issue is finessed by <http://info.ravenbrook.com/mail/2000/11/28/17-30-34/0.txt>. RB 2000-11-30
How foundmanual_test
Evidence<http://www.ravenbrook.com/project/p4dti/doc/2000-10-24/teamshare-psg-alpha-test/> item 9
Created byRichard Brooksby
Created on2000-11-22 15:07:50
Last modified byGareth Rees
Last modified on2001-12-10 19:03:10
History2000-11-22 RB Created from sources (see evidence).
2000-11-30 RB Suspended (see analysis).
2001-02-27 NB Clarified description and downgraded to "nice".


Change Effect Date User Description
5388 closed 2000-12-04 18:41:38 Gareth Rees Removing resolver role from the integration:

Tidied up the replication and mailing methods to make this part of the replicator clearer. Changed replicate_issue_to_job() to replicate_issue_dt_to_p4() and replicate_job_to_issue() to replicate_issue_p4_to_dt() for consistency with other method names. Added new methods overwrite_issue_dt_to_p4() and overwrite_issue_p4_to_dt(), which are wrappers around the above methods that also e-mail the affected parties. In order to be able to e-mail the owner of a job, added the replicator method user_email_address for getting a Perforce user's e-mail address and the replicator configuration parameter job-owner-field that names the owner field in a job (the automatic configuration generator specifies 'Owner' for this). Removed the mail_administrator method() (use mail instead), and improved the mail() method. Improved many log entries by using issue.readable_name instead of issue.id. Re-organized and documented the replicate() function. It's no less complicated than it was before, but I think it's easier to understand. Functions like replicate() and replicate_issue_p4_to_dt() no longer return a meaningful error code. They either return or throw an exception.

Changed conflict_policy so that it always returns 'dt'. This is the key change that removes the resolver's role.

Changed the handling of errors to support the change in the conflict policy. There's now no need for conflict_error, so this is gone. The reverting of jobs to the corresponding issue is handled by the revert_issue_dt_to_p4() method: this ensures that it gets called in the correct place only (that is, normal replication from Perforce to the defect tracker has failed). The replicate_many() method no longer does any handling of errors. All other errors are caught by the run() method so that the replicator can keep on going, except AssertionError and KeyboardInterrupt, both of which stop the replicator.
5064 suspended 2000-11-28 17:47:35 Richard Brooksby Wrote section 11 of the AG, explaining that there is no section 11 because we're not having a "resolver" role after all. See <http://info.ravenbrook.com/mail/2000/11/28/17-30-34/0.txt>.