You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by "O. Olson" <ol...@yahoo.it> on 2013/07/15 19:25:05 UTC
Change Velocity Template Directory
Is there any way to change the default Velocity directory where the Velocity
templates are stored? In the example download, I modified the solrconfig.xml
under the Solr Request Handler to add:
<str name="v.base_dir">conf/mycustom/</str>
I have a mycustom directory under the conf directory for the example core,
but I still get the “Unable to find resource 'browse.vm'” exception/error.
I actually renamed the velocity directory to mycustom. So it has all the
template files that Velocity needs - at least that’s what I figured.
Thank you in advance for any help,
O. O.
--
View this message in context: http://lucene.472066.n3.nabble.com/Change-Velocity-Template-Directory-tp4078120.html
Sent from the Solr - User mailing list archive at Nabble.com.
SolrCloud: Collection API question and problem with core loading
Posted by Patrick Mi <pa...@touchpointgroup.com>.
Hi there,
I run 2 solr instances ( Tomcat 7, Solr 4.3.0 , one shard),one external
Zookeeper instance and have lots of cores.
I use collection API to create the new core dynamically after the
configuration for the core is uploaded to the Zookeeper and it all works
fine.
As there are so many cores it takes very long time to load them at start up
I would like to start up the server quickly and load the cores on demand.
When the core is created via collection API it is created with default
parameter : loadOnStartup="true" ( this can be seen in solr.xml )
Question: is there a way to specify this parameter so it can be set 'false'
in collection API ?
Problem: If I manually set loadOnStartup="true" for the core I had exception
below when I used CloudSolrServer to query the core :
Error: org.apache.solr.client.solrj.SolrServerException: No live SolrServers
available to handle this request
Seems to me that CloudSolrServer will not trigger the core to be loaded.
Is it possible to get the core loaded using CloudSolrServer?
Regards,
Patrick
Re: SolrCloud: Collection API question and problem with core loading
Posted by Erick Erickson <er...@gmail.com>.
All of the core loading stuff is on the server side, so CloudSolrServer
isn't really germane (I don't think anyway).
This is in a bit of flux, so try having one core that's loaded on startup
even if it's just a dummy core. There's currently ongoing work to
play nicer with no cores being defined at startup, but that's not in
4.3.
Take a look at: http://wiki.apache.org/solr/CoreAdmin#CREATE
where it talks about optional parameters.
NOTE: 4.4 (release imminent) has substantial fixes for the whole
persistence situation. Also note that solr.xml is going away as a
place to store core information and core discovery will be supported
only from 5.x on.
Good Luck!
Erick
On Mon, Jul 15, 2013 at 9:05 PM, Patrick Mi
<pa...@touchpointgroup.com> wrote:
> Hi there,
>
> I run 2 solr instances ( Tomcat 7, Solr 4.3.0 , one shard),one external
> Zookeeper instance and have lots of cores.
>
> I use collection API to create the new core dynamically after the
> configuration for the core is uploaded to the Zookeeper and it all works
> fine.
>
> As there are so many cores it takes very long time to load them at start up
> I would like to start up the server quickly and load the cores on demand.
>
> When the core is created via collection API it is created with default
> parameter : loadOnStartup="true" ( this can be seen in solr.xml )
>
> Question: is there a way to specify this parameter so it can be set 'false'
> in collection API ?
>
> Problem: If I manually set loadOnStartup="true" for the core I had exception
> below when I used CloudSolrServer to query the core :
> Error: org.apache.solr.client.solrj.SolrServerException: No live SolrServers
> available to handle this request
>
> Seems to me that CloudSolrServer will not trigger the core to be loaded.
>
> Is it possible to get the core loaded using CloudSolrServer?
>
> Regards,
> Patrick
>
>
Re: Change Velocity Template Directory
Posted by "O. Olson" <ol...@yahoo.it>.
Thank you Erik. I did not think the Windows file/directory path format would
work for Solr. For others the following worked for me:
<str
name="v.base_dir">C:\Users\MyUsername\Solr\example\example-DIH\solr\db\conf\mycustom\</str>
Erik Hatcher-4 wrote
> Try supplying an absolute path. I'm away from my computer so can't check
> just yet, but it is probably coded to consider that value absolute since
> moving it generally means you want templates outside of your Solr conf/.
>
> Erik
--
View this message in context: http://lucene.472066.n3.nabble.com/Change-Velocity-Template-Directory-tp4078120p4078188.html
Sent from the Solr - User mailing list archive at Nabble.com.
Re: Change Velocity Template Directory
Posted by Erik Hatcher <er...@gmail.com>.
Try supplying an absolute path. I'm away from my computer so can't check just yet, but it is probably coded to consider that value absolute since moving it generally means you want templates outside of your Solr conf/.
Erik
On Jul 15, 2013, at 13:25, "O. Olson" <ol...@yahoo.it> wrote:
> Is there any way to change the default Velocity directory where the Velocity
> templates are stored? In the example download, I modified the solrconfig.xml
> under the Solr Request Handler to add:
>
> <str name="v.base_dir">conf/mycustom/</str>
>
> I have a mycustom directory under the conf directory for the example core,
> but I still get the “Unable to find resource 'browse.vm'” exception/error.
>
> I actually renamed the velocity directory to mycustom. So it has all the
> template files that Velocity needs - at least that’s what I figured.
>
> Thank you in advance for any help,
> O. O.
>
>
>
>
> --
> View this message in context: http://lucene.472066.n3.nabble.com/Change-Velocity-Template-Directory-tp4078120.html
> Sent from the Solr - User mailing list archive at Nabble.com.