Sphinx full text search integration module

66 views
Skip to first unread message

Hamish Friedlander

unread,
Aug 2, 2009, 11:49:37 PM8/2/09
to silverst...@googlegroups.com
Hi Everyone,

I'm happy to announce the first beta release of the Sphinx search
integration module. This module adds Sphinx (http://sphinxsearch.com/)
powered full-text searching of any DataObject fairly seamlessly.

Advantages over full-text search

- Faster
- More accurate, more relevant results
- Understands language - gives results containing "jumped" when
searching for "jumping"
- Intelligent snippet extraction with search term highlighting
- Able to search any DataObject, including a specific subclass, not
just SiteTree and Files
- Able to filter results during search on other fields and relations

Disadvantages over regular full-text search

- Requires external binaries to be installed (not suitable for
shared hosting)
- Extra daemon means extra memory and harddisk space requirements
- Sphinx is distributed under the GPL, not a BSD derivative like
SilverStripe

Usage
---------

The biggest issue is getting Sphinx installed on your machine. It's an
external binary (written in C), and we require at least 0.9.9-rc2,
with 64 bit document IDs enabled. Sphinx works fine on Linux, OS X and
Windows, but this module currently won't work on Windows (it uses unix
sockets to talk to the Sphinx searchd binary) - that's something we
plan to fix in a future release.

Once you've got Sphinx installed and on your path, to integrate this
module with a SilverStripe site you need to:

1. Add the module (http://svn.silverstripe.com/open/modules/sphinx/trunk
)
2. Add the SphinxSearchable decorator to any DataObjects you want to
search (for example, SiteTree and File)
3. Call dev/build, which will generate a configuration file for
Sphinx and rebuild Sphinx's indexes
4a. Use SphinxSearchForm instead of SearchForm
4b. For more complex searching use SphinxSearch::search directly

Licensing
-------------

Sphinx is distributed under the GPL. The file sphinxapi.php is the
official php client for Sphinx, and so is also distributed under the
GPL. We have email confirmation from the Sphinx developers that we can
include sphinxapi.php in SilverStripe under a license similar to Sun’s
MySQL FOSS exception - that is, the file itself remains under GPL, but
distribution within SilverStripe is OK without SilverStripe needing to
be distributed under the GPL.

Thanks to Andrew Aksyonoff and everyone involved in Sphinx

Hamish Friedlander
SilverStripe

Reply all
Reply to author
Forward
0 new messages