Uploaded image for project: 'Lucene - Core'
  1. Lucene - Core
  2. LUCENE-1599

SpanRegexQuery and SpanNearQuery is not working with MultiSearcher

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.4.1
    • Fix Version/s: 2.9
    • Component/s: modules/other
    • Labels:
      None
    • Environment:

      lucene-core 2.4.1, lucene-regex 2.4.1

    • Lucene Fields:
      New, Patch Available

      Description

      MultiSearcher is using:
      queries[i] = searchables[i].rewrite(original);
      to rewrite query and then use combine to combine them.

      But SpanRegexQuery's rewrite is different from others.
      After you call it on the same query, it always return the same rewritten queries.

      As a result, only search on the first IndexSearcher work. All others are using the first IndexSearcher's rewrite queries.
      So many terms are missing and return unexpected result.

      Billow

        Attachments

        1. LUCENE-1599.patch
          8 kB
          Mark Miller
        2. TestSpanRegexBug.java
          3 kB
          Billow Gao

          Activity

            People

            • Assignee:
              markrmiller@gmail.com Mark Miller
              Reporter:
              billowgao Billow Gao
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Time Tracking

                Estimated:
                Original Estimate - 2h
                2h
                Remaining:
                Remaining Estimate - 2h
                2h
                Logged:
                Time Spent - Not Specified
                Not Specified