简体   繁体   中英

Adding a field to the Solr Schema

I am looking to add a field to the Solr schema.

I'm aware that after adding a field to the schema.xml , I have to restart the Solr-instance and rebuild the index. However, does the schema.xml reside on the Solr server or should I change the schema.xml that I am exporting?

Also, does "rebuild the index" refer to exporting data to the Solr search server?

schema.xml does not usually reside within the Solr Server.
It resides in the SOLR.HOME pointed through environment settings (tomcat settings fine, solr web.xml or passed as a system property) to an external directory which holds the cores, configurations and the index files.

If exporting the data means re-feeding the same data to Solr, then it will reindex the data.

Schema file resides in the conf folder of solr home that contains the configuration setting of your index. Yes you have to re-create the index, if your are using DIH then your have to run data-import command again to see the effect of your change.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM