Merge remote branch 'davrieb/autotag' into autotag
[ikiwiki.git] / doc / todo / conflict_free_comment_merges.mdwn
1 Currently, new comments are named with an incrementing ID (comment_N). So
2 if a wiki has multiple disconnected servers, and comments are made to the
3 same page on both, merging is guaranteed to result in conflicts.
4
5 I propose avoiding such merge problems by naming a comment with a sha1sum
6 of its (full) content. Keep the incrementing ID too, so there is an
7 -ordering. And so duplicate comments are allowed..)
8 So, "comment_N_SHA1".
9
10 Note: The comment body will need to use meta title in the case where no 
11 title is specified, to retain the current behavior of the default title
12 being "comment N".
13
14 What do you think [[smcv]]? --[[Joey]] 
15
16 > I had to use md5sums, as sha1sum perl module may not be available and I
17 > didn't want to drag it in. But I think that's ok; this doesn't need to be
18 > cryptographically secure and even the chances of being able to
19 > purposefully cause a md5 collision and thus an undesired merge conflict
20 > are quite low since it modifies the input text and adds a date stamp to
21 > it.
22 >
23 > Anyway, I think it's good, [[done]] --[[Joey]]