Zend Framework: Zend_Search_Xapian Component Proposal
| Proposed Component Name | Zend_Search_Xapian |
|---|---|
| Developer Notes | http://framework.zend.com/wiki/display/ZFDEV/Zend_Search_Xapian |
| Proposers | Steven Brown |
| Zend Liaison | TBD |
| Revision | 1.0 - 14 August 2009: Initial Draft. (wiki revision: 34) |
Table of Contents
1. Overview
Zend_Search_Xapian provides an interface to the Xapian search engine library. Xapian is written in C++ and is available as a PHP module, as such it provides far better performance than Zend_Search_Lucene. Xapian does come with a class library for PHP5, Zend_Search_Xapian is designed to be a ZF-friendly alternative.
2. References
3. Component Requirements, Constraints, and Acceptance Criteria
Most requirements take the form of "foo will do ...." or "foo will not support ...", although different words and sentence structure might be used. Adding functionality to your proposal is requirements creep (bad), unless listed below. Discuss major changes with your team first, and then open a "feature improvement" issue against this component.
- This component will replicate the functionality of the standard Xapian PHP library.
- This component will not provide a stand-aline Xapian search engine (it will require the Xapian PHP module).
4. Dependencies on Other Framework Components
- Zend_Exception
5. Theory of Operation
The functionality replicates the standard Xapian PHP library.
6. Milestones / Tasks
- Milestone 1: design notes will be published here
- Milestone 2: Working prototype checked into the incubator supporting use cases
- Milestone 3: Unit tests exist, work, and are checked into SVN.
- Milestone 4: Initial documentation exists.
7. Class Index
- Zend_Search_Xapian
- Zend_Search_Xapian_Database
- Zend_Search_Xapian_Database_Writable
- Zend_Search_Xapian_Document
- Zend_Search_Xapian_Enquire
- Zend_Search_Xapian_ESet OR Zend_Search_Xapian_ExpandedSet
- Zend_Search_Xapian_ESetIterator OR Zend_Search_Xapian_ExpandedSetIterator
- Zend_Search_Xapian_MatchDecider
- Zend_Search_Xapian_MSet OR Zend_Search_Xapian_MatchSet
- Zend_Search_Xapian_MSetIterator OR Zend_Search_Xapian_MatchSetIterator
- Zend_Search_Xapian_MultiValueSorter
- Zend_Search_Xapian_PositionIterator
- Zend_Search_Xapian_PostingIterator
- Zend_Search_Xapian_Query
- Zend_Search_Xapian_QueryParser
- Zend_Search_Xapian_RSet OR Zend_Search_Xapian_RelevanceSet
- Zend_Search_Xapian_Stem
- Zend_Search_Xapian_Stopper
- Zend_Search_Xapian_Stopper_Simple
- Zend_Search_Xapian_TermGenerator
- Zend_Search_Xapian_TermIterator
- Zend_Search_Xapian_ValueIterator
- Zend_Search_Xapian_ValueRangeProcessor
- Zend_Search_Xapian_ValueRangeProcessor_Date
- Zend_Search_Xapian_ValueRangeProcessor_Number
- Zend_Search_Xapian_ValueRangeProcessor_String
- Zend_Search_Xapian_Weight
- Zend_Search_Xapian_Weight_BM25 - not sure if this name would be ok?
- Zend_Search_Xapian_Weight_Bool OR Zend_Search_Xapian_Weight_Boolean
- Zend_Search_Xapian_Weight_Trad OR Zend_Search_Xapian_Weight_Traditional
8. Use Cases
9. Class Skeletons
At the moment all classes mimic the structure of the standard Xapian class library. Some more investigation is needed into each of the properties and methods to see what changes can be made. My suspicion is that all iterators could be implement SeekableIterator, Countable and ArrayAccess. The method names could be made friendlier also.
2 Comments
comments.show.hideNov 29, 2009
Juan Felipe Alvarez Saldarriaga
Any news about this proposal?
Dec 22, 2009
Steven Brown
I have this working in a live application and the performance is much better than Zend_Search_Lucene obviously because it uses the Xapian PHP module rather than just PHP code. I am not sure what license issues there may be with using the Xapian PHP bindings as a basis for the structure and functionality.