Design decision: conflict resolution Gareth Rees, Ravenbrook Limited 1. Introduction This is a record of a design decision made at a meeting between RB and GDR on 2000-10-05. 2. Resolving conflicts The administrator of the integration needs to be able to resolve conflicts. The replicator needs to record information about whether jobs and issues are conflicting. A solution to this is to have a status field in the job and the issue. The status field takes four values: ok/conflicting/keep/discard. When everything is going correctly, the status field contains "ok". When a conflict is discovered (by the replicator) between the job and the issue, the replicator sets both status fields to "conflicting". The administrator can resolve the conflict by selecting the issue or the job or both and setting the status field to "keep" or "discard". These have the following effect when the replicator next examines these entities: Issue status Job status Action taken by replicator ------------------------------------------------------------------------------- ok ok Situation normal; replicate changes. conflicting conflicting Do nothing (wait for intervention). keep conflicting Overwrite job with issue; set statuses to "ok". keep discard ditto conflicting discard ditto conflicting keep Overwrite issue with job; set statuses to "ok". discard keep ditto discard conflicting ditto Any other combination of statuses is an error. Note: if the organization implements an automatic policy such as "defect tracker wins", the statuses remain "ok" and "ok". No manual intervention is required. We noted that "ok" and "conflicting" are statuses, but "keep" and "discard" are actions. This is inconsistent. Suppose they were all actions. Then "ok" would be "replicate" and "conflicting" would be "wait". Suppose they were all statuses. Then "keep" would be "right" or "live" and "discard" would be "wrong" or "dead" or something like that. The actions are clearer. So we'll adopt them. The table will look like this: Issue action Job action Action taken by replicator ------------------------------------------------------------------------------------- replicate replicate Situation normal; replicate changes. wait wait Do nothing (wait for intervention). keep wait Overwrite job with issue; set actions to "replicate". keep discard ditto wait discard ditto wait keep Overwrite issue with job; set actions to "replicate". discard keep ditto discard wait ditto A. References B. Document history 2000-10-05 GDR Created based on e-mail written during meeting.