Hello,

i was digging into the highlighting functionality in solr and saw that if multiple highlighting fields (like wildcards) are specified, the IndexReader is used at every document and field to get the term vectors (at TokenSources.getTokenStreamWithOffsets). I would suggest that a optional cache would be good here that holds the document id as a key and a Fields object as value. I implemented this behavior in the DefaultSolrHighlighter.doHighlightingByHighlighter method and got nice performance improvement there.

What do you think, does this make sense or is this a more rare usecase?

Greetings,
Daniel

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to