Full text search with MongoDB and Lucene analyzers
Johan Rask:
It is important to understand that for a full fledged full text search engine, Lucene or Solr is still your choice since it has many other powerful features. This example only includes simple text searching and not i.e phrase searching or other types of text searches, nor does it include ranking of hits. But, for many occasions this is all you need but then you must be aware of that especially write performance will be worse or much worse depending on the size of the data your are indexing. I have not yet done any search performance tests for this so I am currently totally unaware of this but I will publish this as soon as I can.
Just a couple of thoughts:
- Besides Lucene and Solr, ☞ ElasticSearch is another option you should keep in mind
- your application will have to deal maintaining the index (adding, updating, removing). MongoDB currently lacks a notification mechanism that would help you decouple this. Something a la CouchDB
_changesfeed or Riak post-commit hooks (nb: leaving aside that starting with version 0.133 Riak search is available)
Original title and link: Full text search with Mongodb and Lucene analyzers (NoSQL databases © myNoSQL)
via: http://blog.jayway.com/2010/11/14/full-text-search-with-mongodb-and-lucene-analyzers/