Skip to content
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

Requiring support for leading wildcard search for nouveau #5027

Closed
GMishx opened this issue Apr 4, 2024 · 3 comments
Closed

Requiring support for leading wildcard search for nouveau #5027

GMishx opened this issue Apr 4, 2024 · 3 comments

Comments

@GMishx
Copy link
Contributor

GMishx commented Apr 4, 2024

Summary

Requiring support for leading wildcard search for Nouveau indexes. Currently, the leading wildcard searches are not supported by Nouveau and throws a 400.

Desired Behaviour

Ability to configure leading wildcard search for Nouveau.

Possible Solution

In the previous integration with couchdb-lucene, there was a configurable setting in couchdb-lucene.ini which can enable leading wildcard search. Need a similar setting for Nouveau to support searches like ?q=name:*roe*

@rnewson
Copy link
Member

rnewson commented Apr 4, 2024

This will not be supported for the same reason that Lucene itself recommends against it, it is very inefficient (all documents with the field must be read, you get no benefit from an index).

If you truly need this a common trick is to reverse your index input and reverse your query, converting a suffix query into a more efficient prefix query.

@GMishx
Copy link
Contributor Author

GMishx commented Apr 5, 2024

Thanks for the explanation and inputs.

@GMishx GMishx closed this as completed Apr 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants