2
votes

We want to implement full document search in our project in .Net web project.

For that we came across 2 names and below is what I deduced/inferred.

Lucene.Net is good at indexing and searching text, while SOLR.Net is at parsing multitude of documents.

I am not sure if Lucene.Net, SOLR.Net requires JRE to be present on the server as I do not know if they still use Lucene and/or SOLR internally (Java Versions).

So here are my 2 questions:

  • Do I require JRE installed on my servers?
  • How can I go with implementing search using SOLR.Net? i.e if it is dll based (API) or I need to do something else.
1
Is Question 2 missing?Lt_Shade
it was there but it got merged in same line.Durgesh Chaudhary
Grand just wondered encase you didn't get the full answer you were looking for.Lt_Shade
got kind of. asked some more info in the answered section belowDurgesh Chaudhary

1 Answers

10
votes

Solr sits on top of Lucene and it is written in Java, so it requires JRE. Solr.Net is only .net client for Solr, so you would need host Solr somehow for it.

Lucene on the other hand originally was written in Java, but was ported to .NET, so you can simply reference dll of ported Lucene lib and you will be fine.

There is also ElasticSearch, that also sits on top of Lucene and it is also written in Java, so it requires JRE also, but it is better than Solr in several aspects, mainly in easier scaling, also has in my opinion better .net client.

Depending on that you need, you may also take a look at RavenDB and it also sits on top of Lucene and has full text search/faceting capabilities, may run on its own server or as embedded database (it is written in .net).

To answer your questions:

1) For Lucene only, you don't need JRE, we're running website using Lucene.NET on Windows Azure Websites, which means we haven't installed anthing additional on those server instances.

2) To use Solr for full text search, you need to:

1) Install Solr (you'll need Servlet Container to host Solr, I've tried only with Tomcat, Solr examples use Jetty) http://wiki.apache.org/solr/SolrInstall. Alternatively you can outsource Solr hosting, for example from here: http://www.websolr.com/plans

2) Use some API (Solr.net) to add documents to index

3) Use some API (Solr.net) to perform search on index