0

Thank you in advance for bearing with me. I am new to Solr and looking to integrate into Rails. Although Postgres can text search, Solr seems to be faster..

I understand the modifications that need to happen to the models and controllers within the Rails app itself, however, I cannot seem to grasp when the xml files themselves will be defined and/or stored. Is there a configuration which points to a data source/xml file within Rails that I am missing? I understand that Solr runs and is launched right from the Sunspot gem, but how does that data source (in my case, xml files) communicate with the app? I am not sure if I understand how localhost:8983/solr is to interact with Rails as is would normally.

Any and all help is appreciated, many many thanks. I am running lion 10.7, ruby 1.9.7, rails 3.2.9, the sunspot gem... THANK YOU!

Richael
  • 405
  • 1
  • 6
  • 12

1 Answers1

0

Not sure if I'm answering all of your questions, but when you run the command:

rails generate sunspot_rails:install

it generates a file in the config directory called sunspot.yml. In that file, it specifies how to connect with a running SOLR database depending on your environment.

The Sunspot gem then looks at that file in order to know how to connect to SOLR.

Rebitzele
  • 3,252
  • 1
  • 20
  • 21
  • 1
    Thank you for your input. I suppose what I am asking is (according to what you just reaffirmed): one bash shell to launch the webserve for rails, another bash shell to launch the solr tool with the xml data source.. and the rails app and the xml source can be listed in different directories... true? – Richael May 06 '13 at 15:23