MultiFieldDisjunctionMaxQueryParser [LUCENE-553]
- Dominant language
- Java
- Stars
- 3.6k
- Forks
- 1.4k
- Avg merge
- 2d 11h
- Merged PRs (30d)
- 88
Description
Following on from Lucene-323, here is a replacement for the old DistributingMultiFieldQueryParser that works with the new QueryParser. This is essentially a cut-and-paste of MultiFieldQueryParser, using DisjunctionMaxQuery instead of BooleanQuery as the combing operator for the expansion of query terms across the multiple fields being searched. This is an important adjunct to DisjunctionMaxQuery as it provides a way to generate this query from input query strings.
It would be possible to generalize MultiFieldQueryParser to parameterize the combining operator, but this would require modifying it rather than simply adding a new class.
---
Migrated from [LUCENE-553](https://issues.apache.org/jira/browse/LUCENE-553) by Chuck Williams, updated Feb 28 2013
Environment:
```
All
```
Attachments: [MultiFieldDisjunctionMaxQueryParser.java](https://apache.github.io/lucene-jira-archive/attachments/LUCENE-553/MultiFieldDisjunctionMaxQueryParser.java), [MultiFieldDisjunctionMaxQueryParserTest.java](https://apache.github.io/lucene-jira-archive/attachments/LUCENE-553/MultiFieldDisjunctionMaxQueryParserTest.java)
Contributor guide
Research direction
Start by reading the existing MultiFieldQueryParser and the attached MultiFieldDisjunctionMaxQueryParser.java and MultiFieldDisjunctionMaxQueryParserTest.java. Compare the proposed parser with the current QueryParser behavior and confirm the test coverage. Done means the replacement parser supports multi-field query strings using DisjunctionMaxQuery and its tests pass.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- search
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100