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

Markus Jelsma commented on SOLR-4137:
-------------------------------------

Hi Simon, FYI, it seems part of the bug is still present. We're testing whether 
or not we can get rid of the stopfilter, now we're seeing several queries fail 
with the following stacktrace if there's a stopword present in the query.

{code}
java.lang.StringIndexOutOfBoundsException: String index out of range: 228
        at java.lang.String.substring(String.java:1934)
        at 
org.apache.lucene.search.vectorhighlight.BaseFragmentsBuilder.makeFragment(BaseFragmentsBuilder.java:178)
        at 
org.apache.lucene.search.vectorhighlight.BaseFragmentsBuilder.createFragments(BaseFragmentsBuilder.java:144)
        at 
org.apache.lucene.search.vectorhighlight.FastVectorHighlighter.getBestFragments(FastVectorHighlighter.java:186)
        at 
org.apache.solr.highlight.DefaultSolrHighlighter.doHighlightingByFastVectorHighlighter(DefaultSolrHighlighter.java:564)
        at 
org.apache.solr.highlight.DefaultSolrHighlighter.doHighlighting(DefaultSolrHighlighter.java:391)
        at 
org.apache.solr.handler.component.HighlightComponent.process(HighlightComponent.java:139)
        at 
org.apache.solr.handler.component.SearchHandler.handleRequestBody(SearchHandler.java:216)
        at 
org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandlerBase.java:135)
        at org.apache.solr.core.SolrCore.execute(SolrCore.java:1811)
        at 
org.apache.solr.servlet.SolrDispatchFilter.execute(SolrDispatchFilter.java:660)
        at 
org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:345)
        at 
org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:141)
        at 
org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1307)
        at 
org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:453)
        at 
org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:137)
        at 
org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:560)
        at 
org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:231)
        at 
org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1072)
        at 
org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:382)
        at 
org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:193)
        at 
org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1006)
        at 
org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:135)
        at 
org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:255)
        at 
org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.java:154)
        at 
org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:116)
        at org.eclipse.jetty.server.Server.handle(Server.java:365)
        at 
org.eclipse.jetty.server.AbstractHttpConnection.handleRequest(AbstractHttpConnection.java:485)
        at 
org.eclipse.jetty.server.BlockingHttpConnection.handleRequest(BlockingHttpConnection.java:53)
        at 
org.eclipse.jetty.server.AbstractHttpConnection.headerComplete(AbstractHttpConnection.java:926)
        at 
org.eclipse.jetty.server.AbstractHttpConnection$RequestHandler.headerComplete(AbstractHttpConnection.java:988)
        at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:635)
        at org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:235)
        at 
org.eclipse.jetty.server.BlockingHttpConnection.handle(BlockingHttpConnection.java:72)
        at 
org.eclipse.jetty.server.bio.SocketConnector$ConnectorEndPoint.run(SocketConnector.java:264)
        at 
org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:608)
        at 
org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:543)
        at java.lang.Thread.run(Thread.java:662)
{code}
                
> FastVectorHighlighter: StringIndexOutOfBoundsException in BaseFragmentsBuilder
> ------------------------------------------------------------------------------
>
>                 Key: SOLR-4137
>                 URL: https://issues.apache.org/jira/browse/SOLR-4137
>             Project: Solr
>          Issue Type: Bug
>          Components: highlighter
>    Affects Versions: 3.6.1, 4.0, 4.1, 4.2, 4.2.1
>            Reporter: Marcel
>            Assignee: Simon Willnauer
>             Fix For: 4.3
>
>
> under some circumstances the BaseFragmentsBuilder genereates a 
> StringIndexOutOfBoundsException inside the makeFragment method.
> The starting offset is higher than the end offset.
> I did a small patch checking the offsets and posted it over there at 
> Stackoverflow: 
> http://stackoverflow.com/questions/12456448/solr-highlight-bug-with-usefastvectorhighlighter
> The code in 4.0 seems to be the same as in 3.6.1
> Example how to reproduce the behaviour:
> There is a word called "www.DAKgesundAktivBonus.de" inside the index. If you 
> search for "dak bonus" some offset calculations went wrong.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

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

Reply via email to