Highlighter does not correctly highlight the phrase around 50th term [LUCENE-2910]
- Dominant language
- Java
- Stars
- 3.6k
- Forks
- 1.4k
- Avg merge
- 2d 11h
- Merged PRs (30d)
- 88
Description
When you use the Highlighter combined with N-Gram tokenizers such as CJKTokenizer and try to highlight the phrase that appears around 50th term in the field, the highlighted phrase is shorter than expected.
```
e.g. Highlighting "fooo" in the following text with bigram tokenizer:
"0---------1---------2---------3---------4---------fooo---"
Expected: "0---------1---------2---------3---------4---------fooo---"
Actual: "0---------1---------2---------3---------4---------fooo---"
```
---
Migrated from [LUCENE-2910](https://issues.apache.org/jira/browse/LUCENE-2910) by Shinya Kasatani
Attachments: [HighlighterFix.patch](https://apache.github.io/lucene-jira-archive/attachments/LUCENE-2910/HighlighterFix.patch)
Contributor guide
Assessment
This issue has not been assessed yet.