[ 
https://issues.apache.org/jira/browse/LUCENE-2514?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Robert Muir updated LUCENE-2514:
--------------------------------

    Attachment: LUCENE-2514_qp.patch

With Term as byte, and tokenstreams can encode terms to byte however they want 
with TermToBytesRefAttribute, it makes sense for queryparsers to consume bytes 
like the indexer, and build terms without an intermediate String. 

This way non-unicode terms (e.g. collation) work as expected.

This patch updates the queryparsers, except for contrib/queryparser (which will 
be more serious and cause API changes), and the range query building 
AnalyzingQueryParser (we need to fix TermRangeQuery first).

All tests pass.

> Change Term to use bytes
> ------------------------
>
>                 Key: LUCENE-2514
>                 URL: https://issues.apache.org/jira/browse/LUCENE-2514
>             Project: Lucene - Java
>          Issue Type: Task
>          Components: Search
>    Affects Versions: 4.0
>            Reporter: Robert Muir
>            Assignee: Uwe Schindler
>         Attachments: LUCENE-2514-MTQPagedBytes.patch, 
> LUCENE-2514-MTQPagedBytes.patch, LUCENE-2514-MTQPagedBytes.patch, 
> LUCENE-2514-surrogates-dance.patch, LUCENE-2514.patch, LUCENE-2514.patch, 
> LUCENE-2514.patch, LUCENE-2514.patch, LUCENE-2514.patch, LUCENE-2514.patch, 
> LUCENE-2514.patch, LUCENE-2514.patch, LUCENE-2514.patch, LUCENE-2514.patch, 
> LUCENE-2514.patch, LUCENE-2514.patch, LUCENE-2514.patch, LUCENE-2514.patch, 
> LUCENE-2514_qp.patch
>
>
> in LUCENE-2426, the sort order was changed to codepoint order.
> unfortunately, Term is still using string internally, and more importantly 
> its compareTo() uses the wrong order [utf-16].
> So MultiTermQuery, etc (especially its priority queues) are currently wrong.
> By changing Term to use bytes, we can also support terms encoded as bytes 
> such as numerics, instead of using
> strange string encodings.

-- 
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: dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: dev-h...@lucene.apache.org

Reply via email to