Is there a way to automatically set a field when a document is indexed? Specifically, I'd like to have a date field updated to the current time when a document is indexed.
I am trying to find the best way to re-index content on a live server. I can't wipe the index and start over as there will be active queries through the whole process. I have a bunch of stuff stored in SQL, my plan is to: * note the current time * Cycle through everything, <add>100 documents at a time</add> * when it is done, delete everything that was not updated since we started this process. Something like: <delete><query>index_time:[0 TO 2006-12-13T05:40:08,703]</query></delete> * <commit/> * <optimize/> My options are: 1) Send the index time along with the document. 2) extend UpdateHandler (DirectUpdateHandler2) to do this automatically 1) is the easiest but requires that everyone sending data sends a valid "index_time" field. 2) more complicated, but then we know everything has a valid "index_time" field. Thanks for any pointers! ryan