lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Adriano Crestani (JIRA)" <>
Subject [jira] Updated: (LUCENE-1938) Precedence query parser using the contrib/queryparser framework
Date Thu, 01 Oct 2009 23:15:23 GMT


Adriano Crestani updated LUCENE-1938:

    Attachment: LUCENE-1938.patch

This patch contains a Precedence query parser. It's basically an extension of the current
Standard query parser, but enables the boolean precedence.

The patch also contains the test cases from the current PrecedenceQueryParser, currently located
under contrib/misc. Everything passes fine, except a test that tests if the query <A B
C> is the same as <A OR B C>, when the default operator is OR. The problem is that
this new PQP does not flat/optimize the boolean tree when the boolean operator is the same.
It can be performed later, but for now it does not implement this kind of optimization.

Another issue is that I created a class under contrib/queryparser called PrecedenceQueryParser
within the same package declaration the PQP from contrib/misc is right now. Is that a big
issue? Couldn't the old PQP be removed and we start using this one, so we have no class conflict.

The greatest advantage of this implementation is that it basically reuses all the StandardQueryParser
functiontalities and syntax, and any modification on the StandardQP will be automatically
applied to the PrecedenceQP. No need to maintain 2 different implementations with the same
code, as the old PQP does today.

> Precedence query parser using the contrib/queryparser framework
> ---------------------------------------------------------------
>                 Key: LUCENE-1938
>                 URL:
>             Project: Lucene - Java
>          Issue Type: New Feature
>          Components: contrib/*
>    Affects Versions: 2.9
>            Reporter: Adriano Crestani
>            Assignee: Adriano Crestani
>            Priority: Minor
>             Fix For: 3.1
>         Attachments: LUCENE-1938.patch
> Extend the current StandardQueryParser on contrib so it supports boolean precedence

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message