single thread comments
Currently there are a set of comments "attached" to each entry. When an entry is edited, it is duplicated and the changes are made to the copy. The copy includes the history records (aka comments) that were on the parent entry and a comment for the current edit is appended. These contain ad-hoc text entered by the submitter describing the edit, and an automatically generated diff between the xml of the edited entry and its parent that serves to summarize the changes made. This scheme has a number of problems: * When there are several edits to an entry and they are viewed together, earlier comments are duplicated on many of the edits resulting in a lot of visual confusion (see IS-189) * When there are two independent edits of the same parent, no indication of the other edit can be seen when looking at either. This requires a mechanism to check for other edit branches and explicitly "reject" them in order to assure they are considered before approving an edit. * When an edited entry is approved, all the edits leading to it including the original approved entry are deleted (to reduce the accumulation of old cruft in the database.) This was deemed ok because the approved entry carries all the comments and diff records of its predecessors. But in some corner cases involving concurrent edits, the old entry deletion can take current xrefs with it. * If the diff info is not correctly generated, there is no way to recover it because the entry diffed against is gone. * The comments in practice tend to be used as a discussion forum but is impossible to add a comment without also creating an edit. I want to introduce the concept of an "entry set": a number of entries having a common sequence number and shared ancestry. * Entry sets will be identified by the pair (corpus, seq#). * Comments will be linked to the entry set, ordered by creation timestamp and *optionally* allow a link to an edited entry. * Editing an entry will duplicate it and apply the changes to the copy as before. * Edited entries will not be deleted on approval of a descendent and diffs will be generable on demand between any of the entries in the set. * As now, there will never be more than one approved entry in a set and only the approved entry will be exported to xml, etc. In other words, instead of a set of comments attached to each entry, there will be a set of comments for each sequence number with edited entries attached to the comments. The database changes needed to support this are not difficult. Library API will need quite a bit of work because the current architecture is pretty deeply embedded. I've no idea yet what the webpage UI should look like. References: email 2014-09-09 to jwb "Re: Amendment Submissions" email 2014-09-10 from jwb: "Revised Database Structure"
[Imported from JMdictDB Issues Tracker: IS-241/msg620]
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information