lucene-solr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Anders Melchiorsen (JIRA)" <>
Subject [jira] Commented: (SOLR-1404) Random failures with highlighting
Date Mon, 07 Sep 2009 08:33:57 GMT


Anders Melchiorsen commented on SOLR-1404:

Hi Igor, thanks for the patch.

It does seem to work for me. I will leave it for others to decide whether it is the best fix.
If the issue is not fixed at a lower layer, note that the HTMLStripStandardTokenizerFactory
seems to have a similar problem.

I reported that this problem exists with other tokenizers as well, including the HTMLStripCharFilterFactory+WhitespaceTokenizerFactory
combo that you recommend. Today, however, I cannot reproduce that behaviour. As I have been
reporting several issues, I find it likely that I have been confused by having multiple configurations
running at the same time.

> Random failures with highlighting
> ---------------------------------
>                 Key: SOLR-1404
>                 URL:
>             Project: Solr
>          Issue Type: Bug
>          Components: Analysis, highlighter
>    Affects Versions: 1.4
>            Reporter: Anders Melchiorsen
>             Fix For: 1.4
>         Attachments: SOLR-1404.patch
> With a recent Solr nightly, we started getting errors when highlighting.
> I have not been able to reduce our real setup to a minimal one that is failing, but the
same error seems to pop up with the configuration below. Note that the QUERY will mostly fail,
but it will work sometimes. Notably, after running "java -jar start.jar", the QUERY will work
the first time, but then start failing for a while. Seems that something is not being reset
> The example uses the deprecated HTMLStripWhitespaceTokenizerFactory but the problem apparently
also exists with other tokenizers; I was just unable to create a minimal example with other
> <?xml version="1.0" encoding="UTF-8" ?>
> <schema name="example" version="1.2">
>   <types>
>     <fieldType name="string" class="solr.StrField" />
>     <fieldtype name="testtype" class="solr.TextField">
>       <analyzer>
>         <tokenizer class="solr.HTMLStripWhitespaceTokenizerFactory" />
>       </analyzer>
>     </fieldtype>
>  </types>
>  <fields>
>    <field name="id" type="string" indexed="true" stored="false" />
>    <field name="test" type="testtype" indexed="false" stored="true" />
>  </fields>
>  <uniqueKey>id</uniqueKey>
> </schema>
> URL=http://localhost:8983/solr/update
> curl $URL --data-binary '<add><doc><field name="id">1</field><field
name="test">test</field></doc></add>' -H 'Content-type:text/xml; charset=utf-8'
> curl $URL --data-binary '<commit/>' -H 'Content-type:text/xml; charset=utf-8'
> curl 'http://localhost:8983/solr/select/?hl.fl=test&hl=true&q=id:1'
> Token test exceeds length
of provided text sized 4
> org.apache.solr.common.SolrException:
Token test exceeds length of provided text sized 4
> 	at org.apache.solr.highlight.DefaultSolrHighlighter.doHighlighting(
> 	at org.apache.solr.handler.component.HighlightComponent.process(
> 	at org.apache.solr.handler.component.SearchHandler.handleRequestBody(
> 	at org.apache.solr.handler.RequestHandlerBase.handleRequest(
> 	at org.apache.solr.core.SolrCore.execute(
> 	at org.apache.solr.servlet.SolrDispatchFilter.execute(
> 	at org.apache.solr.servlet.SolrDispatchFilter.doFilter(
> 	at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(
> 	at org.mortbay.jetty.servlet.ServletHandler.handle(
> 	at
> 	at org.mortbay.jetty.servlet.SessionHandler.handle(
> 	at org.mortbay.jetty.handler.ContextHandler.handle(
> 	at org.mortbay.jetty.webapp.WebAppContext.handle(
> 	at org.mortbay.jetty.handler.ContextHandlerCollection.handle(
> 	at org.mortbay.jetty.handler.HandlerCollection.handle(
> 	at org.mortbay.jetty.handler.HandlerWrapper.handle(
> 	at org.mortbay.jetty.Server.handle(
> 	at org.mortbay.jetty.HttpConnection.handleRequest(
> 	at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(
> 	at org.mortbay.jetty.HttpParser.parseNext(
> 	at org.mortbay.jetty.HttpParser.parseAvailable(
> 	at org.mortbay.jetty.HttpConnection.handle(
> 	at$
> 	at org.mortbay.thread.BoundedThreadPool$
> Caused by: Token test
exceeds length of provided text sized 4
> 	at
> 	at org.apache.solr.highlight.DefaultSolrHighlighter.doHighlighting(
> 	... 23 more

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message