lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Grant Ingersoll (JIRA)" <>
Subject [jira] Updated: (LUCENE-2945) Surround Query doesn't properly handle equals/hashcode
Date Sat, 05 Mar 2011 12:37:45 GMT


Grant Ingersoll updated LUCENE-2945:

    Attachment: LUCENE-2945.patch

OK, here's a patch with a test that passes.  I'm not entirely thrilled about the implementation
of equals/hash on the two inner classes (used to be anonymous) but I do think it works.  Namely,
I use the syntax of the original query as a string, per Paul's original suggestion as part
of the hash/equals.  It just seems awkward to have to pass that in solely for this purpose,
but I didn't see what other information I had around that would make the object unique from
an equals/hash standpoint.  I suppose the underlying queries list on the ComposedQuery might
work and I can try that if others think it makes more sense.

> Surround Query doesn't properly handle equals/hashcode
> ------------------------------------------------------
>                 Key: LUCENE-2945
>                 URL:
>             Project: Lucene - Java
>          Issue Type: Bug
>    Affects Versions: 3.0.3, 4.0
>            Reporter: Grant Ingersoll
>            Assignee: Grant Ingersoll
>            Priority: Minor
>             Fix For: 3.1, 4.0
>         Attachments: LUCENE-2945-partial1.patch, LUCENE-2945.patch, LUCENE-2945.patch,
> In looking at using the surround queries with Solr, I am hitting issues caused by collisions
due to equals/hashcode not being implemented on the anonymous inner classes that are created
by things like DistanceQuery (branch 3.x, near line 76)

This message is automatically generated by JIRA.
For more information on JIRA, see:


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

View raw message