Logo Search packages:      
Sourcecode: zeitgeist-extensions version File versions  Download package

def fts::Indexer::_reindex (   self,
  event_list 
) [private]
Index everything in the ZG log. The argument must be a list
of events. Typically extracted by a Reindex instance.
Only call from worker thread as it writes to the db and Xapian
is *not* thread safe (only single-writer-multiple-reader).

Definition at line 461 of file fts.py.

                                     :
            """
            Index everything in the ZG log. The argument must be a list
            of events. Typically extracted by a Reindex instance.
            Only call from worker thread as it writes to the db and Xapian
            is *not* thread safe (only single-writer-multiple-reader).
            """
            self._index.close ()
            self._index = xapian.WritableDatabase(INDEX_FILE, xapian.DB_CREATE_OR_OVERWRITE)
            self._query_parser.set_database (self._index)
            self._enquire = xapian.Enquire(self._index)
      
            self._index.set_metadata("fts_index_version", INDEX_VERSION)
            
            log.info("Preparing to rebuild index with %s events" % len(event_list))
            for e in event_list : self._queue.put(e)


Generated by  Doxygen 1.6.0   Back to index