Issues

ZF-1565: Best practice section for Zend_Search_Lucene module

Description

Some 'best practice' recommendations may already be added to Zend_Search_Lucene module documentation.

  1. Don't use 'id' for stored field names.

  2. Some recommendations for MaxBufferedDocs, MaxMergeDocs and MergeFactor settings for different usage modes (indexing, searching, batch indexing, indexing small/large documents).

  3. Shut down index before the end of script (unset index object), so auto-commit will be done before exception mechanism is shut down.

Comments

  1. Do not use index on NFS (see flock() documentation).
  1. If documents have any unique-id field, then documents should be retrieved through $index->termDocs() method instead of $index->find()

  2. If index is not optimized than each segment has his own term dictionary and preloaded term dictionary index. It also increases search time (each search is actually several mini-searches through segments)

  1. Encoding parameters usage.
  1. Index maintenance (backup and restoring).

Done.