floriansemm / SolrBundle

Solr-Integration into Symfony and Doctrine2
http://floriansemm.github.io/SolrBundle
MIT License
123 stars 73 forks source link

"unkown field" - Best way to create the document schema in solr #129

Closed ozzmaster closed 8 years ago

ozzmaster commented 8 years ago

Hi everyone

I would like to know if there is a way for my Symfony app, using this bundle, to create the initial schema of the solr documents automatically?

Should I code in an event listener or something that will connect to solr, check if an entity's document schema exists solr and if not create it?

Apologies if my terminology is not correct. I have been using ElasticSearch in other project and the bundle I use there creates everything that is needed when the index is recreated.

floriansemm commented 8 years ago

Your solr-instance already contains a schema.xml in the example-DIH folder.