OR/NOT query syntax

2009-03-11 Thread Andrew Wall
I'm attempting to write a solr query that ensures that if one field has a
particular value that another field also have a particular value.   I've
arrived at this syntax, but it doesn't seem to work correctly.

((myField:superneat AND myOtherField:somethingElse) OR NOT myField:superneat)

either operand functions correctly on its own - but not when joined together
with the "or not" condition.  I don't understand why this syntax doesn't
work - can someone shed some light on this?

Thanks!
Andrew Wall


Re: SolrJ XML indexing

2009-03-11 Thread Ashish P

Yes cleaning up works...
But not sure how to avoid this happening again??
-Ashish


jonbaer wrote:
> 
> Id suggest what someone else mentioned to just do a full clean up of  
> the index.  Sounds like you might have kill -9 or stopped the process  
> manually while indexing (would be only reason for a left over lock).
> 
> - Jon
> 
> On Mar 11, 2009, at 5:16 AM, Ashish P wrote:
> 
>>
>> I added single in indexDefaults that made the  
>> error
>> before go away but now I am getting following error :
>>
>> Mar 11, 2009 6:12:56 PM org.apache.solr.common.SolrException log
>> SEVERE: java.io.IOException: Cannot overwrite:
>> C:\dw-solr\solr\data\index\_1o.fdt
>>  at  
>> org.apache.lucene.store.FSDirectory.createOutput(FSDirectory.java:440)
>>  at org.apache.lucene.index.FieldsWriter.(FieldsWriter.java:62)
>>  at
>> org 
>> .apache 
>> .lucene 
>> .index.StoredFieldsWriter.initFieldsWriter(StoredFieldsWriter.java:65)
>>
>> Please help..
>>
>>
>> Ashish P wrote:
>>>
>>> Thanks man.
>>> I just tried what u suggested but I am getting following error when
>>> performing request
>>> Mar 11, 2009 6:00:28 PM org.apache.solr.update.SolrIndexWriter
>>> getDirectory
>>> WARNING: No lockType configured for C:\dw-solr\solr\./data/index/  
>>> assuming
>>> 'simple'
>>> Mar 11, 2009 6:00:29 PM org.apache.solr.common.SolrException log
>>> SEVERE: org.apache.lucene.store.LockObtainFailedException: Lock  
>>> obtain
>>> timed out:
>>> simplefsl...@c:\dw-solr\solr\.\data\index 
>>> \lucene-1d6c0059ac2f9f2c83acf749af7e0906-write.lock
>>> at org.apache.lucene.store.Lock.obtain(Lock.java:85)
>>> at org.apache.lucene.index.IndexWriter.init(IndexWriter.java:1140)
>>> at org.apache.lucene.index.IndexWriter.(IndexWriter.java:938)
>>> at
>>> org.apache.solr.update.SolrIndexWriter.(SolrIndexWriter.java: 
>>> 116)
>>>
>>> Any ideas???
>>>
>>> -Ashish
>>>
>>>
>>> Noble Paul നോബിള്‍  नोब्ळ् wrote:

 String xml = null;//load the file to the xml string
 DirectXmlRequest up = new DirectXmlRequest( "/update", xml );
 solrServer.request( up );

 On Wed, Mar 11, 2009 at 2:19 PM, Ashish P 
 wrote:
>
> I have an XML file with structure :
> 
>   ...
>   ...
>   .
>   .
> 
>
> It is present on disk on some location let's say C:\\documents.xml
>
> Q.1. Using solrJ can I index all docs in this file directly?? or  
> do I
> have
> to convert each document to solrInputDocument by parsing XML
>
> Q.2 How to use DirectXmlRequest?? any example
>
> Thanks in advance...
> Ashish
>
>
>
>
> --
> View this message in context:
> http://www.nabble.com/SolrJ-XML-indexing-tp22450845p22450845.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>
>



 -- 
 --Noble Paul


>>>
>>>
>>
>> -- 
>> View this message in context:
>> http://www.nabble.com/SolrJ-XML-indexing-tp22450845p22451235.html
>> Sent from the Solr - User mailing list archive at Nabble.com.
>>
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/SolrJ-XML-indexing-tp22450845p22468203.html
Sent from the Solr - User mailing list archive at Nabble.com.



Re: Tomcat holding deleted snapshots until it's restarted

2009-03-11 Thread Chris Hostetter

: If the problem is not there the other thing that comes to my mind is
: lucene2.9-dev... maybe there's a problem closing indexWriter?... opiously
: it's just a thought.

you never answered yoniks question about wether you see any "Closing 
Searcher" messagges in your log, also it's useful to know what you see in 
the CORE section when you look at stats.jsp ... typically the "main" 
searcher is listed there twice, but during warming you'll see the old 
searcher as well ... if older searchers aren't getting closed for some 
reason, they should be listed there.

i'd start by confirming/ruling out hte old searchers before speculating 
about the indexwriter or other problems.

: > On a quiet system, you should see the original searcher closed right
: > after the new searcher is registered.
: > 
: > Example:
: > Mar 11, 2009 2:22:25 PM org.apache.solr.core.SolrCore registerSearcher
: > INFO: [] Registered new searcher searc...@1f1cbf6 main
: > Mar 11, 2009 2:22:25 PM org.apache.solr.search.SolrIndexSearcher close
: > INFO: Closing searc...@acdd02 main



-Hoss



Re: Replication in 1.3

2009-03-11 Thread Yonik Seeley
On Wed, Mar 11, 2009 at 1:29 PM, Vauthrin, Laurent
 wrote:
> I'm hoping to use Solr version 1.4 but in the meantime I'm trying to get
> replication to work in version 1.3.  I'm running Tomcat as a Windows
> service and have Cygwin installed.

The rsync method of replication is not supported under Windows (due to
differing OS/filesystem semantics).  The Java-based synchronization in
Solr 1.4 does support Windows though.

-Yonik
http://www.lucidimagination.com


Re: Memory implications for default (score) search

2009-03-11 Thread Yonik Seeley
On Wed, Mar 11, 2009 at 6:20 PM, outoftime  wrote:
> I've read on this list and elsewhere
> that sorting by fields has well-defined memory implications - is that true
> for relevance sorting as well?

Relevancy sorting has pretty much no memory overhead.
Note that if you use function query, that can since it typically uses
the FieldCache to obtain values per document (same as sorting).

-Yonik
http://www.lucidimagination.com


Re: Custom path for solr lib and data folder

2009-03-11 Thread Chris Hostetter
Adding '" + jars[j].toString() + "' to Solr classloaderAdding '" + 
jars[j].toString() + "' to Solr classloader

: > But how can i redirect solr to a seperate lib directrory that is outside of
: > the solr.home
: > 
: > Is this possible in solr 1.3
: 
: I don't believe it is possible (but please correct me if I'm wrong).  From
: SolrResourceLoader:
: 
:log.info("Solr home set to '" + this.instanceDir + "'");
:this.classLoader = createClassLoader(new File(this.instanceDir + "lib/"),
: parent);
: 
: So only a lib/ under Solr home directory is used.  It would be a nice

that's the lib directory specific to the core (hence it's relative the 
instanceDir).

In con's original post he was claiming to have problems getting 
solr.xml's sharedLib option to point to an absolute path ... this should 
work fine.

con: when your solr.xml you should see an INFO message starting with 
"loading shared library:..." -- what path is listed on that line?

your sharedLib="%COMMON_LIB%" example won't work (for the reasons Noble 
mentioned) but your sharedLib="C:\lib" should work (assuming that path 
exists) and then immediately following the log message i mentioned 
above, you should see INFO messages like...
Adding file:///...foo.jar to Solr classloader
...for each jar in that directory.  if there are none, or the directory 
can't be found you might see "Reusing parent classloader" or "Can't 
construct solr lib class loader" messages instead.

what do you see in your logs?



-Hoss



Re: Solr 1.3; Data Import w/ Dynamic Fields

2009-03-11 Thread Chris Hostetter

: Subject: Solr 1.3; Data Import w/ Dynamic Fields
: In-Reply-To: <5e76b0ad0903110150h3e75bb68pd3603b8da4261...@mail.gmail.com>

http://people.apache.org/~hossman/#threadhijack
Thread Hijacking on Mailing Lists

When starting a new discussion on a mailing list, please do not reply to 
an existing message, instead start a fresh email.  Even if you change the 
subject line of your email, other mail headers still track which thread 
you replied to and your question is "hidden" in that thread and gets less 
attention.   It makes following discussions in the mailing list archives 
particularly difficult.
See Also:  http://en.wikipedia.org/wiki/Thread_hijacking



-Hoss



Re: indexing multiple schemas Vs extending existing schema

2009-03-11 Thread Chris Hostetter

: Subject: indexing multiple schemas Vs extending existing schema
: In-Reply-To: <746bb9e20903091644g6959224am9445c26c76532...@mail.gmail.com>


http://people.apache.org/~hossman/#threadhijack
Thread Hijacking on Mailing Lists

When starting a new discussion on a mailing list, please do not reply to 
an existing message, instead start a fresh email.  Even if you change the 
subject line of your email, other mail headers still track which thread 
you replied to and your question is "hidden" in that thread and gets less 
attention.   It makes following discussions in the mailing list archives 
particularly difficult.
See Also:  http://en.wikipedia.org/wiki/Thread_hijacking




-Hoss



Re: CJKAnalyzer and Chinese Text sort

2009-03-11 Thread Chris Hostetter

First off: you can't sort on a field where any doc has more then one token 
-- that's why worting on a TextField doesn't work unless you use something 
like the KeywordTokenizer.

Second...

: I found out that reason the strings are not getting sorted is because 
: there is no way to pass the locale information to StrField, I ended up 
: extending StrField to take an additional attribute in schema.xml and 
: then had to override the getSortString method where in I create a new 
: Locale based on the schema attribute and pass it to the StrField. I put 
: this newly created jar file in the lib folder and everything seems to be 
: working fine after that. Since, my java knowledge is almost zilch, I was 
: wondering is this the right way to solve this problem or is there any 
: other recommended approach for this?

I don't remember what the state of Locale-based sorting is, but the 
modifications you describe sound right based on what i remember ... would 
you be interested in submitting them back as a patch?

http://wiki.apache.org/solr/HowToContribute


-Hoss



Re: Tomcat holding deleted snapshots until it's restarted

2009-03-11 Thread Marc Sturlese

Yes, I coded a transformer to deal with the data from a mysql table before
index it with dataimporthandler.
I am actually using a nightly build from middle january with all the
concurrency bugs of dataimporthandler fixed.
After lots of tracing I think the problem could be in the commit void of the
DirectUpdateHandler2.class but still not able to hit where. 
If the problem is not there the other thing that comes to my mind is
lucene2.9-dev... maybe there's a problem closing indexWriter?... opiously
it's just a thought.



Yonik Seeley-2 wrote:
> 
> On Wed, Mar 11, 2009 at 12:23 PM, Marc Sturlese 
> wrote:
>> I have checked the log and it is closing an indexWriter and registering a
>> new searcher but can't see that the older one is closed:
> 
> On a quiet system, you should see the original searcher closed right
> after the new searcher is registered.
> 
> Example:
> Mar 11, 2009 2:22:25 PM org.apache.solr.core.SolrCore registerSearcher
> INFO: [] Registered new searcher searc...@1f1cbf6 main
> Mar 11, 2009 2:22:25 PM org.apache.solr.search.SolrIndexSearcher close
> INFO: Closing searc...@acdd02 main
> 
>> I am using not a plugin, just implemented a transformer to modify the
>> data but this should'nt afect.
> 
> Transformer?  from Data Import Handler?
> What version of Solr are you using?
> 
> -Yonik
> http://www.lucidimagination.com
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Tomcat-holding-deleted-snapshots-until-it%27s-restarted-tp22451252p22465842.html
Sent from the Solr - User mailing list archive at Nabble.com.



Memory implications for default (score) search

2009-03-11 Thread outoftime

Howdy all,

I'm running into a problem where for a search that returns a relatively high
number of results (a few hundred), I'm running into an OutOfMemoryError. I
tried killing all faceting and also not specifying a sort, in hopes that
that would help, but no luck so far. I've read on this list and elsewhere
that sorting by fields has well-defined memory implications - is that true
for relevance sorting as well? Also, is there a way to tell Solr not to
attempt any sorting at all?

In case it helps, here's the greatest hits from the stack trace:

Java heap space
java.lang.OutOfMemoryError (Java_heap_space)
at org.apache.lucene.util.PriorityQueue.initialize() [PriorityQueue.java:36]
at org.apache.solr.search.ScorePriorityQueue.init()
[SolrIndexSearcher.java:1466]
at org.apache.solr.search.SolrIndexSearcher.getDocListAndSetNC()
[SolrIndexSearcher.java:1059]
at org.apache.solr.search.SolrIndexSearcher.getDocListC()
[SolrIndexSearcher.java:801]
at org.apache.solr.search.SolrIndexSearcher.getDocListAndSet()
[SolrIndexSearcher.java:1237]
at org.apache.solr.request.StandardRequestHandler.handleRequestBody()
[StandardRequestHandler.java:117]
at org.apache.solr.handler.RequestHandlerBase.handleRequest()
[RequestHandlerBase.java:77]
at org.apache.solr.core.SolrCore.execute() [SolrCore.java:658]
at org.apache.solr.servlet.SolrDispatchFilter.execute()
[SolrDispatchFilter.java:191]
at org.apache.solr.servlet.SolrDispatchFilter.doFilter()
[SolrDispatchFilter.java:159]
at org.mortbay.jetty.servlet.ServletHandler

Any help much appreciated - thank you!
-- 
View this message in context: 
http://www.nabble.com/Memory-implications-for-default-%28score%29-search-tp22465820p22465820.html
Sent from the Solr - User mailing list archive at Nabble.com.



Re: Phrases in Synonyms.txt

2009-03-11 Thread Vernon Chapman

Hoss,

Thanks I am the op on this question.
I figured it out by just trying t out and what your saying seems to
be correct.

Thanks


Chris Hostetter wrote:

: The question is how would/could I add the final option "Sus scrofa domestica"
: to the list of synonyms for swine would any of these work or am I totally off
: base here?
: 
: 1) swine => hogs,pigs,porcine,"Sus scrofa domestica"

: 2) swine => hogs,pigs,porcine,"Sus\ scrofa\ domestica"

swine => hogs,pigs,porcine,Sus scrofa domestica

...only commas need special escaping.  there are some notes in the wiki 
about the caveats to using multi-word synonyms you should check out 
though.



-Hoss


  


Re: Spatial search using R-tree for indexed bounding boxes

2009-03-11 Thread pjaol

There are many spatial solutions out there
- R-tree
- Quad-Tree
- SRID with positional proximity like geohash
- Voronoi diagrams
etc..

All have their pros & cons as do Cartesian grids.
Feel free to contribute the more there are, the more solutions that can be
applied to different problems, I use a Cartesian method meets my needs for
my work which has a substantial data set. 

If you look at the LocalSolr implementation of LocalLucene you'll notice
that there are 
multiple grids indexed at different levels / tiers. In a very similar
fashion to Quad-Trees.

The reason, you can 'zoom' in as low as you need to.

There are multiple filters occurring for the geo filters in locallucene,
first is an MMB based
on bestFit or zoom level, then afterwards those results are filtered by your
text intersection
and finally by a radial filter. 
The MMB filter, pre-generates the shape or in this case box with all the
id's you're interested in
and using a TermEnumerator pulls those from the index. As the id's are
stored in a sorted fashion
it's a very fast retrieval. Without having to manage memory or a data
structure outside of lucene.

Storing multiple points is possible, doing a radial filter, or sorting on
distance (which is what my work
depends on) is tricky as I use FieldCache to retrieve actual points quickly.
Multiple values in a field cache
dont work. But I am looking at the Uninverted Field method of solr facets
for that.
You will have the same issue no matter what method you use, unless you don't
care
about distance.

If you want to do something more complex like polygon's, you extend the
Shape's class, and create
either another MMB or convex hull method. 
Basically my belief is, that it's faster to find something if you know what
your looking for.
i.e. grid / box id's
The bestFit method essentially lets you skip traversing and just get to the
level you want.
Pre-generate the id's used in a shape, and simply pull them out of the
index.




hossman wrote:
> 
> 
> : Patrick (of local lucene fame) thinks it is possible to do extent
> queries with
> : the cartesian grid method -- essentially you select the "best fit" level
> and
> : cell, and that should be set for anything within the extent.  The
> advantage of
> : this approach is that it is super-fast and scaleable.  The disadvantage
> is
> : that it is only as accurate as the grid.
> 
> i'm way out of my league on spatial search -- but couldn't you use the 
> grid method to whittle down the result space, and then do the computation 
> to determine if a true overlap exists?
> 
> 
> -Hoss
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Spatial-search-using-R-tree-for-indexed-bounding-boxes-tp22318859p22462731.html
Sent from the Solr - User mailing list archive at Nabble.com.



Re: Phrases in Synonyms.txt

2009-03-11 Thread Chris Hostetter
: The question is how would/could I add the final option "Sus scrofa domestica"
: to the list of synonyms for swine would any of these work or am I totally off
: base here?
: 
: 1) swine => hogs,pigs,porcine,"Sus scrofa domestica"
: 2) swine => hogs,pigs,porcine,"Sus\ scrofa\ domestica"

swine => hogs,pigs,porcine,Sus scrofa domestica

...only commas need special escaping.  there are some notes in the wiki 
about the caveats to using multi-word synonyms you should check out 
though.


-Hoss



Re: bug report in "INFO" link at solr admin page using multicore

2009-03-11 Thread Chris Hostetter

SOLR-1064 ... resolved.


: : I think I have detected a bug in admin solr screen. I am using multicore
: : with various cores. When I click a core in the admin page and after click
: : "INFO" the info that apears (class, cache info..) it's always of the same
: : core (the last one in solrconfig.xml).
: : I don't know if there's something wrong in my configuration or it's really a
: : bug... If I click in "SCHEMA" or "CONFIG" the showed files are corret, the
: : problem is just in "INFO"
: : Can someone check it out? In case it happens to other people I can rise a
: : bug.
: 
: please do ... i figured maybe it was just a bad link off the admin screen, 
: but using the "multicore" example both of these URLs display info for 
: core1...
:   http://localhost:8983/solr/core1/admin/registry.jsp
:   http://localhost:8983/solr/core0/admin/registry.jsp
: 
: ...which is pretty scary since the header knows the right core.
: 
: 
: 
: 
: -Hoss
: 



-Hoss



Re: Tomcat holding deleted snapshots until it's restarted

2009-03-11 Thread Yonik Seeley
On Wed, Mar 11, 2009 at 12:23 PM, Marc Sturlese  wrote:
> I have checked the log and it is closing an indexWriter and registering a
> new searcher but can't see that the older one is closed:

On a quiet system, you should see the original searcher closed right
after the new searcher is registered.

Example:
Mar 11, 2009 2:22:25 PM org.apache.solr.core.SolrCore registerSearcher
INFO: [] Registered new searcher searc...@1f1cbf6 main
Mar 11, 2009 2:22:25 PM org.apache.solr.search.SolrIndexSearcher close
INFO: Closing searc...@acdd02 main

> I am using not a plugin, just implemented a transformer to modify the data 
> but this should'nt afect.

Transformer?  from Data Import Handler?
What version of Solr are you using?

-Yonik
http://www.lucidimagination.com


Re: input XSLT

2009-03-11 Thread Noble Paul നോബിള്‍ नोब्ळ्
On Tue, Mar 10, 2009 at 12:17 PM, CIF Search  wrote:
> Just as you have an xslt response writer to convert Solr xml response to
> make it compatible with any application, on the input side do you have an
> xslt module that will parse xml documents to solr format before posting them
> to solr indexer. I have gone through dataimporthandler, but it works in data
> 'pull' mode i.e. solr pulls data from the given location. I would still want
> to work with applications 'posting' documents to solr indexer as and when
> they want.
it is a limitation of DIH, but if you can put your xml in a file
behind an http server then you can fire a command to DIH to pull data
from the url quite easily.
>
> Regards,
> CI
>



-- 
--Noble Paul


Re: Version 1.4 of Solr

2009-03-11 Thread Noble Paul നോബിള്‍ नोब्ळ्
we should revive the thread on releasing 1.4 a bit earlier. let us
start trimming down the list of unresolved issues.

On Tue, Mar 10, 2009 at 11:37 PM, Otis Gospodnetic
 wrote:
>
> I've been working with the mid-April assumption.
>
> Otis
> --
> Sematext -- http://sematext.com/ -- Lucene - Solr - Nutch
>
>
>
> - Original Message 
>> From: "Vauthrin, Laurent" 
>> To: solr-user@lucene.apache.org
>> Sent: Tuesday, March 10, 2009 1:25:01 PM
>> Subject: Version 1.4 of Solr
>>
>> Hello,
>>
>>
>>
>> I'm not sure if this is the right forum for this, but I'm wondering if I
>> could get a rough timeline of when version 1.4 of Solr might be out?
>> I'm trying to figure out whether we will be able to use the new built-in
>> replication as opposed to the current rsync collection distribution.
>>
>>
>>
>> Thanks,
>>
>> Laurent
>
>



-- 
--Noble Paul


Re: Verbose(r) logging in DIH?

2009-03-11 Thread Noble Paul നോബിള്‍ नोब्ळ्
SOLR-1062 just logs the details at an entity level.

suggest ways to log other events.

On Wed, Mar 11, 2009 at 10:51 PM, Jon Baer  wrote:
> +1 for this (as it would be an added bonus to do something based on the log
> events) ... so in this case if you have that transformer does it mean it
> will get events before and after the import?  Correct me if Im wrong there
> are currently (1.4) preImportDeleteQuery and postImportDeleteQuery hooks for
> the entire import just nothing on the entity level?
>
> - Jon
>
> On Mar 9, 2009, at 2:48 PM, Noble Paul നോബിള്‍ नोब्ळ् wrote:
>
>> it is really not available. probably we can have a LogTransformer
>> which can Log using slf4j
>>
>> 
>> 
>> 
>>
>>
>> On Mon, Mar 9, 2009 at 11:55 PM, Jon Baer  wrote:
>>>
>>> Hi,
>>>
>>> Is there currently anything in DIH to allow for more verbose logging?
>>>  (something more than status) ... was there a way to hook in your own for
>>> debugging purposes?  I can't seem to locate the options in the Wiki or
>>> remember if it was available.
>>>
>>> Thanks.
>>>
>>> - Jon
>>>
>>
>>
>>
>> --
>> --Noble Paul
>
>



-- 
--Noble Paul


Re: bug report in "INFO" link at solr admin page using multicore

2009-03-11 Thread Chris Hostetter

: I think I have detected a bug in admin solr screen. I am using multicore
: with various cores. When I click a core in the admin page and after click
: "INFO" the info that apears (class, cache info..) it's always of the same
: core (the last one in solrconfig.xml).
: I don't know if there's something wrong in my configuration or it's really a
: bug... If I click in "SCHEMA" or "CONFIG" the showed files are corret, the
: problem is just in "INFO"
: Can someone check it out? In case it happens to other people I can rise a
: bug.

please do ... i figured maybe it was just a bad link off the admin screen, 
but using the "multicore" example both of these URLs display info for 
core1...
  http://localhost:8983/solr/core1/admin/registry.jsp
  http://localhost:8983/solr/core0/admin/registry.jsp

...which is pretty scary since the header knows the right core.




-Hoss



Replication in 1.3

2009-03-11 Thread Vauthrin, Laurent
I'm hoping to use Solr version 1.4 but in the meantime I'm trying to get
replication to work in version 1.3.  I'm running Tomcat as a Windows
service and have Cygwin installed.  I'm trying to get the snapshooter
script to run with the following in my solrconfig.xml:

 



  c:/cygwin/bin/bash-test.bat

  

  true



 

(The batch file executes: c:\cygwin\bin\bash -c
'/cygdrive/c/apps/prod/TomcatSolr/Solr/bin/snapshooter')

This batch file runs but it apparently freezes when running the
snapshooter script.  Obviously I'm going about this the wrong way.
Anyone have pointers on what I might be doing wrong?

 

Thanks!

Laurent



Re: Compound word search (maybe DisMaxQueryPaser problem)

2009-03-11 Thread Chris Hostetter
: Hmmm was my mail so weird or my question so stupid ... or is there simply
: noone with an answer? Not even a hint? :(

patience my freind, i've got a backlog of ~~500 Lucene related messages in 
my INBOX, and i was just reading your original email when this reply came 
in.

In generally this is a fairly hard problem ... the easiest solution i know 
of that works in most cases is to do index time expansion using the 
SYnonymFilter, so regardless of wether a document contains "usbcable" 
"usb-cable" or "usb cable" all three varients get indexed, and then the 
user can search for any of them.

the downside is that it can throw off your tf/idf stats for some terms (if 
they apear by themselves, and as part of a compound) and it can result in 
false positives for esoteric phrase searches (but that tends to be more of 
a theoretical problem then an actual one.

: > But this never happens since with the DisMax Searcher the parser produces a
: > query like this:
: > 
: > ((category:blue | name:blue)~0.1 (category:tooth | name:tooth)~0.1)
...
: > to deal with this compound word problem? Is there another query parser that
: > already does the trick?

take a look at the FieldQParserPlugin ... it passes the raw query string 
to the analyser of a specified field -- this would let your TokenFilters 
see the "stream" of tokens (which isn't possible with the conventional 
QueryParser tokenization rules) but it doesn't have any of the 
"field/query matric cross product" goodness of dismax -- you'd only be 
able to query the one field.

(Hmmm i wonder if DisMaxQParser 2.0 could have an option to let you 
specify a FieldType whose analyzer was used to tokenize the query string 
instead of using the Lucene QueryParser JavaCC tokenization, and *then* 
the tokens resulting from that initial analyzer could be passed to the 
analyzers of the various qf fields ... hmmm, that might be just crazy 
enough to be too crazy to work)




-Hoss


Re: Verbose(r) logging in DIH?

2009-03-11 Thread Jon Baer
+1 for this (as it would be an added bonus to do something based on  
the log events) ... so in this case if you have that transformer does  
it mean it will get events before and after the import?  Correct me if  
Im wrong there are currently (1.4) preImportDeleteQuery and  
postImportDeleteQuery hooks for the entire import just nothing on the  
entity level?


- Jon

On Mar 9, 2009, at 2:48 PM, Noble Paul നോബിള്‍  
नोब्ळ् wrote:



it is really not available. probably we can have a LogTransformer
which can Log using slf4j






On Mon, Mar 9, 2009 at 11:55 PM, Jon Baer  wrote:

Hi,

Is there currently anything in DIH to allow for more verbose logging?
 (something more than status) ... was there a way to hook in your  
own for
debugging purposes?  I can't seem to locate the options in the Wiki  
or

remember if it was available.

Thanks.

- Jon





--
--Noble Paul




Re: use () in the query string

2009-03-11 Thread Chris Hostetter

: In my case, my query of "id_s_i_s_nm:(om_B00114162K*)" returned nothing 
: but query "id_s_i_s_nm:om_B00114162K*" returned the right result.
: 
: What's the difference between using () or not.

parensx are used for grouping -- when used after a field name like that, 
they mean that you want all of the sub clauses in the group to be queried 
against that field...
 
this...
+foo:(+aaa bbb -ccc)
is short hand for this...
+(+foo:aaa foo:bbb -foo:ccc)

...in your case, only having a single query inside the group should make 
those two examples function identical.  can you post the debug output when 
using debugQuery=true for both of those queries, along with the fieldtype 
and field decalrations for that field?



-Hoss



Re: input XSLT

2009-03-11 Thread Chris Hostetter
: > Just as you have an xslt response writer to convert Solr xml response to
: > make it compatible with any application, on the input side do you have an
: > xslt module that will parse xml documents to solr format before posting them
: > to solr indexer. I have gone through dataimporthandler, but it works in data

some Proof Of Concept work was done in the past, but it never really took 
off...
https://issues.apache.org/jira/browse/SOLR-285
https://issues.apache.org/jira/browse/SOLR-370

now that we have DIH, I think another approach (that would fit better with 
how things currently are) would be having a "ContentStreamDataSource" for 
DIH analogous to the HttpDataSource (except without any explicit knowledge 
of URLs) thatresepected the standard COntentStream params and could then 
work with the XPathEntityProcessor

-Hoss



Re: Compound word search (maybe DisMaxQueryPaser problem)

2009-03-11 Thread Walter Underwood
Sorry, I missed this. We have the same problem.

None of our customers use query syntax, so I have considered making a
full-text query parser. Use the analyzer chain, then convert the result
into a big OR query, then pass it to the rest of Dismax. Shingles and
synonyms should work at query time with that approach.

This question should probably go to a Lucene list, too.

wunder

On 3/11/09 2:54 AM, "Tobias Dittrich"  wrote:

> Hmmm was my mail so weird or my question so stupid ... or is
> there simply noone with an answer? Not even a hint? :(
> 
> Tobias Dittrich schrieb:
>> Hi all,
>> 
>> I know there are a lot of topics about compound word search already but
>> I haven't found anything for my specific problem yet. So if this is
>> already answered (which would be nice :)) then any hints or search
>> phrases for the mail archive would be apreciated.
>> 
>> Bascially I want users to be able to search my index for compound words
>> that are not really compounds but merely terms that can be written in
>> several ways.
>> 
>> For example I have the categories "usb" and "cable" in my index and I
>> want the user to be able to search for "usbcable" or "usb-cable" etc.
>> Also there is "bluetooth" in the index and I want the search for "blue
>> tooth" to return the corresponding documents.
>> 
>> My approach is to use ShingleFilterFactory followed by
>> WordDelimiterFilterFactory to index all possible combinations of words
>> and get rid of intra-word delimiters. This nicely covers the first part
>> of my requirements since the terms "usb" and "cable" somewhere along the
>> process get concatenated and "usbcable" is in the index.
>> 
>> Now I also want use this on the query side, so the user input "blue
>> tooth" (not as phrase) would become "bluetooth" for this field and
>> produce a hit. But this never happens since with the DisMax Searcher the
>> parser produces a query like this:
>> 
>> ((category:blue | name:blue)~0.1 (category:tooth | name:tooth)~0.1)
>> 
>> And the filters and analysers for this field never get to see the whole
>> user query and cannot perform their shingle and delimiter tasks :(
>> 
>> So my question now is: how can I get this working? Is there a preferable
>> way to deal with this compound word problem? Is there another query
>> parser that already does the trick?
>> 
>> Or would it make sense to write my own query parser that passes the user
>> query "as is" to the several fields?
>> 
>> Any hints on this are welcome.
>> 
>> Thanks in advance
>> Tobias
>> 



Re: Version 1.4 of Solr

2009-03-11 Thread Matthew Runo
Yes, we are using the Java replication feature to send our index and  
configuration files from our master server to 4 slaves.


Thanks for your time!

Matthew Runo
Software Engineer, Zappos.com
mr...@zappos.com - 702-943-7833

On Mar 11, 2009, at 9:29 AM, Jon Baer wrote:


Are you using the replication feature by any chance?

- Jon

On Mar 10, 2009, at 2:28 PM, Matthew Runo wrote:

We're currently using 1.4 in production right now, using a recent  
nightly. It's working fine for us.


Thanks for your time!

Matthew Runo
Software Engineer, Zappos.com
mr...@zappos.com - 702-943-7833

On Mar 10, 2009, at 10:25 AM, Vauthrin, Laurent wrote:


Hello,



I'm not sure if this is the right forum for this, but I'm  
wondering if I

could get a rough timeline of when version 1.4 of Solr might be out?
I'm trying to figure out whether we will be able to use the new  
built-in

replication as opposed to the current rsync collection distribution.



Thanks,

Laurent









RE: Version 1.4 of Solr

2009-03-11 Thread Vauthrin, Laurent
I'm attempting to set up the 1.3 replication feature in Windows via
Cygwin.  The 1.4 version looks a little simpler which is why I was
prodding the last about the 1.4 release date.

-Original Message-
From:
solr-user-return-19484-laurent.vauthrin=disney@lucene.apache.org
[mailto:solr-user-return-19484-laurent.vauthrin=disney@lucene.apache
.org] On Behalf Of Jon Baer
Sent: Wednesday, March 11, 2009 9:29 AM
To: solr-user@lucene.apache.org
Subject: Re: Version 1.4 of Solr

Are you using the replication feature by any chance?

- Jon

On Mar 10, 2009, at 2:28 PM, Matthew Runo wrote:

> We're currently using 1.4 in production right now, using a recent  
> nightly. It's working fine for us.
>
> Thanks for your time!
>
> Matthew Runo
> Software Engineer, Zappos.com
> mr...@zappos.com - 702-943-7833
>
> On Mar 10, 2009, at 10:25 AM, Vauthrin, Laurent wrote:
>
>> Hello,
>>
>>
>>
>> I'm not sure if this is the right forum for this, but I'm wondering  
>> if I
>> could get a rough timeline of when version 1.4 of Solr might be out?
>> I'm trying to figure out whether we will be able to use the new  
>> built-in
>> replication as opposed to the current rsync collection distribution.
>>
>>
>>
>> Thanks,
>>
>> Laurent
>>
>



Re: Version 1.4 of Solr

2009-03-11 Thread Jon Baer

Are you using the replication feature by any chance?

- Jon

On Mar 10, 2009, at 2:28 PM, Matthew Runo wrote:

We're currently using 1.4 in production right now, using a recent  
nightly. It's working fine for us.


Thanks for your time!

Matthew Runo
Software Engineer, Zappos.com
mr...@zappos.com - 702-943-7833

On Mar 10, 2009, at 10:25 AM, Vauthrin, Laurent wrote:


Hello,



I'm not sure if this is the right forum for this, but I'm wondering  
if I

could get a rough timeline of when version 1.4 of Solr might be out?
I'm trying to figure out whether we will be able to use the new  
built-in

replication as opposed to the current rsync collection distribution.



Thanks,

Laurent







Re: SolrJ XML indexing

2009-03-11 Thread Jon Baer
Id suggest what someone else mentioned to just do a full clean up of  
the index.  Sounds like you might have kill -9 or stopped the process  
manually while indexing (would be only reason for a left over lock).


- Jon

On Mar 11, 2009, at 5:16 AM, Ashish P wrote:



I added single in indexDefaults that made the  
error

before go away but now I am getting following error :

Mar 11, 2009 6:12:56 PM org.apache.solr.common.SolrException log
SEVERE: java.io.IOException: Cannot overwrite:
C:\dw-solr\solr\data\index\_1o.fdt
	at  
org.apache.lucene.store.FSDirectory.createOutput(FSDirectory.java:440)

at org.apache.lucene.index.FieldsWriter.(FieldsWriter.java:62)
at
org 
.apache 
.lucene 
.index.StoredFieldsWriter.initFieldsWriter(StoredFieldsWriter.java:65)


Please help..


Ashish P wrote:


Thanks man.
I just tried what u suggested but I am getting following error when
performing request
Mar 11, 2009 6:00:28 PM org.apache.solr.update.SolrIndexWriter
getDirectory
WARNING: No lockType configured for C:\dw-solr\solr\./data/index/  
assuming

'simple'
Mar 11, 2009 6:00:29 PM org.apache.solr.common.SolrException log
SEVERE: org.apache.lucene.store.LockObtainFailedException: Lock  
obtain

timed out:
simplefsl...@c:\dw-solr\solr\.\data\index 
\lucene-1d6c0059ac2f9f2c83acf749af7e0906-write.lock

at org.apache.lucene.store.Lock.obtain(Lock.java:85)
at org.apache.lucene.index.IndexWriter.init(IndexWriter.java:1140)
at org.apache.lucene.index.IndexWriter.(IndexWriter.java:938)
at
org.apache.solr.update.SolrIndexWriter.(SolrIndexWriter.java: 
116)


Any ideas???

-Ashish


Noble Paul നോബിള്‍  नोब्ळ् wrote:


String xml = null;//load the file to the xml string
DirectXmlRequest up = new DirectXmlRequest( "/update", xml );
solrServer.request( up );

On Wed, Mar 11, 2009 at 2:19 PM, Ashish P 
wrote:


I have an XML file with structure :

  ...
  ...
  .
  .


It is present on disk on some location let's say C:\\documents.xml

Q.1. Using solrJ can I index all docs in this file directly?? or  
do I

have
to convert each document to solrInputDocument by parsing XML

Q.2 How to use DirectXmlRequest?? any example

Thanks in advance...
Ashish




--
View this message in context:
http://www.nabble.com/SolrJ-XML-indexing-tp22450845p22450845.html
Sent from the Solr - User mailing list archive at Nabble.com.






--
--Noble Paul







--
View this message in context: 
http://www.nabble.com/SolrJ-XML-indexing-tp22450845p22451235.html
Sent from the Solr - User mailing list archive at Nabble.com.





Re: Tomcat holding deleted snapshots until it's restarted

2009-03-11 Thread Marc Sturlese

Hey Yonik,
I have realized that the problem is happening not because of the snapshots.
I mean, I do an index and optimize it. Modifiy the database and to
delta-import and optimize again... After that I do an lsof of the tomcat
user and I see the old index still holded by tomcat...

...
ava  12814  tomcat   88r  REG8,2 149279785  2902977
/home/smack/solr/data/index/_56n.frq (deleted)
java  12814  tomcat   89r  REG8,2  91797827  2902978
/home/smack/solr/data/index/_56n.prx (deleted)
java  12814  tomcat   90r  REG8,2   4196563  2902979
/home/smack/solr/data/index/_56n.nrm (deleted)
...

I am using not a plugin, just implemented a transformer to modify the data
but this should'nt afect.
At least I see that actually the problem seems to be that an indexSearcher
or indexWriter is not beig closed...
I have checked the log and it is closing an indexWriter and registering a
new searcher but can't see that the older one is closed:

Mar 11 17:02:37 127.0.0.1 solr: 3926476 [Thread-47] DEBUG
org.apache.solr.update.SolrIndexWriter - Closing Writer DirectUpdateHandler2
Mar 11 17:02:38 127.0.0.1 solr: 3927659 [Thread-47] INFO 
org.apache.solr.core.SolrCore - TrovitDeletionPolicy.onCommit: commits:
Mar 11 17:02:38 127.0.0.1 solr: 3927660 [Thread-47] INFO 
org.apache.solr.core.SolrCore - last commit = 1234970421620
Mar 11 17:02:38 127.0.0.1 solr: 3927924 [Thread-47] INFO 
org.apache.solr.search.SolrIndexSearcher - Opening searc...@a9f827 main
Mar 11 17:02:38 127.0.0.1 solr: 3927924 [Thread-47] INFO 
org.apache.solr.update.UpdateHandler - end_commit_flush
Mar 11 17:02:38 127.0.0.1 solr: 3927925 [pool-11-thread-1] INFO 
org.apache.solr.search.SolrIndexSearcher - autowarming searc...@a9f827 main
from searc...@1e0bf98 main
fieldValueCache{lookups=0,hits=0,hitratio=0.00,inserts=0,evictions=0,size=3,warmupTime=0,cumulative_lookups=0,cumulative_hits=0,cumulative_hitratio=0.00,cumulative_inserts=0,cumulative_evictions=0,item_fa_region={field=fa_region,memSize=5599982,tindexSize=56,time=48,phase1=44,nTerms=50,bigTerms=3,termInstances=488689,uses=3},item_fa_city_area={field=fa_city_area,memSize=5599654,tindexSize=50,time=469,phase1=465,nTerms=18,bigTerms=0,termInstances=352,uses=3},item_fa_city={field=fa_city,memSize=5633866,tindexSize=1494,time=94,phase1=91,nTerms=5767,bigTerms=0,termInstances=685467,uses=3}}
Mar 11 17:02:38 127.0.0.1 solr: 3927925 [pool-11-thread-1] INFO 
org.apache.solr.search.SolrIndexSearcher - autowarming result for
searc...@a9f827 main
fieldValueCache{lookups=0,hits=0,hitratio=0.00,inserts=0,evictions=0,size=0,warmupTime=0,cumulative_lookups=0,cumulative_hits=0,cumulative_hitratio=0.00,cumulative_inserts=0,cumulative_evictions=0}
Mar 11 17:02:38 127.0.0.1 solr: 3927925 [pool-11-thread-1] INFO 
org.apache.solr.search.SolrIndexSearcher - autowarming searc...@a9f827 main
from searc...@1e0bf98 main
filterCache{lookups=0,hits=0,hitratio=0.00,inserts=0,evictions=0,size=20,warmupTime=279,cumulative_lookups=0,cumulative_hits=0,cumulative_hitratio=0.00,cumulative_inserts=0,cumulative_evictions=0}
Mar 11 17:02:38 127.0.0.1 solr: 3928161 [pool-11-thread-1] INFO 
org.apache.solr.search.SolrIndexSearcher - autowarming result for
searc...@a9f827 main
filterCache{lookups=0,hits=0,hitratio=0.00,inserts=0,evictions=0,size=20,warmupTime=236,cumulative_lookups=0,cumulative_hits=0,cumulative_hitratio=0.00,cumulative_inserts=0,cumulative_evictions=0}
Mar 11 17:02:38 127.0.0.1 solr: 3928161 [pool-11-thread-1] INFO 
org.apache.solr.search.SolrIndexSearcher - autowarming searc...@a9f827 main
from searc...@1e0bf98 main
queryResultCache{lookups=0,hits=0,hitratio=0.00,inserts=5,evictions=0,size=5,warmupTime=10,cumulative_lookups=0,cumulative_hits=0,cumulative_hitratio=0.00,cumulative_inserts=0,cumulative_evictions=0}
Mar 11 17:02:38 127.0.0.1 solr: 3928171 [pool-11-thread-1] INFO 
org.apache.solr.search.SolrIndexSearcher - autowarming result for
searc...@a9f827 main
queryResultCache{lookups=0,hits=0,hitratio=0.00,inserts=5,evictions=0,size=5,warmupTime=10,cumulative_lookups=0,cumulative_hits=0,cumulative_hitratio=0.00,cumulative_inserts=0,cumulative_evictions=0}
Mar 11 17:02:38 127.0.0.1 solr: 3928171 [pool-11-thread-1] INFO 
org.apache.solr.search.SolrIndexSearcher - autowarming searc...@a9f827 main
from searc...@1e0bf98 main
documentCache{lookups=0,hits=0,hitratio=0.00,inserts=5,evictions=0,size=5,warmupTime=0,cumulative_lookups=0,cumulative_hits=0,cumulative_hitratio=0.00,cumulative_inserts=0,cumulative_evictions=0}
Mar 11 17:02:38 127.0.0.1 solr: 3928171 [pool-11-thread-1] INFO 
org.apache.solr.search.SolrIndexSearcher - autowarming result for
searc...@a9f827 main
documentCache{lookups=0,hits=0,hitratio=0.00,inserts=0,evictions=0,size=0,warmupTime=0,cumulative_lookups=0,cumulative_hits=0,cumulative_hitratio=0.00,cumulative_inserts=0,cumulative_evictions=0}
Mar 11 17:02:38 127.0.0.1 solr: 3928171 [pool-11-threa

Re: Tomcat holding deleted snapshots until it's restarted

2009-03-11 Thread Yonik Seeley
On Wed, Mar 11, 2009 at 5:17 AM, Marc Sturlese  wrote:
> I have noticed that once snapshots are deleted, tomcat keeps holding
> references to them.Due to this disk space will never set free until Tomcat
> is restarted, I have realized that doing a lsof | grep 'tomcat', the result
> look like:

That suggests that the index files aren't being closed for some reason.
After the new index searcher is registered, do you see the close of
the old index reader in the logs?
Do you have any Solr modifications or plugins?

-Yonik
http://www.lucidimagination.com


> java 22015 tomcat 614r REG 253,0 1149569723 1093456605
> /var/local/solr/data/index/_1fb.fdt (deleted)
> java 22015 tomcat 615r REG 253,0 12724500 1093456606
> /var/local/solr/data/index/_1fb.fdx (deleted)
> java 22015 tomcat 616r REG 253,0 175953343 1093456607
> /var/local/solr/data/index/_1fb.tis (deleted)
> java 22015 tomcat 617r REG 253,0 1989522 1102344114
> /var/local/solr/sdata/index/_1fb.tii (deleted)
> java 22015 tomcat 618r REG 253,0 178646437 1102344140
> /var/local/solr/data/index/_1fb.frq (deleted)
> java 22015 tomcat 619r REG 253,0 108460405 1102344154
> /var/local/solr/sdata/index/_1fb.prx (deleted)
>
> ...
>
> How can I make tomcat free the snapshots. Or even better... why is it
> happening?
> Thanks in advance
> --
> View this message in context: 
> http://www.nabble.com/Tomcat-holding-deleted-snapshots-until-it%27s-restarted-tp22451252p22451252.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>
>


Re: Organizing POJO's in a heirarchy in Solr

2009-03-11 Thread Praveen_Kumar_Jayaram


Thanks for the pointers Erik.


Erik Hatcher wrote:
> 
> 
> On Mar 11, 2009, at 10:39 AM, PKJ wrote:
>> Could you please post some good pointers for learning more on Solr?
> 
> The Solr wiki is quite rich with details.  The official Solr tutorial  
> is a nice quick start, and we expanded a bit on this with our article  
> and screencast here:
> 
>   
>  >
> 
> The video is best viewed here:
> 
>   
>  >
> 
> And lots more here: http://wiki.apache.org/solr/SolrResources
> 
> And while I'm at it, I'll shamelessly plug Lucene in Action, 2nd  
> edition, which is available in pre-release e-book (and print will ship  
> when it's ready, later this year).  A Solr chapter is in progress.  A  
> just got a limited time discount code to share with the world.   
> Details here: 
> 
>   Erik
> 
> 
>   
> 
> 


-
Regards,
Praveen
-- 
View this message in context: 
http://www.nabble.com/Organizing-POJO%27s-in-a-heirarchy-in-Solr-tp22427900p22457904.html
Sent from the Solr - User mailing list archive at Nabble.com.



Re: Organizing POJO's in a heirarchy in Solr

2009-03-11 Thread Erik Hatcher


On Mar 11, 2009, at 10:39 AM, PKJ wrote:

Could you please post some good pointers for learning more on Solr?


The Solr wiki is quite rich with details.  The official Solr tutorial  
is a nice quick start, and we expanded a bit on this with our article  
and screencast here:





The video is best viewed here:




And lots more here: http://wiki.apache.org/solr/SolrResources

And while I'm at it, I'll shamelessly plug Lucene in Action, 2nd  
edition, which is available in pre-release e-book (and print will ship  
when it's ready, later this year).  A Solr chapter is in progress.  A  
just got a limited time discount code to share with the world.   
Details here: 


Erik





Re: Solr configuration with Text files

2009-03-11 Thread Shalin Shekhar Mangar
On Wed, Mar 11, 2009 at 8:32 PM, KennyN  wrote:

>
> Thanks for the responses guys!
>
> I looked around the wiki for an example of using DataImportHandler to
> iterate over a list of files and read the content into a field and didn't
> find anything. I agree it would be useful!
>

With 1.3 you still have the FileListEntityProcessor and the
FileDataSource/XPathEntityProcessor using which you iterate over the XML
files you described above. You'll need to write a Transformer which can get
the value of the 'id' field, read it's contents and store them into the
'content' field.

With 1.4 trunk you can remove the need for the custom Transformer and use
FileDataSource/PlainTextEntityProcessor instead.

-- 
Regards,
Shalin Shekhar Mangar.


Re: query on defaultSearchField?

2009-03-11 Thread Erik Hatcher


On Mar 11, 2009, at 11:14 AM, Kalidoss MM wrote:

1)
Can i give by default defaultSearchField with multiple field  
values as

like
 text, Tag, CategorydefaultSearchField>




No, but


 Or should i use
 
 


that will work, or look into using the dismax parser where you can  
specify the fields to search and their boosts with the qf parameter.


Erik



query on defaultSearchField?

2009-03-11 Thread Kalidoss MM
Hi,

1)
 Can i give by default defaultSearchField with multiple field values as
like
  text, Tag, Category

  Or should i use
  
  

Thanks,
Kalidoss.m,


Re: Solr configuration with Text files

2009-03-11 Thread KennyN

Thanks for the responses guys! 

I looked around the wiki for an example of using DataImportHandler to
iterate over a list of files and read the content into a field and didn't
find anything. I agree it would be useful!



Erik Hatcher wrote:
> 
> Using Solr Cell (ExtractingRequestHandler) which is now built into  
> trunk, and thus an eventual Solr 1.4 release, indexing a directory of  
> text (or even Word, PDF, etc) files is mostly 'out of the box'.
> 
> It still requires scripting an iteration over all files and sending  
> them.  Here's an example of doing that scripting using Ant and the ant- 
> contrib  and  tasks:
> 
>
>  
>
>
>  Processing @{filename}
> 
>   failonerror="true">
>
>
>
>
> 
>
>
>
>
>  
>
>  
>
> 
> And it also should be possible, perhaps slightly easier and more built- 
> in to do the entire iteration using DataImportHandler's ability to  
> iterate over a list of files and read their contents into a field.   
> [an example of this on the wiki would be handy, or a pointer to it if  
> it doesn't already exist]
> 
>   Erik
> 
> 
> On Mar 10, 2009, at 2:01 PM, KennyN wrote:
> 
>>
>> This functionality is possible 'out of the box', right? Or am I  
>> going to need
>> to code up something that reads in the id named files and generates  
>> the xml
>> file?
>> -- 
>> View this message in context:
>> http://www.nabble.com/Solr-configuration-with-Text-files-tp22438201p22440095.html
>> Sent from the Solr - User mailing list archive at Nabble.com.
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Solr-configuration-with-Text-files-tp22438201p22457049.html
Sent from the Solr - User mailing list archive at Nabble.com.



Re: Tomcat holding deleted snapshots until it's restarted

2009-03-11 Thread Marc Sturlese

Hey Shalin,
I am using XFS file system with Debian Linux version 2.6.26-1-amd64.
Tomcat 5.5 server and java 1.6

As I optimize the index always before doing an snapshot (so the hard links
will have the size of the whole index every time they are shot) I will try
to modify snapshooter to create the snapshots doing a normal copy instead of
using hard links.

One question, are you using jetty or tomcat? I have thought that maybe this
just happens with tomcat...
If something comes to your mind please let me know. I have to be restarting
my production tomcat every time the disk is consumed and it's being a bit
messy... hope the modification in snapshooter works...

Thanks in advance



Shalin Shekhar Mangar wrote:
> 
> On Wed, Mar 11, 2009 at 3:07 PM, Marc Sturlese
> wrote:
> 
>>
>> I am using the scripts of Collection Distribution.
>> The problem is just happening in the master, not in the slaves.
>> Do you have any clue? I am fighting against this since a few days ago...
>> Thanks in advance
>>
>> No Marc, I'm clueless too. I haven't seen this behavior before. Which OS
> and filesystem are you using? Perhaps someone else may have more insight.
> 
> -- 
> Regards,
> Shalin Shekhar Mangar.
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Tomcat-holding-deleted-snapshots-until-it%27s-restarted-tp22451252p22456694.html
Sent from the Solr - User mailing list archive at Nabble.com.



Re: Organizing POJO's in a heirarchy in Solr

2009-03-11 Thread PKJ


Thanks for your response Eric.
I appreciate your idea to have the path as a property/field itself. Am
pretty new to Solr and Lucene.

Could you please post some good pointers for learning more on Solr?


Erik Hatcher wrote:
> 
> 
> On Mar 11, 2009, at 8:47 AM, Eric Pugh wrote:
>> Solr really isn't organized for tree structures of data.  I think  
>> you might do better using a database with a tree structure.
> 
> That's not a very fair statement.  Sure, documents in Solr/Lucene are  
> simply composed of a flat list of fields, but one can store a path- 
> like representation in a field and search within hierarchies.  For  
> example, indexing a "string" path field with values such as:
> 
> path: /Repository/Folder1/POJO1
> 
> One could query for /Repository/* to get all documents (err, objects)  
> from that tree downward, and so on for any sub or complete path.
> 
> The main thing to look at when figuring out how to squash a domain  
> into a Lucene index is what exactly do you need on the querying side  
> of things, rather than looking at it from a domain model and seeing  
> how to represent relationships and hierarchy from that perspective.
> 
>   Erik
> 
> 
>>
>>
>> pojo would be a table of pojo's serialized out.  And the parent_id  
>> could point to another structure that builds the tree.  Can you  
>> flesh out your use case more of why they need to be in a tree  
>> structure.
>>
>> Eric
>>
>>
>>
>> On Mar 11, 2009, at 8:29 AM, PKJ wrote:
>>
>>>
>>>
>>> Is there anyone who have any idea solve this issue?
>>> Please give your thoughts.
>>>
>>> Regards,
>>> Praveen
>>>
>>>
>>> PKJ wrote:

 Hi Eric,

 Thanks for your response.
 Yes you are right! Am trying to place POJOs into Solr directly and  
 this is
 working fine.
 I want to search them based on the object properties, need to  
 organize
 them in a heirarchy but not by package names.

 Something like:
 /Repository
 |
 |_ Folder1
 |
 |_ POJO 1

 It must store the object in this hierarchy. I might be asking  
 which is not
 at all supported by Solr.
 Please give your valuable inputs.

 Regards,
 Praveen


 Eric Pugh-4 wrote:
>
> Are you trying to Java objects in Solr in order to be  
> searchable?  How
> about just dumping them as text using POJO <--> to text formats  
> such
> as JSON or Betwixt (http://commons.apache.org/betwixt/).
>
> Then you can just search on the package structure...
>
> ?q=com.abc.lucene.* to return everything under that structure?
>
> Eric
>
>
> On Mar 10, 2009, at 7:13 AM, Praveen_Kumar_J wrote:
>
>>
>> Someone please throw some light on this post.
>> Thanks in advance.
>>
>>
>> Praveen_Kumar_J wrote:
>>>
>>> Hi
>>>
>>> I just upload simple POJOs into Solr by creating custom types and
>>> dynamic
>>> fields in Solr schema as shown below,
>>> 
>>> ...
>>> >> sortMissingLast="true" omitNorms="true"/>
>>> 
>>> >> stored="true" multiValued="true"/>
>>> >> stored="true" multiValued="false"/>
>>> >> stored="false" multiValued="true"/>
>>> 
>>> But I need to organize these POJOs in a hierarchy which can be
>>> navigated
>>> easily (something like explorer).
>>> Am not sure whether this feature is supported by Solr. But still
>>> planning
>>> to implement it somehow (With the help of DB).
>>>
>>> /Root
>>> |
>>> |_ POJO Type1
>>> | |
>>> | |_POJO Type1_1
>>> |
>>> |_POJO Type2
>>>   |
>>>   |_POJO Type2_1
>>>
>>> I need to organize the POJOs as shown above.
>>> Is there any way to achieve this requirement??
>>>
>>> Regards,
>>> Praveen
>>>
>>
>> -- 
>> View this message in context:
>> http://www.nabble.com/Organizing-POJO%27s-in-a-heirarchy-in-Solr-tp22427900p22432121.html
>> Sent from the Solr - User mailing list archive at Nabble.com.
>>
>
> -
> Eric Pugh | Principal | OpenSource Connections, LLC |  
> 434.466.1467 |
> http://www.opensourceconnections.com
> Free/Busy: http://tinyurl.com/eric-cal
>
>
>
>
>
>


>>>
>>> -- 
>>> View this message in context:
>>> http://www.nabble.com/Organizing-POJO%27s-in-a-heirarchy-in-Solr-tp22427900p22454101.html
>>> Sent from the Solr - User mailing list archive at Nabble.com.
>>>
>>
>> -
>> Eric Pugh | Principal | OpenSource Connections, LLC | 434.466.1467 |
>> http://www.opensourceconnections.com
>> Free/Busy: http://tinyurl.com/eric-cal
>>
>>
>>
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Organizing-POJO%27s-in-a-heirarchy-in-Solr-tp22427900p22456524.html
Sent 

Re: Organizing POJO's in a heirarchy in Solr

2009-03-11 Thread Schley Andrew Kutz
I like the path idea, however, it does not allow you to perform  
tantamount joins on elements in the path. I am working on an idea that  
would effectively enable you to perform RDF style queries:


FIND a WHERE a.f1 > 300 AND a.b.f1 > 3 AND a.c.name == 'foo'

f1 is a field on 'a' where 'b' and 'c' are pointers on 'a' to other  
documents. Essentially this can be accomplished with facets since you  
don't have to retrieve the b and c documents, only whether or not the  
set is empty. I am considering doing this as a response writer or a  
separate web service, but ideas are welcome.


--
-a

"Ideally, a code library must be immediately usable by naive  
developers, easily customized by more sophisticated developers, and  
readily extensible by experts." -- L. Stein


On Mar 11, 2009, at 9:35 AM, PKJ wrote:




Pretty good idea David.
Yeah I understand that Solr has not build for such purposes. It is a  
good

search server.
Will incorporated your idea to store the path as a property and  
search.
Thanks again. Please post if you see any improvements for this  
requirement

in near future.

Regards,
Praveen


David Smiley @MITRE.org wrote:


Solr could still work for you Praveen.
Consider a schema with a field named "parentPath" that is not  
tokenized.
It stores the path to the folder containing the current document  
but does

not have the document's name in it.  In your example, this would be
"/Repository/Folder1/".  The document's name would be stored in  
another
field. This system is not perfect but it meets the only requirement  
you've

outlined.

~ David Smiley


On 3/11/09 8:47 AM, "Eric Pugh"   
wrote:


Solr really isn't organized for tree structures of data.  I think you
might do better using a database with a tree structure.

pojo would be a table of pojo's serialized out.  And the parent_id
could point to another structure that builds the tree.  Can you flesh
out your use case more of why they need to be in a tree structure.

Eric



On Mar 11, 2009, at 8:29 AM, PKJ wrote:




Is there anyone who have any idea solve this issue?
Please give your thoughts.

Regards,
Praveen


PKJ wrote:


Hi Eric,

Thanks for your response.
Yes you are right! Am trying to place POJOs into Solr directly and
this is
working fine.
I want to search them based on the object properties, need to
organize
them in a heirarchy but not by package names.

Something like:
/Repository
|
|_ Folder1
|
|_ POJO 1

It must store the object in this hierarchy. I might be asking which
is not
at all supported by Solr.
Please give your valuable inputs.

Regards,
Praveen


Eric Pugh-4 wrote:


Are you trying to Java objects in Solr in order to be searchable?
How
about just dumping them as text using POJO <--> to text formats  
such

as JSON or Betwixt (http://commons.apache.org/betwixt/).

Then you can just search on the package structure...

?q=com.abc.lucene.* to return everything under that structure?

Eric


On Mar 10, 2009, at 7:13 AM, Praveen_Kumar_J wrote:



Someone please throw some light on this post.
Thanks in advance.


Praveen_Kumar_J wrote:


Hi

I just upload simple POJOs into Solr by creating custom types  
and

dynamic
fields in Solr schema as shown below,

...



indexed="true"

stored="true" multiValued="false"/>
indexed="true"

stored="false" multiValued="true"/>

But I need to organize these POJOs in a hierarchy which can be
navigated
easily (something like explorer).
Am not sure whether this feature is supported by Solr. But still
planning
to implement it somehow (With the help of DB).

/Root
|
|_ POJO Type1
| |
| |_POJO Type1_1
|
|_POJO Type2
  |
  |_POJO Type2_1

I need to organize the POJOs as shown above.
Is there any way to achieve this requirement??

Regards,
Praveen



--
View this message in context:
http://www.nabble.com/Organizing-POJO%27s-in-a-heirarchy-in-Solr-tp22427900p22432121.html
Sent from the Solr - User mailing list archive at Nabble.com.



-
Eric Pugh | Principal | OpenSource Connections, LLC |  
434.466.1467 |

http://www.opensourceconnections.com
Free/Busy: http://tinyurl.com/eric-cal











--
View this message in context:
http://www.nabble.com/Organizing-POJO%27s-in-a-heirarchy-in-Solr-tp22427900p22454101.html
Sent from the Solr - User mailing list archive at Nabble.com.



-
Eric Pugh | Principal | OpenSource Connections, LLC | 434.466.1467 |
http://www.opensourceconnections.com
Free/Busy: http://tinyurl.com/eric-cal









--
View this message in context: 
http://www.nabble.com/Organizing-POJO%27s-in-a-heirarchy-in-Solr-tp22427900p22456430.html
Sent from the Solr - User mailing list archive at Nabble.com.





Re: Organizing POJO's in a heirarchy in Solr

2009-03-11 Thread PKJ


Pretty good idea David.
Yeah I understand that Solr has not build for such purposes. It is a good
search server.
Will incorporated your idea to store the path as a property and search.
Thanks again. Please post if you see any improvements for this requirement
in near future.

Regards,
Praveen


David Smiley @MITRE.org wrote:
> 
> Solr could still work for you Praveen.
> Consider a schema with a field named "parentPath" that is not tokenized. 
> It stores the path to the folder containing the current document but does
> not have the document's name in it.  In your example, this would be
> "/Repository/Folder1/".  The document's name would be stored in another
> field. This system is not perfect but it meets the only requirement you've
> outlined.
> 
> ~ David Smiley
> 
> 
> On 3/11/09 8:47 AM, "Eric Pugh"  wrote:
> 
> Solr really isn't organized for tree structures of data.  I think you
> might do better using a database with a tree structure.
> 
> pojo would be a table of pojo's serialized out.  And the parent_id
> could point to another structure that builds the tree.  Can you flesh
> out your use case more of why they need to be in a tree structure.
> 
> Eric
> 
> 
> 
> On Mar 11, 2009, at 8:29 AM, PKJ wrote:
> 
>>
>>
>> Is there anyone who have any idea solve this issue?
>> Please give your thoughts.
>>
>> Regards,
>> Praveen
>>
>>
>> PKJ wrote:
>>>
>>> Hi Eric,
>>>
>>> Thanks for your response.
>>> Yes you are right! Am trying to place POJOs into Solr directly and
>>> this is
>>> working fine.
>>> I want to search them based on the object properties, need to
>>> organize
>>> them in a heirarchy but not by package names.
>>>
>>> Something like:
>>> /Repository
>>>  |
>>>  |_ Folder1
>>>  |
>>>  |_ POJO 1
>>>
>>> It must store the object in this hierarchy. I might be asking which
>>> is not
>>> at all supported by Solr.
>>> Please give your valuable inputs.
>>>
>>> Regards,
>>> Praveen
>>>
>>>
>>> Eric Pugh-4 wrote:

 Are you trying to Java objects in Solr in order to be searchable?
 How
 about just dumping them as text using POJO <--> to text formats such
 as JSON or Betwixt (http://commons.apache.org/betwixt/).

 Then you can just search on the package structure...

 ?q=com.abc.lucene.* to return everything under that structure?

 Eric


 On Mar 10, 2009, at 7:13 AM, Praveen_Kumar_J wrote:

>
> Someone please throw some light on this post.
> Thanks in advance.
>
>
> Praveen_Kumar_J wrote:
>>
>> Hi
>>
>> I just upload simple POJOs into Solr by creating custom types and
>> dynamic
>> fields in Solr schema as shown below,
>> 
>> ...
>> > sortMissingLast="true" omitNorms="true"/>
>> 
>> > stored="true" multiValued="true"/>
>> > stored="true" multiValued="false"/>
>> > stored="false" multiValued="true"/>
>> 
>> But I need to organize these POJOs in a hierarchy which can be
>> navigated
>> easily (something like explorer).
>> Am not sure whether this feature is supported by Solr. But still
>> planning
>> to implement it somehow (With the help of DB).
>>
>> /Root
>>  |
>>  |_ POJO Type1
>>  | |
>>  | |_POJO Type1_1
>>  |
>>  |_POJO Type2
>>|
>>|_POJO Type2_1
>>
>> I need to organize the POJOs as shown above.
>> Is there any way to achieve this requirement??
>>
>> Regards,
>> Praveen
>>
>
> --
> View this message in context:
> http://www.nabble.com/Organizing-POJO%27s-in-a-heirarchy-in-Solr-tp22427900p22432121.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>

 -
 Eric Pugh | Principal | OpenSource Connections, LLC | 434.466.1467 |
 http://www.opensourceconnections.com
 Free/Busy: http://tinyurl.com/eric-cal






>>>
>>>
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Organizing-POJO%27s-in-a-heirarchy-in-Solr-tp22427900p22454101.html
>> Sent from the Solr - User mailing list archive at Nabble.com.
>>
> 
> -
> Eric Pugh | Principal | OpenSource Connections, LLC | 434.466.1467 |
> http://www.opensourceconnections.com
> Free/Busy: http://tinyurl.com/eric-cal
> 
> 
> 
> 
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Organizing-POJO%27s-in-a-heirarchy-in-Solr-tp22427900p22456430.html
Sent from the Solr - User mailing list archive at Nabble.com.



Re: Organizing POJO's in a heirarchy in Solr

2009-03-11 Thread PKJ


Thanks for your response Eric.
Actually the scenario is to use the Solr search server as a hierarchical
storage system also. Where we store objects/files in a hierarchy and do
searches on that. something like DB (for files) + Solr.
Here I am evaluating Solr with an knowledge management system.
So thought of storing in a hierarchy.

regards,
Praveen



Eric Pugh-4 wrote:
> 
> Solr really isn't organized for tree structures of data.  I think you  
> might do better using a database with a tree structure.
> 
> pojo would be a table of pojo's serialized out.  And the parent_id  
> could point to another structure that builds the tree.  Can you flesh  
> out your use case more of why they need to be in a tree structure.
> 
> Eric
> 
> 
> 
> On Mar 11, 2009, at 8:29 AM, PKJ wrote:
> 
>>
>>
>> Is there anyone who have any idea solve this issue?
>> Please give your thoughts.
>>
>> Regards,
>> Praveen
>>
>>
>> PKJ wrote:
>>>
>>> Hi Eric,
>>>
>>> Thanks for your response.
>>> Yes you are right! Am trying to place POJOs into Solr directly and  
>>> this is
>>> working fine.
>>> I want to search them based on the object properties, need to  
>>> organize
>>> them in a heirarchy but not by package names.
>>>
>>> Something like:
>>> /Repository
>>>  |
>>>  |_ Folder1
>>>  |
>>>  |_ POJO 1
>>>
>>> It must store the object in this hierarchy. I might be asking which  
>>> is not
>>> at all supported by Solr.
>>> Please give your valuable inputs.
>>>
>>> Regards,
>>> Praveen
>>>
>>>
>>> Eric Pugh-4 wrote:

 Are you trying to Java objects in Solr in order to be searchable?   
 How
 about just dumping them as text using POJO <--> to text formats such
 as JSON or Betwixt (http://commons.apache.org/betwixt/).

 Then you can just search on the package structure...

 ?q=com.abc.lucene.* to return everything under that structure?

 Eric


 On Mar 10, 2009, at 7:13 AM, Praveen_Kumar_J wrote:

>
> Someone please throw some light on this post.
> Thanks in advance.
>
>
> Praveen_Kumar_J wrote:
>>
>> Hi
>>
>> I just upload simple POJOs into Solr by creating custom types and
>> dynamic
>> fields in Solr schema as shown below,
>> 
>> ...
>> > sortMissingLast="true" omitNorms="true"/>
>> 
>> > stored="true" multiValued="true"/>
>> > stored="true" multiValued="false"/>
>> > stored="false" multiValued="true"/>
>> 
>> But I need to organize these POJOs in a hierarchy which can be
>> navigated
>> easily (something like explorer).
>> Am not sure whether this feature is supported by Solr. But still
>> planning
>> to implement it somehow (With the help of DB).
>>
>> /Root
>>  |
>>  |_ POJO Type1
>>  | |
>>  | |_POJO Type1_1
>>  |
>>  |_POJO Type2
>>|
>>|_POJO Type2_1
>>
>> I need to organize the POJOs as shown above.
>> Is there any way to achieve this requirement??
>>
>> Regards,
>> Praveen
>>
>
> -- 
> View this message in context:
> http://www.nabble.com/Organizing-POJO%27s-in-a-heirarchy-in-Solr-tp22427900p22432121.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>

 -
 Eric Pugh | Principal | OpenSource Connections, LLC | 434.466.1467 |
 http://www.opensourceconnections.com
 Free/Busy: http://tinyurl.com/eric-cal






>>>
>>>
>>
>> -- 
>> View this message in context:
>> http://www.nabble.com/Organizing-POJO%27s-in-a-heirarchy-in-Solr-tp22427900p22454101.html
>> Sent from the Solr - User mailing list archive at Nabble.com.
>>
> 
> -
> Eric Pugh | Principal | OpenSource Connections, LLC | 434.466.1467 |
> http://www.opensourceconnections.com
> Free/Busy: http://tinyurl.com/eric-cal
> 
> 
> 
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Organizing-POJO%27s-in-a-heirarchy-in-Solr-tp22427900p22456314.html
Sent from the Solr - User mailing list archive at Nabble.com.



Re: Combination of EmbeddedSolrServer and CommonHttpSolrServer

2009-03-11 Thread Shalin Shekhar Mangar
On Wed, Mar 11, 2009 at 6:37 PM, Kulkarni, Ajit Kamalakar <
ajkulka...@ptc.com> wrote:

>
> If we index the documents using CommonsHttpSolrServer and search using
> the same, we get the updated results
>
> That means we can search the latest added document as well even if it is
> not committed to the file system
>

That is not possible. Without calling commit, new documents will not be
visible to a searcher.


> So it looks like there is some kind of cache that is used by both index
> and search logic inside solr for a given SolrServer components (e. g.
> CommonsHttpSolrServer, EmbeddedSolrServer)
>

Indexing does not create any cache. The caching is done only by the
searcher. The old searcher/cache is discarded and a new searcher/cache is
created when you call commit. Setting autoWarmCount on the caches in
solrconfig.xml makes the new searcher run some of the most recently used
queries on the old searcher to warm up the new cache.

Calling commit on the SolrServer to synch with the index data may not be
> good option as I suppose it to be expensive operation.
>

It is the only option. But you may be able to make the operation cheaper by
tweaking the autowarmCount on the caches (this is specified in
solrconfig.xml). However, caches are important for good search performance.
Depending on your search traffic, you'll need to find a sweet spot.


> The cache and hard disk data synchronization should be independent of
> the SolrServer instances managed by Solr Web Application inside tomcat.
>

SolrServer is not really a server in itself. It is (a pointer to?) a server
being used by a solrj client. The CommonsHttpSolrServer refers to a remote
server url and makes calls through HTTP. SolrCore is the internal class
which manages the state of the server.

A SolrCore is created by the solr webapp. When you create another SolrCore
for use by EmbeddedSolrServer, they do not know about each other. Therefore
you need to notify it if you change the index through another core.


> The issue still will be that EmbeddedSolrServer may directly access hard
> index data as it may bypass the Solr web app totally
>
> I am embedding tomcat in my RMI server.
>
> The RMI Server is going to use EmbeddedSolrServer and it also hosts the
> Solr WebApp inside its tomcat instance
>
> So I guess I should be able to manage a singleton cache  that is given
> to both, CommonsHttpSolrServer related components managed inside Solr
> WebApp and EmbeddedSolrServer components
>
>
Why have two of them at all? Is the solr deployed inside tomcat serves HTTP
requests from external clients without going through your RMI server? You
can simplify things by keeping it either in tomcat or in embedded mode.

Hope that helps.

-- 
Regards,
Shalin Shekhar Mangar.


RE: Solr search with Auto Spellchecker

2009-03-11 Thread Narayanan, Karthikeyan
Shalin,
Thanks for info... 


Thanks.
  
Karthik


-Original Message-
From: Shalin Shekhar Mangar [mailto:shalinman...@gmail.com] 
Sent: Wednesday, March 11, 2009 9:33 AM
To: solr-user@lucene.apache.org
Subject: Re: Solr search with Auto Spellchecker

On Wed, Mar 11, 2009 at 7:00 PM, Narayanan, Karthikeyan <
karthikeyan.naraya...@gs.com> wrote:

> Is it possible get the search results from the spell corrected word in
a
> single solr search query?.  Like I search for the word "globl" and the
> correct spelling is "global".. The query should return results
matching
> with the word "global".  Would appreciate any ideas..
>
>
No, you'll need to make two queries.

-- 
Regards,
Shalin Shekhar Mangar.


Re: Tomcat holding deleted snapshots until it's restarted

2009-03-11 Thread Shalin Shekhar Mangar
On Wed, Mar 11, 2009 at 3:07 PM, Marc Sturlese wrote:

>
> I am using the scripts of Collection Distribution.
> The problem is just happening in the master, not in the slaves.
> Do you have any clue? I am fighting against this since a few days ago...
> Thanks in advance
>
> No Marc, I'm clueless too. I haven't seen this behavior before. Which OS
and filesystem are you using? Perhaps someone else may have more insight.

-- 
Regards,
Shalin Shekhar Mangar.


Re: Solr search with Auto Spellchecker

2009-03-11 Thread Shalin Shekhar Mangar
On Wed, Mar 11, 2009 at 7:00 PM, Narayanan, Karthikeyan <
karthikeyan.naraya...@gs.com> wrote:

> Is it possible get the search results from the spell corrected word in a
> single solr search query?.  Like I search for the word "globl" and the
> correct spelling is "global".. The query should return results matching
> with the word "global".  Would appreciate any ideas..
>
>
No, you'll need to make two queries.

-- 
Regards,
Shalin Shekhar Mangar.


RE: Solr search with Auto Spellchecker

2009-03-11 Thread Narayanan, Karthikeyan
Is it possible get the search results from the spell corrected word in a
single solr search query?.  Like I search for the word "globl" and the
correct spelling is "global".. The query should return results matching
with the word "global".  Would appreciate any ideas.. 


Thanks.
Karthik



> _ 
> From: Narayanan, Karthikeyan  
> Sent: Tuesday, March 10, 2009 9:43 AM
> To:   'solr-user@lucene.apache.org'
> Subject:  Solr search with Auto Spellchecker 
> 
> 
>   Hello All,
>  Am trying to implement spell checker in
> the Solr search.  I am able to get the suggestions by passing
> 'spellcheck=true'.  But I want the search results  from the spell
> corrected word.
>   How do I achieve that?.  Thanks in Advance.
> 
>   Thanks.
>   Karthik
> 
> 


Re: Organizing POJO's in a heirarchy in Solr

2009-03-11 Thread Erik Hatcher

Good thinking David!   :)

Or even a tokenized field... tokenized by path segments, so the  
document we're talking about could have a path field with the terms: / 
Repository and /Repository/Folder1 - that way the queries can be made  
simpler (and perhaps faster).


Erik


On Mar 11, 2009, at 9:10 AM, Smiley, David W. wrote:


Solr could still work for you Praveen.
Consider a schema with a field named "parentPath" that is not  
tokenized.  It stores the path to the folder containing the current  
document but does not have the document's name in it.  In your  
example, this would be "/Repository/Folder1/".  The document's name  
would be stored in another field. This system is not perfect but it  
meets the only requirement you've outlined.


~ David Smiley


On 3/11/09 8:47 AM, "Eric Pugh"   
wrote:


Solr really isn't organized for tree structures of data.  I think you
might do better using a database with a tree structure.

pojo would be a table of pojo's serialized out.  And the parent_id
could point to another structure that builds the tree.  Can you flesh
out your use case more of why they need to be in a tree structure.

Eric



On Mar 11, 2009, at 8:29 AM, PKJ wrote:




Is there anyone who have any idea solve this issue?
Please give your thoughts.

Regards,
Praveen


PKJ wrote:


Hi Eric,

Thanks for your response.
Yes you are right! Am trying to place POJOs into Solr directly and
this is
working fine.
I want to search them based on the object properties, need to
organize
them in a heirarchy but not by package names.

Something like:
/Repository
|
|_ Folder1
|
|_ POJO 1

It must store the object in this hierarchy. I might be asking which
is not
at all supported by Solr.
Please give your valuable inputs.

Regards,
Praveen


Eric Pugh-4 wrote:


Are you trying to Java objects in Solr in order to be searchable?
How
about just dumping them as text using POJO <--> to text formats  
such

as JSON or Betwixt (http://commons.apache.org/betwixt/).

Then you can just search on the package structure...

?q=com.abc.lucene.* to return everything under that structure?

Eric


On Mar 10, 2009, at 7:13 AM, Praveen_Kumar_J wrote:



Someone please throw some light on this post.
Thanks in advance.


Praveen_Kumar_J wrote:


Hi

I just upload simple POJOs into Solr by creating custom types and
dynamic
fields in Solr schema as shown below,

...






But I need to organize these POJOs in a hierarchy which can be
navigated
easily (something like explorer).
Am not sure whether this feature is supported by Solr. But still
planning
to implement it somehow (With the help of DB).

/Root
|
|_ POJO Type1
| |
| |_POJO Type1_1
|
|_POJO Type2
  |
  |_POJO Type2_1

I need to organize the POJOs as shown above.
Is there any way to achieve this requirement??

Regards,
Praveen



--
View this message in context:
http://www.nabble.com/Organizing-POJO%27s-in-a-heirarchy-in-Solr-tp22427900p22432121.html
Sent from the Solr - User mailing list archive at Nabble.com.



-
Eric Pugh | Principal | OpenSource Connections, LLC |  
434.466.1467 |

http://www.opensourceconnections.com
Free/Busy: http://tinyurl.com/eric-cal











--
View this message in context: 
http://www.nabble.com/Organizing-POJO%27s-in-a-heirarchy-in-Solr-tp22427900p22454101.html
Sent from the Solr - User mailing list archive at Nabble.com.



-
Eric Pugh | Principal | OpenSource Connections, LLC | 434.466.1467 | 
http://www.opensourceconnections.com
Free/Busy: http://tinyurl.com/eric-cal









Re: Organizing POJO's in a heirarchy in Solr

2009-03-11 Thread Smiley, David W.
Solr could still work for you Praveen.
Consider a schema with a field named "parentPath" that is not tokenized.  It 
stores the path to the folder containing the current document but does not have 
the document's name in it.  In your example, this would be 
"/Repository/Folder1/".  The document's name would be stored in another field. 
This system is not perfect but it meets the only requirement you've outlined.

~ David Smiley


On 3/11/09 8:47 AM, "Eric Pugh"  wrote:

Solr really isn't organized for tree structures of data.  I think you
might do better using a database with a tree structure.

pojo would be a table of pojo's serialized out.  And the parent_id
could point to another structure that builds the tree.  Can you flesh
out your use case more of why they need to be in a tree structure.

Eric



On Mar 11, 2009, at 8:29 AM, PKJ wrote:

>
>
> Is there anyone who have any idea solve this issue?
> Please give your thoughts.
>
> Regards,
> Praveen
>
>
> PKJ wrote:
>>
>> Hi Eric,
>>
>> Thanks for your response.
>> Yes you are right! Am trying to place POJOs into Solr directly and
>> this is
>> working fine.
>> I want to search them based on the object properties, need to
>> organize
>> them in a heirarchy but not by package names.
>>
>> Something like:
>> /Repository
>>  |
>>  |_ Folder1
>>  |
>>  |_ POJO 1
>>
>> It must store the object in this hierarchy. I might be asking which
>> is not
>> at all supported by Solr.
>> Please give your valuable inputs.
>>
>> Regards,
>> Praveen
>>
>>
>> Eric Pugh-4 wrote:
>>>
>>> Are you trying to Java objects in Solr in order to be searchable?
>>> How
>>> about just dumping them as text using POJO <--> to text formats such
>>> as JSON or Betwixt (http://commons.apache.org/betwixt/).
>>>
>>> Then you can just search on the package structure...
>>>
>>> ?q=com.abc.lucene.* to return everything under that structure?
>>>
>>> Eric
>>>
>>>
>>> On Mar 10, 2009, at 7:13 AM, Praveen_Kumar_J wrote:
>>>

 Someone please throw some light on this post.
 Thanks in advance.


 Praveen_Kumar_J wrote:
>
> Hi
>
> I just upload simple POJOs into Solr by creating custom types and
> dynamic
> fields in Solr schema as shown below,
> 
> ...
>  sortMissingLast="true" omitNorms="true"/>
> 
>  stored="true" multiValued="true"/>
>  stored="true" multiValued="false"/>
>  stored="false" multiValued="true"/>
> 
> But I need to organize these POJOs in a hierarchy which can be
> navigated
> easily (something like explorer).
> Am not sure whether this feature is supported by Solr. But still
> planning
> to implement it somehow (With the help of DB).
>
> /Root
>  |
>  |_ POJO Type1
>  | |
>  | |_POJO Type1_1
>  |
>  |_POJO Type2
>|
>|_POJO Type2_1
>
> I need to organize the POJOs as shown above.
> Is there any way to achieve this requirement??
>
> Regards,
> Praveen
>

 --
 View this message in context:
 http://www.nabble.com/Organizing-POJO%27s-in-a-heirarchy-in-Solr-tp22427900p22432121.html
 Sent from the Solr - User mailing list archive at Nabble.com.

>>>
>>> -
>>> Eric Pugh | Principal | OpenSource Connections, LLC | 434.466.1467 |
>>> http://www.opensourceconnections.com
>>> Free/Busy: http://tinyurl.com/eric-cal
>>>
>>>
>>>
>>>
>>>
>>>
>>
>>
>
> --
> View this message in context: 
> http://www.nabble.com/Organizing-POJO%27s-in-a-heirarchy-in-Solr-tp22427900p22454101.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>

-
Eric Pugh | Principal | OpenSource Connections, LLC | 434.466.1467 | 
http://www.opensourceconnections.com
Free/Busy: http://tinyurl.com/eric-cal







RE: Combination of EmbeddedSolrServer and CommonHttpSolrServer

2009-03-11 Thread Kulkarni, Ajit Kamalakar
Ryan,

If we index the documents using CommonsHttpSolrServer and search using
the same, we get the updated results

That means we can search the latest added document as well even if it is
not committed to the file system 

 

So it looks like there is some kind of cache that is used by both index
and search logic inside solr for a given SolrServer components (e. g.
CommonsHttpSolrServer, EmbeddedSolrServer)

 

Is there any way to configure that same cache  will be used by the
component that respond to HTTP request through CommonsHttpSolrServer and
the component used by EmbeddedSolrServer?

 

I don't see any reason why searcher and/or indexer for a given
SolrServer need to maintain exclusive cache

 

Calling commit on the SolrServer to synch with the index data may not be
good option as I suppose it to be expensive operation.

 

The cache and hard disk data synchronization should be independent of
the SolrServer instances managed by Solr Web Application inside tomcat.

 

The issue still will be that EmbeddedSolrServer may directly access hard
index data as it may bypass the Solr web app totally

 

I am embedding tomcat in my RMI server. 

The RMI Server is going to use EmbeddedSolrServer and it also hosts the
Solr WebApp inside its tomcat instance

 

So I guess I should be able to manage a singleton cache  that is given
to both, CommonsHttpSolrServer related components managed inside Solr
WebApp and EmbeddedSolrServer components

 

Please comment.

 

Thanks,

Ajit

 

-Original Message-
From: Ryan McKinley [mailto:ryan...@gmail.com] 
Sent: Monday, February 09, 2009 9:23 PM
To: solr-user@lucene.apache.org
Subject: Re: Combination of EmbeddedSolrServer and CommonHttpSolrServer

 

> 

 

Keep in mind that the way lucene/solr work is that the results are  

constant from when you open the searcher.  If new documents are added  

(without re-opening the searcher) they will not be seen.

 

  tells solr to re-open the index and see the changes.

 

 

> 1. Does this mean that committing on the indexing (Embedded) server  

> does

> not reflect the document changes when we fire a search through another

> (HTTP) server?

 

correct.  The HTTP server would still be open from before the indexing  

happened.

 

> 

> 2. What happens to the commit fired on the indexing server? Can I  

> remove

> that and just commit on the "read only" server?

 

Call commit on the indexing server, then the read only server then you  

can delete the Embedded server

 

 

> 

> 3. Do we have to fire a Commit (on the HTTP server) before we try to

> search for a document?

 

Yes -- calling commit will re-open the index and reflect any changes  

to it

 

 

> 

> 4. Can we make any setting (perhaps using auto-commit) on the HTTP

> server to avoid this scenario?

> 

 

Not really -- the HTTP core has no idea what is happening on the other  

core.

 

 

ryan



Re: Organizing POJO's in a heirarchy in Solr

2009-03-11 Thread Erik Hatcher


On Mar 11, 2009, at 8:47 AM, Eric Pugh wrote:
Solr really isn't organized for tree structures of data.  I think  
you might do better using a database with a tree structure.


That's not a very fair statement.  Sure, documents in Solr/Lucene are  
simply composed of a flat list of fields, but one can store a path- 
like representation in a field and search within hierarchies.  For  
example, indexing a "string" path field with values such as:


   path: /Repository/Folder1/POJO1

One could query for /Repository/* to get all documents (err, objects)  
from that tree downward, and so on for any sub or complete path.


The main thing to look at when figuring out how to squash a domain  
into a Lucene index is what exactly do you need on the querying side  
of things, rather than looking at it from a domain model and seeing  
how to represent relationships and hierarchy from that perspective.


Erik





pojo would be a table of pojo's serialized out.  And the parent_id  
could point to another structure that builds the tree.  Can you  
flesh out your use case more of why they need to be in a tree  
structure.


Eric



On Mar 11, 2009, at 8:29 AM, PKJ wrote:




Is there anyone who have any idea solve this issue?
Please give your thoughts.

Regards,
Praveen


PKJ wrote:


Hi Eric,

Thanks for your response.
Yes you are right! Am trying to place POJOs into Solr directly and  
this is

working fine.
I want to search them based on the object properties, need to  
organize

them in a heirarchy but not by package names.

Something like:
/Repository
|
|_ Folder1
|
|_ POJO 1

It must store the object in this hierarchy. I might be asking  
which is not

at all supported by Solr.
Please give your valuable inputs.

Regards,
Praveen


Eric Pugh-4 wrote:


Are you trying to Java objects in Solr in order to be  
searchable?  How
about just dumping them as text using POJO <--> to text formats  
such

as JSON or Betwixt (http://commons.apache.org/betwixt/).

Then you can just search on the package structure...

?q=com.abc.lucene.* to return everything under that structure?

Eric


On Mar 10, 2009, at 7:13 AM, Praveen_Kumar_J wrote:



Someone please throw some light on this post.
Thanks in advance.


Praveen_Kumar_J wrote:


Hi

I just upload simple POJOs into Solr by creating custom types and
dynamic
fields in Solr schema as shown below,

...






But I need to organize these POJOs in a hierarchy which can be
navigated
easily (something like explorer).
Am not sure whether this feature is supported by Solr. But still
planning
to implement it somehow (With the help of DB).

/Root
|
|_ POJO Type1
| |
| |_POJO Type1_1
|
|_POJO Type2
  |
  |_POJO Type2_1

I need to organize the POJOs as shown above.
Is there any way to achieve this requirement??

Regards,
Praveen



--
View this message in context:
http://www.nabble.com/Organizing-POJO%27s-in-a-heirarchy-in-Solr-tp22427900p22432121.html
Sent from the Solr - User mailing list archive at Nabble.com.



-
Eric Pugh | Principal | OpenSource Connections, LLC |  
434.466.1467 |

http://www.opensourceconnections.com
Free/Busy: http://tinyurl.com/eric-cal











--
View this message in context: 
http://www.nabble.com/Organizing-POJO%27s-in-a-heirarchy-in-Solr-tp22427900p22454101.html
Sent from the Solr - User mailing list archive at Nabble.com.



-
Eric Pugh | Principal | OpenSource Connections, LLC | 434.466.1467 | 
http://www.opensourceconnections.com
Free/Busy: http://tinyurl.com/eric-cal







Re: Organizing POJO's in a heirarchy in Solr

2009-03-11 Thread Eric Pugh
Solr really isn't organized for tree structures of data.  I think you  
might do better using a database with a tree structure.


pojo would be a table of pojo's serialized out.  And the parent_id  
could point to another structure that builds the tree.  Can you flesh  
out your use case more of why they need to be in a tree structure.


Eric



On Mar 11, 2009, at 8:29 AM, PKJ wrote:




Is there anyone who have any idea solve this issue?
Please give your thoughts.

Regards,
Praveen


PKJ wrote:


Hi Eric,

Thanks for your response.
Yes you are right! Am trying to place POJOs into Solr directly and  
this is

working fine.
I want to search them based on the object properties, need to  
organize

them in a heirarchy but not by package names.

Something like:
/Repository
 |
 |_ Folder1
 |
 |_ POJO 1

It must store the object in this hierarchy. I might be asking which  
is not

at all supported by Solr.
Please give your valuable inputs.

Regards,
Praveen


Eric Pugh-4 wrote:


Are you trying to Java objects in Solr in order to be searchable?   
How

about just dumping them as text using POJO <--> to text formats such
as JSON or Betwixt (http://commons.apache.org/betwixt/).

Then you can just search on the package structure...

?q=com.abc.lucene.* to return everything under that structure?

Eric


On Mar 10, 2009, at 7:13 AM, Praveen_Kumar_J wrote:



Someone please throw some light on this post.
Thanks in advance.


Praveen_Kumar_J wrote:


Hi

I just upload simple POJOs into Solr by creating custom types and
dynamic
fields in Solr schema as shown below,

...






But I need to organize these POJOs in a hierarchy which can be
navigated
easily (something like explorer).
Am not sure whether this feature is supported by Solr. But still
planning
to implement it somehow (With the help of DB).

/Root
 |
 |_ POJO Type1
 | |
 | |_POJO Type1_1
 |
 |_POJO Type2
   |
   |_POJO Type2_1

I need to organize the POJOs as shown above.
Is there any way to achieve this requirement??

Regards,
Praveen



--
View this message in context:
http://www.nabble.com/Organizing-POJO%27s-in-a-heirarchy-in-Solr-tp22427900p22432121.html
Sent from the Solr - User mailing list archive at Nabble.com.



-
Eric Pugh | Principal | OpenSource Connections, LLC | 434.466.1467 |
http://www.opensourceconnections.com
Free/Busy: http://tinyurl.com/eric-cal











--
View this message in context: 
http://www.nabble.com/Organizing-POJO%27s-in-a-heirarchy-in-Solr-tp22427900p22454101.html
Sent from the Solr - User mailing list archive at Nabble.com.



-
Eric Pugh | Principal | OpenSource Connections, LLC | 434.466.1467 | 
http://www.opensourceconnections.com
Free/Busy: http://tinyurl.com/eric-cal






Re: Organizing POJO's in a heirarchy in Solr

2009-03-11 Thread PKJ


Is there anyone who have any idea solve this issue?
Please give your thoughts.

Regards,
Praveen


PKJ wrote:
> 
> Hi Eric,
> 
> Thanks for your response.
> Yes you are right! Am trying to place POJOs into Solr directly and this is
> working fine.
> I want to search them based on the object properties, need to organize
> them in a heirarchy but not by package names.
> 
> Something like:
> /Repository
>   |
>   |_ Folder1
>   |
>   |_ POJO 1
> 
> It must store the object in this hierarchy. I might be asking which is not
> at all supported by Solr.
> Please give your valuable inputs.
> 
> Regards,
> Praveen
> 
> 
> Eric Pugh-4 wrote:
>> 
>> Are you trying to Java objects in Solr in order to be searchable?  How  
>> about just dumping them as text using POJO <--> to text formats such  
>> as JSON or Betwixt (http://commons.apache.org/betwixt/).
>> 
>> Then you can just search on the package structure...
>> 
>> ?q=com.abc.lucene.* to return everything under that structure?
>> 
>> Eric
>> 
>> 
>> On Mar 10, 2009, at 7:13 AM, Praveen_Kumar_J wrote:
>> 
>>>
>>> Someone please throw some light on this post.
>>> Thanks in advance.
>>>
>>>
>>> Praveen_Kumar_J wrote:

 Hi

 I just upload simple POJOs into Solr by creating custom types and  
 dynamic
 fields in Solr schema as shown below,
 
 ...
 >>> sortMissingLast="true" omitNorms="true"/>
 
 >>> stored="true" multiValued="true"/>
 >>> stored="true" multiValued="false"/>
 >>> stored="false" multiValued="true"/>
 
 But I need to organize these POJOs in a hierarchy which can be  
 navigated
 easily (something like explorer).
 Am not sure whether this feature is supported by Solr. But still  
 planning
 to implement it somehow (With the help of DB).

 /Root
   |
   |_ POJO Type1
   | |
   | |_POJO Type1_1
   |
   |_POJO Type2
 |
 |_POJO Type2_1

 I need to organize the POJOs as shown above.
 Is there any way to achieve this requirement??

 Regards,
 Praveen

>>>
>>> -- 
>>> View this message in context:
>>> http://www.nabble.com/Organizing-POJO%27s-in-a-heirarchy-in-Solr-tp22427900p22432121.html
>>> Sent from the Solr - User mailing list archive at Nabble.com.
>>>
>> 
>> -
>> Eric Pugh | Principal | OpenSource Connections, LLC | 434.466.1467 |
>> http://www.opensourceconnections.com
>> Free/Busy: http://tinyurl.com/eric-cal
>> 
>> 
>> 
>> 
>> 
>> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Organizing-POJO%27s-in-a-heirarchy-in-Solr-tp22427900p22454101.html
Sent from the Solr - User mailing list archive at Nabble.com.



Re: Compound word search (maybe DisMaxQueryPaser problem)

2009-03-11 Thread Tobias Dittrich
Hmmm was my mail so weird or my question so stupid ... or is 
there simply noone with an answer? Not even a hint? :(


Tobias Dittrich schrieb:

Hi all,

I know there are a lot of topics about compound word search already but 
I haven't found anything for my specific problem yet. So if this is 
already answered (which would be nice :)) then any hints or search 
phrases for the mail archive would be apreciated.


Bascially I want users to be able to search my index for compound words 
that are not really compounds but merely terms that can be written in 
several ways.


For example I have the categories "usb" and "cable" in my index and I 
want the user to be able to search for "usbcable" or "usb-cable" etc. 
Also there is "bluetooth" in the index and I want the search for "blue 
tooth" to return the corresponding documents.


My approach is to use ShingleFilterFactory followed by 
WordDelimiterFilterFactory to index all possible combinations of words 
and get rid of intra-word delimiters. This nicely covers the first part 
of my requirements since the terms "usb" and "cable" somewhere along the 
process get concatenated and "usbcable" is in the index.


Now I also want use this on the query side, so the user input "blue 
tooth" (not as phrase) would become "bluetooth" for this field and 
produce a hit. But this never happens since with the DisMax Searcher the 
parser produces a query like this:


((category:blue | name:blue)~0.1 (category:tooth | name:tooth)~0.1)

And the filters and analysers for this field never get to see the whole 
user query and cannot perform their shingle and delimiter tasks :(


So my question now is: how can I get this working? Is there a preferable 
way to deal with this compound word problem? Is there another query 
parser that already does the trick?


Or would it make sense to write my own query parser that passes the user 
query "as is" to the several fields?


Any hints on this are welcome.

Thanks in advance
Tobias



--
Tobias Dittrich
- Leiter Internet-Entwicklung -
_
WAVE Computersysteme GmbH

Philipp-Reis-Str. 9
35440 Linden

Geschäftsführer: Carsten Kellmann
Registergericht Gießen HRB 1823

Fon: +49 (0) 6403 / 9050 6001
Fax: +49 (0) 6403 / 9050 5089
mailto:dittr...@wave-computer.de
http://www.wave-computer.de



Re: Solr 1.3; Data Import w/ Dynamic Fields

2009-03-11 Thread Shalin Shekhar Mangar
On Wed, Mar 11, 2009 at 4:01 PM, Noble Paul നോബിള്‍ नोब्ळ् <
noble.p...@gmail.com> wrote:

> I guess you can take the trunk and comment out the contents of
> SolrWriter#rollback() and it should work with Solr1.3
>
>
I agree. Rollback is the only feature which depends on enhancements in
Solr/Lucene libraries. So if you remove this feature, everything else should
work fine with 1.3

-- 
Regards,
Shalin Shekhar Mangar.


Re: Solr 1.3; Data Import w/ Dynamic Fields

2009-03-11 Thread Noble Paul നോബിള്‍ नोब्ळ्
I guess you can take the trunk and comment out the contents of
SolrWriter#rollback() and it should work with Solr1.3

On Wed, Mar 11, 2009 at 3:37 PM, Wesley Small  wrote:
> Thanks for the feedback Shalin.  I will investigate the backport of this 1.4
> fix into 1.3.    Do you know of any other subsequent patches related to the
> data import and dynamic fields that I also should located and backport as
> well?  I just ask if you happen to have this information handy.
>
> I am reaching here, but I would like your opinion.  Do you believe it is
> conceivable at all port the entire data import functionality from the latest
> 1.4-dev nightly build and manually merge this with the stable 1.3 release?
> On 3/11/09 5:26 AM, "Shalin Shekhar Mangar"  wrote:
>
>> On Wed, Mar 11, 2009 at 2:55 PM, Shalin Shekhar Mangar <
>> shalinman...@gmail.com> wrote:
>>
>>> > On Wed, Mar 11, 2009 at 2:28 PM, Wesley Small
>>> wrote:
>>> >
 >> Good morning,
 >>
 >> I reviewed a Solr Patch-742, which corrects an issue with the data 
 >> import
 >> process properly ingesting/commiting (solr add xml) document with 
 >> dynamic
 >> fields.
 >>
 >> Is this fix available for Solr 1.3 or is there a known work around?
 >>
>>> >
>>> > Unfortunately, no. The fix is in trunk but the trunk DataImportHandler 
>>> > uses
>>> > a new rollback operation which is not supported by Solr 1.3 release.
>>> >
>>
>> However you should be able to backport the changes in SOLR-742 to Solr 1.3
>> code.
>>
>> --
>> Regards,
>> Shalin Shekhar Mangar.
>>
>
>



-- 
--Noble Paul


Re: Solr 1.3; Data Import w/ Dynamic Fields

2009-03-11 Thread Wesley Small
I attempted a backport of Patch-742 on Solr-1.3.  You can see the results
below with Hunk failures.

Is there specific  method to obtain a list of patches may that occurred
specific to the data import functionality prior to PATCH-742.  I suppose I
would need to ensure that these specific data import files
(DataImporter.java, DataConfig.java and DocBuilder.java) are at the correct
revision before applying PATCH-742.



-sh-3.1$ pwd
/home/smallwes/projects/solr/downloads/apache-solr-1.3.0

-sh-3.1$ patch -p 0 -i ../SOLR-742.patch --dry-run
patching file 
contrib/dataimporthandler/src/main/java/org/apache/solr/handler/dataimport/D
ataImporter.java
Hunk #1 FAILED at 95.
Hunk #2 FAILED at 112.
Hunk #3 FAILED at 123.
Hunk #4 succeeded at 189 (offset -5 lines).
Hunk #5 FAILED at 227.
4 out of 5 hunks FAILED -- saving rejects to file
contrib/dataimporthandler/src/main/java/org/apache/solr/handler/dataimport/D
ataImporter.java.rej
patching file 
contrib/dataimporthandler/src/main/java/org/apache/solr/handler/dataimport/D
ataConfig.java
Hunk #3 FAILED at 130.
Hunk #4 FAILED at 145.
Hunk #5 FAILED at 158.
3 out of 5 hunks FAILED -- saving rejects to file
contrib/dataimporthandler/src/main/java/org/apache/solr/handler/dataimport/D
ataConfig.java.rej
patching file 
contrib/dataimporthandler/src/main/java/org/apache/solr/handler/dataimport/D
ocBuilder.java
Hunk #1 FAILED at 17.
Hunk #2 FAILED at 331.
Hunk #3 FAILED at 368.
Hunk #4 FAILED at 402.
Hunk #5 succeeded at 580 (offset 1 line).
4 out of 5 hunks FAILED -- saving rejects to file
contrib/dataimporthandler/src/main/java/org/apache/solr/handler/dataimport/D
ocBuilder.java.rej



Regards,
Wesley.


On 3/11/09 6:07 AM, "Small, Wesley"  wrote:

> Thanks for the feedback Shalin.  I will investigate the backport of this 1.4
> fix into 1.3.Do you know of any other subsequent patches related to the
> data import and dynamic fields that I also should located and backport as
> well?  I just ask if you happen to have this information handy.
> 
> I am reaching here, but I would like your opinion.  Do you believe it is
> conceivable at all port the entire data import functionality from the latest
> 1.4-dev nightly build and manually merge this with the stable 1.3 release?
> On 3/11/09 5:26 AM, "Shalin Shekhar Mangar"  wrote:
> 
>> > On Wed, Mar 11, 2009 at 2:55 PM, Shalin Shekhar Mangar <
>> > shalinman...@gmail.com> wrote:
>> >
 >> > On Wed, Mar 11, 2009 at 2:28 PM, Wesley Small
>>> >> wrote:
 >> >
>> >>> >> Good morning,
>> >>> >>
>> >>> >> I reviewed a Solr Patch-742, which corrects an issue with the data
import
>> >>> >> process properly ingesting/commiting (solr add xml) document with
>> dynamic
>> >>> >> fields.
>> >>> >>
>> >>> >> Is this fix available for Solr 1.3 or is there a known work >>
around?
>> >>> >>
 >> >
 >> > Unfortunately, no. The fix is in trunk but the trunk DataImportHandler
uses
 >> > a new rollback operation which is not supported by Solr 1.3 release.
 >> >
>> >
>> > However you should be able to backport the changes in SOLR-742 to Solr 1.3
>> > code.
>> >
>> > --
>> > Regards,
>> > Shalin Shekhar Mangar.
>> >
> 
> 



Re: Custom path for solr lib and data folder

2009-03-11 Thread Erik Hatcher


On Mar 11, 2009, at 6:07 AM, con wrote:
But how can i redirect solr to a seperate lib directrory that is  
outside of

the solr.home

Is this possible in solr 1.3


I don't believe it is possible (but please correct me if I'm wrong).   
From SolrResourceLoader:


log.info("Solr home set to '" + this.instanceDir + "'");
this.classLoader = createClassLoader(new File(this.instanceDir +  
"lib/"), parent);


So only a lib/ under Solr home directory is used.  It would be a nice  
enhancement to Solr to have this more configurable, including a list  
of directories to use.


Erik



Re: Solr 1.3; Data Import w/ Dynamic Fields

2009-03-11 Thread Wesley Small
Thanks for the feedback Shalin.  I will investigate the backport of this 1.4
fix into 1.3.Do you know of any other subsequent patches related to the
data import and dynamic fields that I also should located and backport as
well?  I just ask if you happen to have this information handy.

I am reaching here, but I would like your opinion.  Do you believe it is
conceivable at all port the entire data import functionality from the latest
1.4-dev nightly build and manually merge this with the stable 1.3 release?
On 3/11/09 5:26 AM, "Shalin Shekhar Mangar"  wrote:

> On Wed, Mar 11, 2009 at 2:55 PM, Shalin Shekhar Mangar <
> shalinman...@gmail.com> wrote:
> 
>> > On Wed, Mar 11, 2009 at 2:28 PM, Wesley Small
>> wrote:
>> >
>>> >> Good morning,
>>> >>
>>> >> I reviewed a Solr Patch-742, which corrects an issue with the data import
>>> >> process properly ingesting/commiting (solr add xml) document with dynamic
>>> >> fields.
>>> >>
>>> >> Is this fix available for Solr 1.3 or is there a known work around?
>>> >>
>> >
>> > Unfortunately, no. The fix is in trunk but the trunk DataImportHandler uses
>> > a new rollback operation which is not supported by Solr 1.3 release.
>> >
> 
> However you should be able to backport the changes in SOLR-742 to Solr 1.3
> code.
> 
> --
> Regards,
> Shalin Shekhar Mangar.
> 



Re: Custom path for solr lib and data folder

2009-03-11 Thread con

Thanks Erik

That did the trick for data directory.

I gave the -DSOLR_DATA=''%SOLR_DATA%" in the jboss run.bat and then i am
using this variable in solrconfig.xml. This works fine

But how can i redirect solr to a seperate lib directrory that is outside of
the solr.home

Is this possible in solr 1.3

Thanks
con





Erik Hatcher wrote:
> 
> 
> On Mar 11, 2009, at 5:14 AM, con wrote:
>> But still it is not working
>>
>> I changed the data directory accordingly,
>> ${SOLR_DATA}
>>
>> But this is not working and is giving the following error:
>>
>> SEVERE: Error in  
>> solrconfig.xml:org.apache.solr.common.SolrException: No
>> system property or default value specified for SOLR_DATA
> 
> For this to work, you have to set a JVM system property when launching  
> Solr:
> 
>java -DSOLR_DATA= -jar start.jar
> 
>   Erik
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Custom-path-for-solr-lib-and-data-folder-tp22450530p22451986.html
Sent from the Solr - User mailing list archive at Nabble.com.



Re: SolrJ XML indexing

2009-03-11 Thread Paul Libbrecht

Erm... can it be you have several processes running on it?
I would start by a cleanup of it all and attempt a simple solr  
addition before the xml.


paul


Le 11-mars-09 à 10:16, Ashish P a écrit :



I added single in indexDefaults that made the  
error

before go away but now I am getting following error :

Mar 11, 2009 6:12:56 PM org.apache.solr.common.SolrException log
SEVERE: java.io.IOException: Cannot overwrite:
C:\dw-solr\solr\data\index\_1o.fdt
	at  
org.apache.lucene.store.FSDirectory.createOutput(FSDirectory.java:440)

at org.apache.lucene.index.FieldsWriter.(FieldsWriter.java:62)
at
org 
.apache 
.lucene 
.index.StoredFieldsWriter.initFieldsWriter(StoredFieldsWriter.java:65)


Please help..


Ashish P wrote:


Thanks man.
I just tried what u suggested but I am getting following error when
performing request
Mar 11, 2009 6:00:28 PM org.apache.solr.update.SolrIndexWriter
getDirectory
WARNING: No lockType configured for C:\dw-solr\solr\./data/index/  
assuming

'simple'
Mar 11, 2009 6:00:29 PM org.apache.solr.common.SolrException log
SEVERE: org.apache.lucene.store.LockObtainFailedException: Lock  
obtain

timed out:
simplefsl...@c:\dw-solr\solr\.\data\index 
\lucene-1d6c0059ac2f9f2c83acf749af7e0906-write.lock

at org.apache.lucene.store.Lock.obtain(Lock.java:85)
at org.apache.lucene.index.IndexWriter.init(IndexWriter.java:1140)
at org.apache.lucene.index.IndexWriter.(IndexWriter.java:938)
at
org.apache.solr.update.SolrIndexWriter.(SolrIndexWriter.java: 
116)


Any ideas???

-Ashish


Noble Paul നോബിള്‍  नोब्ळ् wrote:


String xml = null;//load the file to the xml string
DirectXmlRequest up = new DirectXmlRequest( "/update", xml );
solrServer.request( up );

On Wed, Mar 11, 2009 at 2:19 PM, Ashish P 
wrote:


I have an XML file with structure :

  ...
  ...
  .
  .


It is present on disk on some location let's say C:\\documents.xml

Q.1. Using solrJ can I index all docs in this file directly?? or  
do I

have
to convert each document to solrInputDocument by parsing XML

Q.2 How to use DirectXmlRequest?? any example

Thanks in advance...
Ashish




--
View this message in context:
http://www.nabble.com/SolrJ-XML-indexing-tp22450845p22450845.html
Sent from the Solr - User mailing list archive at Nabble.com.






--
--Noble Paul







--
View this message in context: 
http://www.nabble.com/SolrJ-XML-indexing-tp22450845p22451235.html
Sent from the Solr - User mailing list archive at Nabble.com.





smime.p7s
Description: S/MIME cryptographic signature


Re: Custom path for solr lib and data folder

2009-03-11 Thread Erik Hatcher


On Mar 11, 2009, at 5:14 AM, con wrote:

But still it is not working

I changed the data directory accordingly,
${SOLR_DATA}

But this is not working and is giving the following error:

SEVERE: Error in  
solrconfig.xml:org.apache.solr.common.SolrException: No

system property or default value specified for SOLR_DATA


For this to work, you have to set a JVM system property when launching  
Solr:


  java -DSOLR_DATA= -jar start.jar

Erik



Re: Tomcat holding deleted snapshots until it's restarted

2009-03-11 Thread Marc Sturlese

I am using the scripts of Collection Distribution.
The problem is just happening in the master, not in the slaves.
Do you have any clue? I am fighting against this since a few days ago...
Thanks in advance


Shalin Shekhar Mangar wrote:
> 
> On Wed, Mar 11, 2009 at 2:47 PM, Marc Sturlese
> wrote:
> 
>>
>> How can I make tomcat free the snapshots. Or even better... why is it
>> happening?
>>
> 
> Is this on the rsync replication or the new java replication in trunk?
> 
> -- 
> Regards,
> Shalin Shekhar Mangar.
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Tomcat-holding-deleted-snapshots-until-it%27s-restarted-tp22451252p22451527.html
Sent from the Solr - User mailing list archive at Nabble.com.



Re: Solr configuration with Text files

2009-03-11 Thread Erik Hatcher
Using Solr Cell (ExtractingRequestHandler) which is now built into  
trunk, and thus an eventual Solr 1.4 release, indexing a directory of  
text (or even Word, PDF, etc) files is mostly 'out of the box'.


It still requires scripting an iteration over all files and sending  
them.  Here's an example of doing that scripting using Ant and the ant- 
contrib  and  tasks:


  

  
  
Processing @{filename}

failonerror="true">

  
  
  
  

  
  
  
  

  

  

And it also should be possible, perhaps slightly easier and more built- 
in to do the entire iteration using DataImportHandler's ability to  
iterate over a list of files and read their contents into a field.   
[an example of this on the wiki would be handy, or a pointer to it if  
it doesn't already exist]


Erik


On Mar 10, 2009, at 2:01 PM, KennyN wrote:



This functionality is possible 'out of the box', right? Or am I  
going to need
to code up something that reads in the id named files and generates  
the xml

file?
--
View this message in context: 
http://www.nabble.com/Solr-configuration-with-Text-files-tp22438201p22440095.html
Sent from the Solr - User mailing list archive at Nabble.com.




Re: Tomcat holding deleted snapshots until it's restarted

2009-03-11 Thread Shalin Shekhar Mangar
On Wed, Mar 11, 2009 at 2:47 PM, Marc Sturlese wrote:

>
> How can I make tomcat free the snapshots. Or even better... why is it
> happening?
>

Is this on the rsync replication or the new java replication in trunk?

-- 
Regards,
Shalin Shekhar Mangar.


Re: Solr 1.3; Data Import w/ Dynamic Fields

2009-03-11 Thread Shalin Shekhar Mangar
On Wed, Mar 11, 2009 at 2:55 PM, Shalin Shekhar Mangar <
shalinman...@gmail.com> wrote:

> On Wed, Mar 11, 2009 at 2:28 PM, Wesley Small 
> wrote:
>
>> Good morning,
>>
>> I reviewed a Solr Patch-742, which corrects an issue with the data import
>> process properly ingesting/commiting (solr add xml) document with dynamic
>> fields.
>>
>> Is this fix available for Solr 1.3 or is there a known work around?
>>
>
> Unfortunately, no. The fix is in trunk but the trunk DataImportHandler uses
> a new rollback operation which is not supported by Solr 1.3 release.
>

However you should be able to backport the changes in SOLR-742 to Solr 1.3
code.

-- 
Regards,
Shalin Shekhar Mangar.


Re: Solr 1.3; Data Import w/ Dynamic Fields

2009-03-11 Thread Shalin Shekhar Mangar
On Wed, Mar 11, 2009 at 2:28 PM, Wesley Small wrote:

> Good morning,
>
> I reviewed a Solr Patch-742, which corrects an issue with the data import
> process properly ingesting/commiting (solr add xml) document with dynamic
> fields.
>
> Is this fix available for Solr 1.3 or is there a known work around?
>

Unfortunately, no. The fix is in trunk but the trunk DataImportHandler uses
a new rollback operation which is not supported by Solr 1.3 release.

-- 
Regards,
Shalin Shekhar Mangar.


Tomcat holding deleted snapshots until it's restarted

2009-03-11 Thread Marc Sturlese

Hey there,
I have noticed that once snapshots are deleted, tomcat keeps holding
references to them.Due to this disk space will never set free until Tomcat
is restarted, I have realized that doing a lsof | grep 'tomcat', the result
look like:
...

java 22015 tomcat 614r REG 253,0 1149569723 1093456605
/var/local/solr/data/index/_1fb.fdt (deleted)
java 22015 tomcat 615r REG 253,0 12724500 1093456606
/var/local/solr/data/index/_1fb.fdx (deleted)
java 22015 tomcat 616r REG 253,0 175953343 1093456607
/var/local/solr/data/index/_1fb.tis (deleted)
java 22015 tomcat 617r REG 253,0 1989522 1102344114
/var/local/solr/sdata/index/_1fb.tii (deleted)
java 22015 tomcat 618r REG 253,0 178646437 1102344140
/var/local/solr/data/index/_1fb.frq (deleted)
java 22015 tomcat 619r REG 253,0 108460405 1102344154
/var/local/solr/sdata/index/_1fb.prx (deleted)

...

How can I make tomcat free the snapshots. Or even better... why is it
happening?
Thanks in advance
-- 
View this message in context: 
http://www.nabble.com/Tomcat-holding-deleted-snapshots-until-it%27s-restarted-tp22451252p22451252.html
Sent from the Solr - User mailing list archive at Nabble.com.



Re: SolrJ XML indexing

2009-03-11 Thread Ashish P

I added single in indexDefaults that made the error
before go away but now I am getting following error :

Mar 11, 2009 6:12:56 PM org.apache.solr.common.SolrException log
SEVERE: java.io.IOException: Cannot overwrite:
C:\dw-solr\solr\data\index\_1o.fdt
at 
org.apache.lucene.store.FSDirectory.createOutput(FSDirectory.java:440)
at org.apache.lucene.index.FieldsWriter.(FieldsWriter.java:62)
at
org.apache.lucene.index.StoredFieldsWriter.initFieldsWriter(StoredFieldsWriter.java:65)

Please help..


Ashish P wrote:
> 
> Thanks man. 
> I just tried what u suggested but I am getting following error when
> performing request
> Mar 11, 2009 6:00:28 PM org.apache.solr.update.SolrIndexWriter
> getDirectory
> WARNING: No lockType configured for C:\dw-solr\solr\./data/index/ assuming
> 'simple'
> Mar 11, 2009 6:00:29 PM org.apache.solr.common.SolrException log
> SEVERE: org.apache.lucene.store.LockObtainFailedException: Lock obtain
> timed out:
> simplefsl...@c:\dw-solr\solr\.\data\index\lucene-1d6c0059ac2f9f2c83acf749af7e0906-write.lock
>   at org.apache.lucene.store.Lock.obtain(Lock.java:85)
>   at org.apache.lucene.index.IndexWriter.init(IndexWriter.java:1140)
>   at org.apache.lucene.index.IndexWriter.(IndexWriter.java:938)
>   at
> org.apache.solr.update.SolrIndexWriter.(SolrIndexWriter.java:116)
> 
> Any ideas???
> 
> -Ashish
> 
> 
> Noble Paul നോബിള്‍  नोब्ळ् wrote:
>> 
>> String xml = null;//load the file to the xml string
>> DirectXmlRequest up = new DirectXmlRequest( "/update", xml );
>> solrServer.request( up );
>> 
>> On Wed, Mar 11, 2009 at 2:19 PM, Ashish P 
>> wrote:
>>>
>>> I have an XML file with structure :
>>> 
>>>   ...
>>>   ...
>>>   .
>>>   .
>>> 
>>>
>>> It is present on disk on some location let's say C:\\documents.xml
>>>
>>> Q.1. Using solrJ can I index all docs in this file directly?? or do I
>>> have
>>> to convert each document to solrInputDocument by parsing XML
>>>
>>> Q.2 How to use DirectXmlRequest?? any example
>>>
>>> Thanks in advance...
>>> Ashish
>>>
>>>
>>>
>>>
>>> --
>>> View this message in context:
>>> http://www.nabble.com/SolrJ-XML-indexing-tp22450845p22450845.html
>>> Sent from the Solr - User mailing list archive at Nabble.com.
>>>
>>>
>> 
>> 
>> 
>> -- 
>> --Noble Paul
>> 
>> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/SolrJ-XML-indexing-tp22450845p22451235.html
Sent from the Solr - User mailing list archive at Nabble.com.



Re: Custom path for solr lib and data folder

2009-03-11 Thread con



Thanks nobble for the quick reply,

But still it is not working

I changed the data directory accordingly,
${SOLR_DATA}

But this is not working and is giving the following error:

SEVERE: Error in solrconfig.xml:org.apache.solr.common.SolrException: No
system property or default value specified for SOLR_DATA

But from the command prompt if do echo %SOLR_DATA% it is giving the expected
path.

Also is there any way to point solr to an extenal lib directory.
I have an application level lib directory outside of solr, and i need to put
all jars there.

Any possible solution for this problem is really appreciated.




Noble Paul നോബിള്‍  नोब्ळ् wrote:
> 
> environment variables do not work in  solr.xml
> 
> datadir must not be specified like this
> ${solr.data.dir:"%SOLR_DATA%"}
> 
> it should be like
> ${SOLR_DATA}
> the part aftyer the colon is the default value
> 
> 
> 
> On Wed, Mar 11, 2009 at 1:53 PM, con  wrote:
>>
>> Hi All
>>
>> Because of my particular development environment, I want to set up solr
>> in
>> such a way that
>>
>> 1) The shared lib have to be relocated to another path : This location
>> must
>> be read from an environment variable.
>>
>>        I am using solr multi-core and in the solr.xml I tried to specify
>> the
>> shared lib folder to a seperate directory.
>>        But it is not taking the environment variable. Even if I give a
>> absolute
>> path, it is trying to append the absolute path to the current working
>> directory.
>>
>>         this is not
>> working
>>         this also is not
>> working
>>
>> 2) The data dir must be in a different path : The location must be read
>> from
>> another environment variable
>>
>>        To specify the data directory, i updated the solrconfig.xml and
>> set,
>>        ${solr.data.dir:C:\search\data\employees} this
>> is
>> working
>>        but I want to replace this with an environment variable, like:
>>        ${solr.data.dir:"%SOLR_DATA%"}
>>
>> How is it possible in solr 1.3
>>
>> Thanks
>> con
>> --
>> View this message in context:
>> http://www.nabble.com/Custom-path-for-solr-lib-and-data-folder-tp22450530p22450530.html
>> Sent from the Solr - User mailing list archive at Nabble.com.
>>
>>
> 
> 
> 
> -- 
> --Noble Paul
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Custom-path-for-solr-lib-and-data-folder-tp22450530p22451207.html
Sent from the Solr - User mailing list archive at Nabble.com.



Re: SolrJ XML indexing

2009-03-11 Thread Ashish P

Thanks man. 
I just tried what u suggested but I am getting following error when
performing request
Mar 11, 2009 6:00:28 PM org.apache.solr.update.SolrIndexWriter getDirectory
WARNING: No lockType configured for C:\dw-solr\solr\./data/index/ assuming
'simple'
Mar 11, 2009 6:00:29 PM org.apache.solr.common.SolrException log
SEVERE: org.apache.lucene.store.LockObtainFailedException: Lock obtain timed
out:
simplefsl...@c:\dw-solr\solr\.\data\index\lucene-1d6c0059ac2f9f2c83acf749af7e0906-write.lock
at org.apache.lucene.store.Lock.obtain(Lock.java:85)
at org.apache.lucene.index.IndexWriter.init(IndexWriter.java:1140)
at org.apache.lucene.index.IndexWriter.(IndexWriter.java:938)
at 
org.apache.solr.update.SolrIndexWriter.(SolrIndexWriter.java:116)

Any ideas???

-Ashish


Noble Paul നോബിള്‍  नोब्ळ् wrote:
> 
> String xml = null;//load the file to the xml string
> DirectXmlRequest up = new DirectXmlRequest( "/update", xml );
> solrServer.request( up );
> 
> On Wed, Mar 11, 2009 at 2:19 PM, Ashish P 
> wrote:
>>
>> I have an XML file with structure :
>> 
>>   ...
>>   ...
>>   .
>>   .
>> 
>>
>> It is present on disk on some location let's say C:\\documents.xml
>>
>> Q.1. Using solrJ can I index all docs in this file directly?? or do I
>> have
>> to convert each document to solrInputDocument by parsing XML
>>
>> Q.2 How to use DirectXmlRequest?? any example
>>
>> Thanks in advance...
>> Ashish
>>
>>
>>
>>
>> --
>> View this message in context:
>> http://www.nabble.com/SolrJ-XML-indexing-tp22450845p22450845.html
>> Sent from the Solr - User mailing list archive at Nabble.com.
>>
>>
> 
> 
> 
> -- 
> --Noble Paul
> 
> 

-- 
View this message in context: 
http://www.nabble.com/SolrJ-XML-indexing-tp22450845p22451049.html
Sent from the Solr - User mailing list archive at Nabble.com.



Solr 1.3; Data Import w/ Dynamic Fields

2009-03-11 Thread Wesley Small
Good morning,

I reviewed a Solr Patch-742, which corrects an issue with the data import
process properly ingesting/commiting (solr add xml) document with dynamic
fields. 

Is this fix available for Solr 1.3 or is there a known work around?

Cheers,
Wesley


Re: SolrJ XML indexing

2009-03-11 Thread Noble Paul നോബിള്‍ नोब्ळ्
String xml = null;//load the file to the xml string
DirectXmlRequest up = new DirectXmlRequest( "/update", xml );
solrServer.request( up );

On Wed, Mar 11, 2009 at 2:19 PM, Ashish P  wrote:
>
> I have an XML file with structure :
> 
>   ...
>   ...
>   .
>   .
> 
>
> It is present on disk on some location let's say C:\\documents.xml
>
> Q.1. Using solrJ can I index all docs in this file directly?? or do I have
> to convert each document to solrInputDocument by parsing XML
>
> Q.2 How to use DirectXmlRequest?? any example
>
> Thanks in advance...
> Ashish
>
>
>
>
> --
> View this message in context: 
> http://www.nabble.com/SolrJ-XML-indexing-tp22450845p22450845.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>
>



-- 
--Noble Paul


Re: Custom path for solr lib and data folder

2009-03-11 Thread Noble Paul നോബിള്‍ नोब्ळ्
environment variables do not work in  solr.xml

datadir must not be specified like this
${solr.data.dir:"%SOLR_DATA%"}

it should be like
${SOLR_DATA}
the part aftyer the colon is the default value



On Wed, Mar 11, 2009 at 1:53 PM, con  wrote:
>
> Hi All
>
> Because of my particular development environment, I want to set up solr in
> such a way that
>
> 1) The shared lib have to be relocated to another path : This location must
> be read from an environment variable.
>
>        I am using solr multi-core and in the solr.xml I tried to specify the
> shared lib folder to a seperate directory.
>        But it is not taking the environment variable. Even if I give a 
> absolute
> path, it is trying to append the absolute path to the current working
> directory.
>
>         this is not working
>         this also is not working
>
> 2) The data dir must be in a different path : The location must be read from
> another environment variable
>
>        To specify the data directory, i updated the solrconfig.xml and set,
>        ${solr.data.dir:C:\search\data\employees} this is
> working
>        but I want to replace this with an environment variable, like:
>        ${solr.data.dir:"%SOLR_DATA%"}
>
> How is it possible in solr 1.3
>
> Thanks
> con
> --
> View this message in context: 
> http://www.nabble.com/Custom-path-for-solr-lib-and-data-folder-tp22450530p22450530.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>
>



-- 
--Noble Paul


SolrJ XML indexing

2009-03-11 Thread Ashish P

I have an XML file with structure :

   ...
   ...
   .
   .


It is present on disk on some location let's say C:\\documents.xml

Q.1. Using solrJ can I index all docs in this file directly?? or do I have
to convert each document to solrInputDocument by parsing XML

Q.2 How to use DirectXmlRequest?? any example

Thanks in advance...
Ashish




-- 
View this message in context: 
http://www.nabble.com/SolrJ-XML-indexing-tp22450845p22450845.html
Sent from the Solr - User mailing list archive at Nabble.com.



Custom path for solr lib and data folder

2009-03-11 Thread con

Hi All

Because of my particular development environment, I want to set up solr in
such a way that 

1) The shared lib have to be relocated to another path : This location must
be read from an environment variable.

I am using solr multi-core and in the solr.xml I tried to specify the
shared lib folder to a seperate directory. 
But it is not taking the environment variable. Even if I give a absolute
path, it is trying to append the absolute path to the current working
directory.

 this is not working
 this also is not working

2) The data dir must be in a different path : The location must be read from
another environment variable

To specify the data directory, i updated the solrconfig.xml and set,
${solr.data.dir:C:\search\data\employees} this is
working 
but I want to replace this with an environment variable, like:
${solr.data.dir:"%SOLR_DATA%"}

How is it possible in solr 1.3

Thanks
con
-- 
View this message in context: 
http://www.nabble.com/Custom-path-for-solr-lib-and-data-folder-tp22450530p22450530.html
Sent from the Solr - User mailing list archive at Nabble.com.