Note that dynamic field additions were added in Solr 4.4 and Solr 5.0 ... none of them have yet been released.
In the meantime, if you want to add a field to your index, you have two options. First, you can make the hard way: add a field to your schema, clear your index, restart Solr and flip everything. This tends to be a little bankrupt.
Alternatively, you can use a dynamic field declaration . If you look in the diagram, you will see lines like these:
<dynamicField name="*_i" type="int" indexed="true" stored="true"/> <dynamicField name="*_is" type="int" indexed="true" stored="true" multiValued="true"/>
This means that if you add a field with a name ending in _i or _is , you will all be ready. They are usually included in the default schema, so if you have the flexibility of what to call in the field, you can be customized with this.
If none of these options looks promising, your third option is to wait for Solr 4.4 or 5.0 and the update (which will also have a reindex in all likelihood!).
mlissner
source share