-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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
add highlight max analyzed offset config to avoid long text discover search fail #191384
add highlight max analyzed offset config to avoid long text discover search fail #191384
Conversation
💚 CLA has been signed |
Thanks for contributing! I'm discussing some things internally on how to move forward with this PR, but until then I just wanted to let you know we're actively thinking about this and give some initial feedback: Having one advanced setting for this specific parameter is probably not what we want moving forward. As you've pointed out, there are other highlight-related parameters that users/admins may want to specifically configure. So we might want to consider changing this to accept a JSON object that can specify multiple parameters. (This is similar to how I would hold off on making additional changes on this PR for now, as I'm trying to get the Elasticsearch folks involved as well. What honestly makes most sense to me is to default the Again, thanks for contributing... We recognize that the current behavior is not ideal, and we need to do something to help out here. |
We brought up this need with the Elasticsearch team and they have added elastic/elasticsearch#112822. If they implement this, we can just default to setting it to whatever the index is configured to. If that is fixed, would you still have a need to configure a value to something different? |
No, I agree that's better. thanks all, I will close this. |
for thoese who need a workaround, here is a quick and dirty way. tested in docker image kibana:7.17.8, other version should work too. |
add highlight max analyzed offset config to avoid long text discover search fail
resolves #159391
Summary
es default allow 1000000 text highlight anylyzes, if longer than this limit, discover will return fail. it's much better just ignore too long text full highlight than fail the search. so add a config and a default 1000000.
see https://www.elastic.co/guide/en/elasticsearch/reference/7.17/highlighting.html#offsets-strategy
For maintainers