It sounds to me like it should be fairly straightforward to implement online
reindex. That is, reindex without locking the table. This is an important
feature for 24x7 operation. Since postgres doesn't modify data in place the
only thing required for online reindex is to ensure that the reindex operation
sees all of the latest data.

If reindex sets a flag that causes all new inserts and updates to allocate new
space at the end of the heap without checking for free space, then a simple
linear scan should be guaranteed to catch all the data.

(I'm not sure how the indexing operation works, if it reads in the whole table
and then sorts it there would have to be an extra step where any new tuples
are read in and inserted.)

There would only have to be a small window with the table locked while the
indexes are swapped at the end.

-- 
greg


---------------------------(end of broadcast)---------------------------
TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]

Reply via email to