Is there a pre-defined variable that can be used in schema.xml to point to the solr core directory, or the conf subdirectory? I thought ${solr.home} or perhaps ${solr.solr.home} might work but they didn't (unless -Dsolr.home=/my/solr/home is supplied, that is).
The default solrconfig.xml seems to suggest ${solr.data.dir} can be used.
So I am hoping there is another pre-defined variable like this that points to the solr core directory.

Use case, in case you wonder:
We have our custom CharFilter, Tokenizer TokenFilter, and corresponding factories.
Currently we ship schema.xml that contains lines like:

<charFilter class="com.basistech.rlp.solr.RCLUNormalizeCharFilterFactory"
          rlpContext="solr/conf/rlp-context-rclu.xml"/>

This only works if Solr is started from $SOLR_HOME/example, as it is relative to the current working directory. Our customers have to adjust the value to the absolute path if they'd like to use Tomcat or any other web container other than Solr builtin jetty.
We'd rather like to write something like this:

<charFilter class="com.basistech.rlp.solr.RCLUNormalizeCharFilterFactory"
          rlpContext="${solr.conf.dir}/rlp-context-rclu.xml"/>

Kuro

Reply via email to