Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

solr + haystack + django where do I place schema.xml?

I just installed Solr and Haystack for a Django project I'm working on. Following this Haystack tutorial I created a schema.xml but I'm not sure where to place it in the Solr installation.

My Solr installation is in a directory like this: /solr and I'm starting the Solr service from /solr/example with this command java -jar start.jar.

Any ideas where to place that schema.xml and how to tell Solr to use it?

like image 291
avatar Avatar asked Jul 23 '11 17:07

avatar


People also ask

Where is schema xml in Solr?

The Solr schema. xml (typically found in the solr/conf/ directory) is where you tell Solr what types of fields you plan to support, how those types will be analyzed, and what fields you are going to make available for import and queries. Solr will then base its Lucene underbelly on what you define.

What is schema xml in Solr?

The Solr search engine uses a schema. xml file to describe the structure of each data index. This XML files determines how Solr will build indexes from input documents, and how to perform index and query time processing. As well as describing the structure of the index, schema.

What is Haystack in Django?

Haystack provides modular search for Django. It features a unified, familiar API that allows you to plug in different search backends (such as Solr, Elasticsearch, Whoosh, Xapian, etc.) without having to modify your code.


1 Answers

Solr looks for schema.xml in the ./conf directory under the "Solr home" directory.

See this page for more info.

http://wiki.apache.org/solr/ConfiguringSolr

like image 178
Ken Cochrane Avatar answered Oct 15 '22 09:10

Ken Cochrane