MYSQL / SOLR Best configuration for a full text search?

August 5, 2016 184 views
Apache Java Ubuntu

I recently installed SOLR on my droplet.

I wonder if there is a guide or best practice you can share on setting up SOLR so it can search and provide disambiguation and results for any words the user inputs...

Say I search for "micronano" I would expect to find items like "micro" "nano" "nanonano"
and maybe if i search "micro" i would get "did you mean 'macro'?" etc...

is it possible at all in solr?

1 Answer

Hi @francescobertel,

SOLR certainly can do this, however, if you don't have a ton of experience with Lucene, SOLR, or it's derivatives, I'd suggest trying out ElasticSearch (

It has a simple REST interface, and scales wonderfully (and in my opinion, is a little easier to get going than SOLR).

For the searches you're talking about, there're a few options to get the behavior you're talking about, but it'd be down to how you want the search to behave, more than anything else.

For matching like you describe in the first part of your question, you'd use something like a fuzzy match, or allow the user to input a wildcard, and simply pass that to the search. The fuzzy match is probably a little easier to weight towards 'perfect' results (you could use boosting within the search service).

For the 'did you mean' functionality, you could probably just rely on the suggestion packages/services that exist within the SOLR/ES/Lucene services.

Let us know if you have any further questions!

Have another answer? Share your knowledge.