Highlighting issue with quoted queries in Solr - fragment not returned

485 Views Asked by At

This is very curious. Highlighting works fine in every other case, but there's this one case it doesn't return any fragments. My document is as follows (fieldType text_en):

Abu Yahya Suhaib bin Sinan (May Allah be pleased with him) reported that: The Messenger of Allah (PBUH) said, "How wonderful is the case of a believer; there is good for him in everything and this applies only to a believer. If prosperity attends him, he expresses gratitude to Allah and that is good for him; and if adversity befalls him, he endures it patiently and that is better for him".[Muslim].

My query is

"wonderful is the case of a believer"

Solr finds the document to return alright, but the highlighting component of the return value doesn't contain the text of the document. It has a field for the primary key of the document (like always) but nothing deeper than that.

If I remove the last word, everything works properly. If I remove the last word from the quotes and place it outside, it works. It even works with a longer (different) string in quotes. It just doesn't work for this!

How do I begin debugging this?

I don't have any highlighting setup in schema.xml and here are the parameters I'm passing as part of he query: &hl=true&hl.fl=hadithText&hl.snippets=50&hl.fragsize=2500&hl.mergeContiguous=true&defType=edismax&mm=3<-1%205<-2&hl.usePhraseHighlighter=true

0

There are 0 best solutions below