For posterity... After reading through http://wiki.apache.org/solr/SolrConfigXml and http://wiki.apache.org/solr/CoreAdmin and http://issues.apache.org/jira/browse/SOLR-646, I think there's no way for me to make only one core specify &shards=foo, short of duplicating my solrconfig.xml for that core and adding one line:
- I can't use a variable like ${shardsParam} in a single shared solrconfig.xml, because the line <str name="shards">${shardsParam}</str> has to be in there, and that forces a (possibly empty) &shards parameter onto cores that *don't* need one, causing a NullPointerException. - I can't suck in just that one <str> line via a SOLR-646-style import, like #solrconfig.xml <requestHandler> <lst name="defaults"> <import file="${shardspec_file}"/> </list> </requestHandler> #solr.xml <core name="core0"><property name="shardspec_file" value="some_file"/>... <core name="core1"><property name="shardspec_file" value="/dev/null"/>... because SOLR-646's <import> feature got cut. So I think my best bet is to make two mostly-identical solrconfig.xmls, and point core0 to the one specifying a &shards= parameter: <core name="core0" config="core0_solrconfig.xml"/> I don't like the duplication of config, but at least it accomplishes my goal! Michael On Fri, Oct 9, 2009 at 10:37 AM, Michael <solrco...@gmail.com> wrote: > On Fri, Oct 9, 2009 at 10:26 AM, Michael <solrco...@gmail.com> wrote: >> Hm... still no success. Can anyone point me to a doc that explains >> how to define and reference core properties? I've had no luck >> searching Google. > > OK, definition is described here: > http://wiki.apache.org/solr/CoreAdmin#property -- a page I've visited > many times before but somehow had trouble finding. > > Still not sure whether I'm supposed to use "solr.core.shardsParam", or > just "shardsParam", and how to not have a defaulted &shards parameter > for most cores. > > Michael >