Just a quick pre-emptive question before we start to seriously investigate using Lucene.
Currently building a C# WPF application, using MVVM and Microsoft Entity framework. My lead has brought up the point that this might represent a problem with us not being able to let Lucene directly access the database, and therefore there might be difficulty in getting it to tie in with our BOL/DAL.
开发者_JAVA技巧Anyone have any experience of tying Lucene in with such a model?
I have successfully used Lucene in a WPF application using MVVM, and I didn't encounter any problems.
Lucene should sit in your services layer. In the MVVM world, Lucene is your Model. The ViewModel just calls into Lucene with queuries and formats the results in whatever way is needed for the View to present it.
In my application, I had a service that was responsible for pulling relevant data out of the database and adding it to the Lucene index.
精彩评论