Installing Solr-RA

Installing and Using Solr with RankingAlgorithm

Install Solr as before, no changes to the existing installation steps (see Solr docs for installation). No changes to the way you query or use Solr. The change is when you initiate a query, the search uses RankingAlgorithm instead of Lucene. You can still use Lucene by adding "&lucene=true" to use Lucene as before. You can download Solr with RA from here and follow the steps as in the download docs either on the website or from [1].

See examples below:

Searching in document mode (default): http://localhost:8773/solr/select/?q=california+gold+rush&fl=score

Searching in product mode: http://localhost:8773/solr/select/?q=wii+console&fl=score&mode=product

Searching using Lucene library: http://localhost:8773/solr/select/?q=california+gold+rush&fl=score&lucene=true

Installing Solr with RankingAlgorithm v1.1 beta


You can install Solr with RA in two different ways. You can download Solr1.4.1 with RA.zip a bundle of Apache Solr 1.4.1 and Ranking Algorithm (a big download) or just download the solr-ra.war.zip which is a web archive file and copy it into an existing or new Solr 1.4.1 installation. Below the are steps for both:

Download Solr1.4.1 with RA.zip (bundle) Installation is the same as Solr. Download Solr1.4.1 with RA.zip (Solr version 1.4.1 with the RankingAlgorithm) from tgels.com. Unzip or untar the file, change to examples directory and start Solr as before, java -Xmx 2gb -jar start.jar.

Step1: Download Solr1.4.1 with RA.zip from http://solr-ra.tgels.com

Step2: Unzip it to a directory

Step3: cd unzip directory/apache-solr-1.4.1/examples

Step4: bash -x start_solr.sh or

java -Xmx 2gb -jar start.jar. 

Step 5: Configuring options in solrconfig.xml:

<realtime>true</realtime> <!-- true to enable near real time or false -->
<library>rankingalgorithm</library> <!-- rankingalgorithm or lucene search library -->
<!--	<library>lucene</library>  -->
<rankingalgorithm>
   <mode>document</mode> <!-- document or product mode -->
    <!--<mode>product</mode> -->
    <scan>fast</scan>
</rankingalgorithm>

Download Solr1.4.1 with RA.war (war file) Instead of downloading the Solr 1.4.1 with RA ( a huge file ), you can download just the solr_ra.war file. You will still need to download the Solr 1.4.1 from the Solr website as below. Unzip that first, and then change to the examples directory and follow the steps as below.

Step1: Download Solr 1.4.1 from the Apache Solr website, as in here: http://www.apache.org/dyn/closer.cgi/lucene/solr/

Step2: Install Solr 1.4.1 by unzip it to a directory.

Step3: Download the solr_ra war file from solr-ra.tgels.com, as in here: http://solr-ra.tgels.com (click on download war file link at the bottom of the page)

Step4: cp solr_ra.war.zip file to the examples directory under unzip directory/apache-solr-1.4.1/examples.

Step5: unzip solr_ra.war.zip

Step 6: cp solr.war webapps

Step 7: bash -x start_solr.sh or

java -Xmx 2gb -jar start.jar. 

Step 8: Configuring options in solrconfig.xml:

<realtime>true</realtime> <!-- true to enable near real time or false -->
<library>rankingalgorithm</library> <!-- rankingalgorithm or lucene search library -->
<!--	<library>lucene</library>  -->
<rankingalgorithm>
   <mode>document</mode> <!-- document or product mode -->
    <!--<mode>product</mode> -->
    <scan>fast</scan>
</rankingalgorithm>

Installing on Glassfish/Tomcat/JBoss/WebLogic

If you want to deploy Solr on a different container than the default Jetty container, then deploy as before ( ie. Deploy examples/webapps/solr.war on Tomcat or Glassfish or Weblogic or Jboss).