lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Martijn v Groningen <martijn.v.gronin...@gmail.com>
Subject Re: ToParentBlockJoinQuery vs filtered search
Date Mon, 06 Feb 2012 15:57:59 GMT
Hi Mikhail,

There is already an issue open for supporting block join in Solr:
https://issues.apache.org/jira/browse/SOLR-3076

Maybe you can attach your work in that issue and we can iterate from there.

Martijn

On 6 February 2012 14:54, Michael McCandless <lucene@mikemccandless.com> wrote:
>
> On Sun, Feb 5, 2012 at 11:43 PM, Mikhail Khludnev
> <mkhludnev@griddynamics.com> wrote:
>
> > Thanks for resolving my hesitations. It allows me move forward.
>
> You're welcome!
>
> >> It looks like that's what your test case is testing for...?  Does it pass?
> >
> > Of course it doesn't.
> > the first reason is that BlockJoinWeight.scorer()
> > http://svn.apache.org/viewvc/lucene/dev/trunk/modules/join/src/java/org/apache/lucene/search/join/ToParentBlockJoinQuery.java?view=markup
> > has the opposite intention (btw, are you %100 sure?):
> >  * Children query is filtered by the given filter
> > childWeight.scorer(readerContext, true, false, *acceptDocs*);
> >  * Parent filter  is not constrained
> > parentsFilter.getDocIdSet(readerContext,
> > *readerContext.reader().getLiveDocs()*);
> > That's why I asked for the rationale of filtered BJQ search.
> >
> > The also complication which I met is that
> > AssertingIndexSearcher.wrapFilter() randomly switches from filtered
> > search to FilteredQuery.
> > http://svn.apache.org/viewvc/lucene/dev/trunk/lucene/src/test-framework/java/org/apache/lucene/search/AssertingIndexSearcher.java
> > it leads to IllegalStateException"parentFilter must return
> > FixedBitSet; got "BitsFilteredDocIdSet. I suppose I can deal with it.
>
> Hang on -- there are 2 different filters here.
>
> The first one, the parentsFilter that you pass to
> ToParent/ChildBlockJoinQuery, is very specific: it must identify which
> docs are parent docs.  This is unchangeable: every BJQ must use this
> same filter, since what is parent and what is child was determined at
> indexing time when you indexed the blocks.  It must produce a
> FixedBitSet per segment (using CachingWrapperFilter does so).
>
> The second filter, is the optional filter the outside app can pass to
> IndexSearcher.search -- it's this filter that I was describing in my
> last response (ie, that it will be used in the "to" document space,
> only).  This filter is obviously free to change per query, depending
> on what the app is doing...
>
> Mike
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
> For additional commands, e-mail: dev-help@lucene.apache.org
>



--
Met vriendelijke groet,

Martijn van Groningen

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


Mime
View raw message