-
-
Notifications
You must be signed in to change notification settings - Fork 5.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use MatchPhraseQuery for bleve code search #33628
Conversation
The test fails because the default behavior for bleve now differs from elasticsearch. |
use ![]() |
My instance was recently upgraded from 1.22 and 1.23 and many users complain about the code search returning way too many irrelevant results in the new version. In 1.22 MatchPhraseQuery was used for bleve. In 1.23 it now uses MatchQuery without any option for the user to switch it back to MatchPhraseQuery. I don't know what the best course of action is. Maybe your PR #33590 can be backported to 1.23. |
Maybe we can backport it after
Maybe it's better to backport #33590 ? |
I feel like returning ~200 matches when searching for GitHub search returns a single match for So as I said: I don't know what the right approach is, but bleve code search feels broken in 1.23. |
Fix regression from #32210 which unintentionally changed the search mode for bleve from MatchPhraseQuery to MatchQuery.
On the main branch, meanwhile with #33590 a "literal code search" mode (by using quotes) was implemented as workaround for this unexpected code search behavior. Maybe that feature needs some redesign as it turns out to have been caused by a regression.
But this PR at least already fixes the regression for 1.23.x