Fwd: Solr MultiCore dataDir bug - a fix

2009-05-07 Thread Noble Paul നോബിള്‍ नोब्ळ्
I didn't notice that the mail was not sent to the list. Plz send all
your communication to the mailing list


-- Forwarded message --
From: Noble Paul നോബിള്‍  नोब्ळ् noble.p...@corp.aol.com
Date: 2009/5/8
Subject: Re: Solr MultiCore dataDir bug - a fix
To: pasi.j.matilai...@tieto.com


are you sure that your solrconfig.xml does not have a dataDir tag ?
If it is there, then it is supposed to take precedence over the one
you have put in solr.xml

On Fri, May 8, 2009 at 10:43 AM,  pasi.j.matilai...@tieto.com wrote:
 Hello,

 I encountered yesterday the problem that MultiCore Solr doesn't handle
 properly the dataDir setting in solr.xml, regardless of whether it's
 specified as a nested property or as an attribute to core element. I found a
 mail thread where you on March 4th, 2009 promised to have it fixed in a day
 or two.
 (http://markmail.org/message/oylfeldy53lebsfe#query:solr%20multicore%20datadir+page:1+mid:abfbhdxxt3r3zujs+state:results)

 Anyway, as the current Solr trunk didn't contain the fix, I hunted the bug
 down myself. And as I don't want to take the time to get account to update
 the patch to Solr SVN myself, I'm sending the fix to you instead.

 In current trunk, in SolrCore constructor, at line 491, there currently is:

     if (dataDir == null)
     dataDir = config.get(dataDir,cd.getDataDir());

 I replaced this with the following code:

     if (dataDir == null) {
  if (cd.getDataDir()!=null)
  dataDir = cd.getDataDir();
  else
     dataDir = config.get(dataDir,cd.getDefaultDataDir());
     }

 I'm not sure this fully represents how this is supposed to work, but it
 works anyway. At least when I specify dataDir as an attribute to core
 element with a path relative to instanceDir:

     !-- instanceDir resolves to solr/current/ and dataDir to
 solr/current/data --
     core name=current instanceDir=current dataDir=data /

 Best regards,

 Pasi J. Matilainen, Software Engineer
 Tieto Finland Oy, RD Services, Devices RD
 pasi.j.matilai...@tieto.com, mobile +358 (0)40 575 7738, fax +358 (0)14 618
 566
 Visiting address: Mattilanniemi 6, 40101 JYVÄSKYLÄ, Mailing address: P.O.
 Box 163, 40101 JYVÄSKYLÄ, Finland, www.tieto.com

 Meet the new Tieto: www.tieto.com/newtieto
 Please note: The information contained in this message may be legally
 privileged and confidential and protected from disclosure. If the reader of
 this message is not the intended recipient, you are hereby notified that any
 unauthorised use, distribution or copying of this communication is strictly
 prohibited. If you have received this communication in error, please notify
 us immediately by replying to the message and deleting it from your
 computer. Thank You.






--
-
Noble Paul | Principal Engineer| AOL | http://aol.com



-- 
-
Noble Paul | Principal Engineer| AOL | http://aol.com


Multicore DataDir

2008-08-01 Thread CameronL

The dataDir parameter specified in the core... element in multicore.xml
does not seem to point to the correct directory.  I commented out the
dataDir element from solrconfig.xml in all of my cores.

I could explicitly set the dataDir for each core in all of the
solrconfig.xml files, but I would rather only have to deal with a single
solrconfig.xml and not have to configure its contents individually for each
of my cores.  Plus, it's pretty convenient to only have to look at 1 file
(multicore.xml) to configure the dataDirs

Is this the expected behavior?  Is there another place I should be setting
it?  
-- 
View this message in context: 
http://www.nabble.com/Multicore-DataDir-tp18784286p18784286.html
Sent from the Solr - User mailing list archive at Nabble.com.



Re: Multicore DataDir

2008-08-01 Thread Ryan McKinley

Check: https://issues.apache.org/jira/browse/SOLR-646

hopefully that will solve your problems...


On Aug 1, 2008, at 4:35 PM, CameronL wrote:



The dataDir parameter specified in the core... element in  
multicore.xml

does not seem to point to the correct directory.  I commented out the
dataDir element from solrconfig.xml in all of my cores.

I could explicitly set the dataDir for each core in all of the
solrconfig.xml files, but I would rather only have to deal with a  
single
solrconfig.xml and not have to configure its contents individually  
for each
of my cores.  Plus, it's pretty convenient to only have to look at 1  
file

(multicore.xml) to configure the dataDirs

Is this the expected behavior?  Is there another place I should be  
setting

it?
--
View this message in context: 
http://www.nabble.com/Multicore-DataDir-tp18784286p18784286.html
Sent from the Solr - User mailing list archive at Nabble.com.