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

No max_analyzed_offset for highlighting in v7.0.30 #1591

ikey4u opened this issue Feb 28, 2022 · 1 comment

No max_analyzed_offset for highlighting in v7.0.30 #1591

ikey4u opened this issue Feb 28, 2022 · 1 comment


Copy link

ikey4u commented Feb 28, 2022

Which version of Elastic are you using?

elastic.v7 (for Elasticsearch 7.14.2)

Please describe the expected behavior

When doing elastic query, if a filed length more than index.highlight.max_analyzed_offset, it will fail with the following error

illegal_argument_exception: The length [2692528] of field [content] in xxx exceeds the [index.highlight.max_analyzed_offset] limit [1000000]. To avoid this error, set the query parameter [max_analyzed_offset] to a value ....

To solve this problem, we can add a max_analyzed_offset to highlight field.

Please describe the actual behavior

API in highlight.go file does not provide any option to set max_analyzed_offset.

Copy link

olivere commented Feb 28, 2022

Yep, looks like this is missing.

@olivere olivere added this to the 7.0.32 milestone Feb 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet

No branches or pull requests

2 participants