[ 
https://issues.apache.org/jira/browse/SOLR-17003?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17778210#comment-17778210
 ] 

Alex Deparvu commented on SOLR-17003:
-------------------------------------

can you switch the config to the 'original' then? are the highlighting results 
correct?

> UnifiedHighlighter breaks with DateRangeField
> ---------------------------------------------
>
>                 Key: SOLR-17003
>                 URL: https://issues.apache.org/jira/browse/SOLR-17003
>             Project: Solr
>          Issue Type: Bug
>          Components: query
>    Affects Versions: 9.3
>         Environment: Solr 9.3.0
> JRE 17.0.7+8-LTS-224
> Solarium 6.3.1 as middleware
>            Reporter: Scott Vanderbilt
>            Priority: Major
>
> Posted about this on 
> [us...@solr.apahe.org|https://lists.apache.org/thread/m1hs2poxong05crojlfkztc23dnkjsyq]
>  on 13 Sept., but got no response.
> When I submit a query on a field of type solr.DateRangeField, I get the 
> following error:
> {noformat}
> 2023-09-09 17:29:55.017 INFO (qtp790021811-18) [ x:rib] o.a.s.c.S.Request 
> webapp=/solr path=/select 
> params={q=provFindDateRange:[1901+TO+1901]&json.nl=flat&hl=true&hl.simple.post=</strong>&omitHeader=true&fl=id,ribnum,ribnumSort,docTitle,fileName,ribSiteName,authority,msContentsSummary,objTypeAna,objTypeTxt,edition,translation,commentaryP,supportP,isFalsa,isAliena,imageFileNameThumbnail,edLemmaLat,origDateStr,origDateBegin,origDateEnd,geoFindspot&start=0&hl.fragsize=128&hl.fl=edition,translation,commentaryP,provFindspotP,supportP,decoNote&rows=10&wt=json&hl.simple.pre=<strong>}
>  hits=791 status=500 QTime=765
> 2023-09-09 17:29:55.027 ERROR (qtp790021811-18) [ x:rib] o.a.s.s.HttpSolrCall 
> 500 Exception => java.lang.ArrayIndexOutOfBoundsException: Index -1 out of 
> bounds for length 10
>         at 
> org.apache.lucene.spatial.prefix.tree.NumberRangePrefixTree.readCell(NumberRangePrefixTree.java:526)
> java.lang.ArrayIndexOutOfBoundsException: Index -1 out of bounds for length 10
>         at 
> org.apache.lucene.spatial.prefix.tree.NumberRangePrefixTree.readCell(NumberRangePrefixTree.java:526)
>  ~[?:?]
>         at 
> org.apache.lucene.spatial.prefix.AbstractVisitingPrefixTreeQuery$VisitorTemplate.nextTerm(AbstractVisitingPrefixTreeQuery.java:268)
>  ~[?:?]
>         at 
> org.apache.lucene.spatial.prefix.AbstractVisitingPrefixTreeQuery$VisitorTemplate.getDocIdSet(AbstractVisitingPrefixTreeQuery.java:118)
>  ~[?:?]
>         at 
> org.apache.lucene.spatial.prefix.IntersectsPrefixTreeQuery.getDocIdSet(IntersectsPrefixTreeQuery.java:82)
>  ~[?:?]
>         at 
> org.apache.lucene.spatial.prefix.AbstractPrefixTreeQuery$1.scorer(AbstractPrefixTreeQuery.java:94)
>  ~[?:?]
>         at org.apache.lucene.search.Weight.scorerSupplier(Weight.java:136) 
> ~[?:?]
>         at org.apache.lucene.search.Weight.matches(Weight.java:79) ~[?:?]
>         at 
> org.apache.lucene.search.uhighlight.FieldOffsetStrategy.createOffsetsEnumsWeightMatcher(FieldOffsetStrategy.java:147)
>  ~[?:?]
>         at 
> org.apache.lucene.search.uhighlight.FieldOffsetStrategy.createOffsetsEnumFromReader(FieldOffsetStrategy.java:74)
>  ~[?:?]
>         at 
> org.apache.lucene.search.uhighlight.MemoryIndexOffsetStrategy.getOffsetsEnum(MemoryIndexOffsetStrategy.java:119)
>  ~[?:?]
>         at 
> org.apache.lucene.search.uhighlight.FieldHighlighter.highlightFieldForDoc(FieldHighlighter.java:80)
>  ~[?:?]
>         at 
> org.apache.lucene.search.uhighlight.UnifiedHighlighter.highlightFieldsAsObjects(UnifiedHighlighter.java:944)
>  ~[?:?]
>         at 
> org.apache.lucene.search.uhighlight.UnifiedHighlighter.highlightFields(UnifiedHighlighter.java:814)
>  ~[?:?]
>         at 
> org.apache.solr.highlight.UnifiedSolrHighlighter.doHighlighting(UnifiedSolrHighlighter.java:165)
>  ~[?:?]
>         at 
> org.apache.solr.handler.component.HighlightComponent.process(HighlightComponent.java:160)
>  ~[?:?]
>         at 
> org.apache.solr.handler.component.SearchHandler.handleRequestBody(SearchHandler.java:425)
>  ~[?:?]
> ....
> {noformat}
> The relevant portions of the schema.xml file are:
> {noformat}
> <?xml version="1.0" encoding="UTF-8" ?>
> <schema name="foo" version="1.5">
>     <fields>
>         [...]
>         <field name="provFindDateRange" type="date_range" indexed="true" 
> stored="true" multiValued="true"/>
>         [...]
>     </fields>
>     [...]
>     <types>
>         [...]
>         <fieldType name="date_range" class="solr.DateRangeField"/>
>         [...]
>     </types>
> </schema>
> {noformat}
> It's entirely possible there's something wonky in my indexed data, but it all 
> seemed to be processed by the POST tool without error, so I assumed it's all 
> right.
> I'm not sure how to troubleshoot this. Any guidance would be greatly 
> appreciated.
> Thank you.
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@solr.apache.org
For additional commands, e-mail: issues-h...@solr.apache.org

Reply via email to