Added some lines to explain the different solutions to the dupe problem
authormj <mj>
Mon, 25 Mar 2002 20:07:08 +0000 (20:07 +0000)
committermj <mj>
Mon, 25 Mar 2002 20:07:08 +0000 (20:07 +0000)
(trigger and unique indices).

dbscripts/dupetrigger/INSTALL

index 2e62c38..47e781b 100755 (executable)
@@ -1,3 +1,36 @@
+The dupetrigger
+
+MOTIVATION
+
+Often, users commit their comments and articles multiple times if they
+don't believe the comment has been inserted into the databases. This is
+clearly one of the disadvantages of the otherwise clever caching strategy
+used by Mir. Without proper handling, this duplicate content will enlarge
+the database and make the appearance of the generated web pages be less
+satisfactory. 
+
+
+SOLUTIONS
+
+There are two approaches to get rid of these duplicate entries
+(hereafter called "dupes"). The first approach is the dupetrigger that 
+ensures that no entries in a given table are the same. This is the approach
+currently pursued in Mir. If this trigger cannot be compiled or doesn't work
+for any reason, you may work-around this problem by issuing the following
+commands on your psql prompt:
+
+CREATE UNIQUE INDEX idx_content_dupe ON content (title, subtitle, creator, description, content_data);
+CREATE UNIQUE INDEX idx_comment_dupe ON comment (creator, to_media, description, title);
+
+Please note that this approach will work but the implications on the Mir 
+software have not been tested, yet. Maybe Mir will respond with an error 
+or with other unexpected behaviour, but it should do no harm to the
+database. The dupetrigger has been tested with Mir and is currently being 
+operated on de.indymedia.org.
+
+
+HOW TO INSTALL THE DUPE TRIGGER
+
 To install the trigger do the following:
 
 # cp Makefile-dist Makefile