apache / apache/lucene

Improve QueryParser and supported syntax documentation [LUCENE-4040]

Open
#5,112 6 comments 0 reactions 0 assignees View on GitHub
legacy-jira-priority:Minor module:queryparser type:enhancement
Dominant language
Java
Stars
3.6k
Forks
1.4k
Avg merge
2d 11h
Merged PRs (30d)
88

Description

In #5097 there were some changes to the fuzzy query syntax. Only the Classic QueryParser really documents its syntax, which makes it hard to know whether the changes effected other QPs. Compounding this issue there are many classes which have no javadocs at all and I found myself quite confused when I consolidated all the QPs into their module.

We should do a concerted effort to improve the documentation so that it is clear what syntax is supported by what QPs and so that at least the user facing classes have javadocs.

As part of this, I wonder whether we should give the syntax supported by the Classic QueryParser a new name (rather than just Lucene's query syntax) since other QPs can and do support other syntax, and then somehow add some typed control over this, so QPs have to declare programmatically that they support the syntax and so we can verify that by randomly plugging in implementations into tests.

---
Migrated from [LUCENE-4040](https://issues.apache.org/jira/browse/LUCENE-4040) by Chris Male, 2 votes, updated May 11 2012
Attachments: [LUCENE-4040.patch](https://apache.github.io/lucene-jira-archive/attachments/LUCENE-4040/LUCENE-4040.patch) (versions: 2)

Contributor guide

Open the contributing guide

Research direction

Start by reviewing the existing Classic QueryParser syntax documentation, the other QueryParser classes mentioned in the issue, and the attached LUCENE-4040.patch. Map which user-facing query parsers lack documentation and identify the unresolved naming and programmatic syntax-declaration questions. Done would require an agreed scope, clear syntax coverage by parser, and appropriate user-facing Javadocs.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
documentation, search
Issue type
Documentation
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.