Shawn,

Thank you so much for your help.  I appreciate you taking the time to confirm 
what I had a hunch about with Solr.  Sometimes I don't see the forest from the 
trees.  I was hoping Solr would help me out, but like you said, since I have an 
understanding of what Lucene is doing and the fact that I have Lucene 
integrated with Hibernate, Solr really doesn't add any value in this case.  

Thanks again,

Todd

-----Original Message-----
From: Shawn Heisey [mailto:s...@elyograg.org] 
Sent: Monday, May 20, 2013 2:36 PM
To: solr-user@lucene.apache.org
Subject: Re: Existing Project using Hibernate, Spring and Lucene and Looking to 
Add Solr

On 5/20/2013 1:02 PM, Todd Hunt wrote:
<snip>
> It seems like Solr forces one to expose access to its "Cores" (indexes) via 
> its own WAR file.  I don't want that.  I just want to be able to utilize the 
> Solr Java API to integrate with our current web services and Hibernate 
> framework to index text based documents.  Then allow our users to perform 
> open text searching and utilize Solr's advance features like highlighting, 
> MLT, spell checking, suggester and faceting.  But I just don't see how to 
> integrate what Solr has to offer with our existing web application.  I get 
> the feeling that I have to create a new Solr based web application and then 
> have the current application delegate indexing and searching to the Solr 
> application, which is not what I really want to do, if possible.

I've removed most of your email and just quoted the one paragraph above. 
  You have pretty much described the right way to use Solr.  Solr is awesome 
for new projects, because the amount of user code required to interface with 
Solr is usually very small.  Most of the heavy lifting is done server-side, in 
the configuration.

People like yourself that are highly experienced with custom Lucene 
applications often find Solr too restrictive.  Solr does provide extra 
functionality on top of Lucene, but it does NOT expose all of Lucene's 
capability, especially in the newest versions.

Migrating from Lucene to Solr isn't for everyone.  If you have a deep 
understanding of Lucene and your existing application is intricately tied to 
it, you should probably stick with Lucene and just upgrade to the newest stable 
release, because chances are that the way Solr uses Lucene is not completely 
compatible with your existing methods.  From what I've been told, the upgrade 
from Lucene 3.x to 4.x does require a lot of refactoring work on user code.

If you do decide to implement Solr, the recommendation is to use the .war and 
make connections from client code with HttpSolrServer or CloudSolrServer.  
Although you CAN use EmbeddedSolrServer to embed the entire Solr application in 
your program and avoid HTTP, this is not recommended, and it doesn't do 
anything to change the fact that your Lucene code may be fundamentally 
different than Solr.  To completely duplicate your Lucene application you might 
have to write custom Solr components ... and if you start doing that, you might 
as well simply maintain your existing code through version upgrades.  Lucene is 
not going away, and a given version of Lucene will likely always have 
functionality beyond the same version of Solr.

Thanks,
Shawn

Reply via email to