I'm wondering if there are any recommendations, best practises or top-tips for integrating a Lucene.NET based search into an ASP.NET MVC web application?
Things I've read (or think I've read) in various places include the following:
IndexWriter
, many IndexReader
sIndexReader
sAre there any other useful tips or resources I should read before starting?
Thanks,
Kieron
Here are my tips (in no particular order):
A few gotchas from one of my previous projects were:
I would suggest looking at the source code for RavenDb as it is built on top of Lucene and uses a number of best practices.
RavenDb is definitely the easiest way to go here -- it really is lucene++.
In terms of how to use it, I'd recommend looking at the SubText blogging engine. Code is MIT licensed so you can just use it in your project and it has a very well designed index writer/reader.
In our apps, we tend to have one writer and a separate app with many readers. The locking strategy can be key here--especially make sure the readers don't try and lock the index. I'm blanking on the specific term we had to use to make this happen.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.