mkapalka commented on code in PR #2681:
URL: https://github.com/apache/jackrabbit-oak/pull/2681#discussion_r2681320919


##########
oak-search-elastic/src/main/java/org/apache/jackrabbit/oak/plugins/index/elastic/query/ElasticRequestHandler.java:
##########
@@ -131,6 +130,9 @@ public class ElasticRequestHandler {
 
     private static final String HIGHLIGHT_PREFIX = "<strong>";
     private static final String HIGHLIGHT_SUFFIX = "</strong>";
+    // by default, highlight analyzes up to 1M characters. If the content is 
larger than that, an error is thrown.
+    // To avoid that we need to set a limit lower than that.
+    private static final int HIGHLIGHT_MAX_ANALYZED_OFFSET = 999_999;

Review Comment:
   Maybe it's new in 9.x: I don't see this special value in the docs for 8.15: 
https://www.elastic.co/guide/en/elasticsearch/reference/8.15/highlighting.html



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to