Re: References to deleted file handles in long-running server application

2005-11-18 Thread Paul Smith
I have found exactly the same problem. You should consider adding an 'expired IndexSearcher to some sort of Buffer that closes the IndexSearcher after some default timeout. I have not found in practice that allowing the GC to do the work does quite what you think it might do

RE: References to deleted file handles in long-running server application

2005-11-18 Thread Vanlerberghe, Luc
Good rule of thumb: don't ever count on the garbage collector cleaning up for you (even if you call System.gc() to give it a hint). You should close your IndexSearchers, but with a multithreaded application it's difficult to know when (you have to keep them open until no thread uses it any more)

Re: Deprecated API in BooleanQuery broken in Lucene from CVS?

2005-11-18 Thread Patrick Kimber
Daniel You are correct. The latest version from SVN works correctly. Very confusing - I only checked out Lucene from CVS a few days ago. I didn't realise that changes were only being made in the SVN repository. Thank you very much for your help. Regards Patrick On 17/11/05, Daniel Naber [EMAIL

Re: Field Boosting

2005-11-18 Thread Daniel . Clark
titleField.setBoost((float)1.8); doc.add(titleField); keywordField.setBoost((float)1.6); doc.add(keywordField); summaryField.setBoost((float)1.2); doc.add(summaryField); When searching. field.getBoost() always = 1.0 ~ Daniel Clark, Senior Consultant

Re: TermFreqVector

2005-11-18 Thread Grant Ingersoll
On the 1.9 code base, you construct a Term Vector by doing something like: Document doc = ... doc.add(new Field(contents, some value, Field.Store.YES, Field.Index.TOKENIZED, Field.TermVector.WITH_POSITIONS_OFFSETS)); Check out the javadocs for field construction. Once you have done this,

TermFreqVector

2005-11-18 Thread Anna Buczak
You have to tell lucene to store term freq vectors (it isn't done by default). This is exactly the part that I do not know how to do. Where to set the flag ? I use for indexing org.apache/lucene.demo.IndexFiles. Do you have at least one field? Now I know that Lucene adds three fields by default