Re: Question about index segment search order

2023-05-13 Thread Uwe Schindler
Hi, in reference to previous code references and discussions from other Lucene committers I have to clarify: * If you run the query multithreaded (per segment), this means when you add an Executor to IndexSearcher, the order is not predicatable, plain simple * If you use Solr, a single

Re: Question about index segment search order

2023-05-11 Thread Wei
Hi Michael, Yes the collector counts hits across all segments. Thanks for the suggestion, I'm also asking the question on solr-dev. Wei On Thu, May 11, 2023 at 11:57 AM Michael Sokolov wrote: > Maybe ask this issue on solr-dev then? I'm not familiar with how that > collector works. Does it cou

Re: Question about index segment search order

2023-05-11 Thread Michael Sokolov
Maybe ask this issue on solr-dev then? I'm not familiar with how that collector works. Does it count hits across all segments? only within a single segment? On Tue, May 9, 2023 at 1:36 PM Wei wrote: > > Hi Michael, > > I am applying early termination with Solr's EarlyTerminatingCollector > https:

Re: Question about index segment search order

2023-05-09 Thread Wei
Hi Michael, I am applying early termination with Solr's EarlyTerminatingCollector https://github.com/apache/solr/blob/d9ddba3ac51ece953d762c796f62730e27629966/solr/core/src/java/org/apache/solr/search/EarlyTerminatingCollector.java , which triggers EarlyTerminatingCollectorException in SolrIndexSe

Re: Question about index segment search order

2023-05-04 Thread Michael Sokolov
Yes, sorry I didn't mean to imply you couldn't control this if you want to. I guess in the typical setup it is not predictable. How are you applying early termination? Are you using a standard Lucene Collector or do you have your own? On Thu, May 4, 2023 at 2:03 PM Patrick Zhai wrote: > > Hi Mike

Re: Question about index segment search order

2023-05-04 Thread Patrick Zhai
Hi Mike, Just want to mention if the user chooses to use single thread to index and use LogXXMergePolicy then the document order will be preserved as index order. On Thu, May 4, 2023 at 10:04 AM Wei wrote: > Hi Michael, > > We are interested in the segment sequence for early termination. In ou

Re: Question about index segment search order

2023-05-04 Thread Wei
Hi Michael, We are interested in the segment sequence for early termination. In our case there is always a large dominant segment after index rebuild, then many small segments are generated with continuous updates as time goes by. When early termination is applied, the limit could be reached just

Re: Question about index segment search order

2023-05-04 Thread Michael Sokolov
There is no meaning to the sequence. The segments are created concurrently by many threads and the merge process will merge them without regards to any ordering. On Wed, May 3, 2023, 1:09 PM Patrick Zhai wrote: > For that part I'm not entirely sure, if other folks know it please chime in > :)

Re: Question about index segment search order

2023-05-03 Thread Patrick Zhai
For that part I'm not entirely sure, if other folks know it please chime in :) On Wed, May 3, 2023 at 8:48 AM Wei wrote: > Thanks Patrick! In the default case when no LeafSorter is provided, are the > segments traversed in the order of creation time, i.e. the oldest segment > is always visited f

Re: Question about index segment search order

2023-05-03 Thread Wei
Thanks Patrick! In the default case when no LeafSorter is provided, are the segments traversed in the order of creation time, i.e. the oldest segment is always visited first? Wei On Tue, May 2, 2023 at 7:22 PM Patrick Zhai wrote: > Hi Wei, > Lucene in general iterate through the index in the or

Re: Question about index segment search order

2023-05-02 Thread Patrick Zhai
Hi Wei, Lucene in general iterate through the index in the order of what is recorded in the SegmentInfos And at search time, you can specify the order using LeafSorter

Question about index segment search order

2023-05-02 Thread Wei
Hello, We have a index that has multiple segments generated with continuous updates. Does Lucene have a specific order when iterate through the segments (assuming single query thread) ? Can the order be customized that the latest generated segments are searched first? Thanks, Wei

Re: Bizarre Search order request

2012-05-25 Thread Chris Hostetter
: For example, if I display of 20 results, I might want to limit it to a : maximum of 10 "mail", 10 "blog" and 10 "website" documents. Which ones : get displayed and how they were ordered would depend on the normal : relevancy ranking, but, for example, once I had 10 "mail" objects to : displ

Re: Bizarre Search order request

2012-05-25 Thread Chris Lu
Nothing like this yet. But you don't need to do everything in one search request. You can send one search request to know that the match distribution for each document type, and then send 3 requests for 3 document types each. -- Chris Lu - Instant Scalable Full-Text Searc

Bizarre Search order request

2012-05-25 Thread Scott Smith
I really need this on Solr, but thought I would start here as I suspect that, if it's possible, it's some kind of custom relevancy ranking that would need to be done in lucene and then used in SOLR. I will simplify the actual problem somewhat, but I think it will have the gist of what I want to

Re: Search Order

2008-05-05 Thread N. Hira
Please review: http://wiki.apache.org/lucene-java/LuceneFAQ I suspect your question is answered as: How do I make sure that a match in a document title has greater weight than than a match in a document body? -h -- Hira, N.

Re: Search Order

2008-05-05 Thread Erick Erickson
Well, it all depends upon what you mean by problem. Lucene is not returning things in random order, it's returning things in relevance order. There is a lot of discussion about scoring both on the Wiki and in the mail archive if you want to affect the return order. Alternatively, you can sort your

Search Order

2008-05-05 Thread Prashant Saraf
Hi, I am creating a keyword based search engine. Now I am able to search the required data. Now, I notice that the data coming is in random order. Is there any way I can call particular record 1st. I have an example. Suppose I m working on search of Book content, writer, publication. Now if I en