lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Shane (Created) (JIRA)" <>
Subject [jira] [Created] (SOLR-2834) doesn't handle org.apache.solr.analysis.HTMLStripCharFilter
Date Fri, 14 Oct 2011 17:34:12 GMT doesn't handle org.apache.solr.analysis.HTMLStripCharFilter

                 Key: SOLR-2834
             Project: Solr
          Issue Type: Bug
          Components: Schema and Analysis
    Affects Versions: 3.4
            Reporter: Shane

When using to analysis a field, a ClassCastExcpetion is thrown if
the schema defines the filter org.apache.solr.analysis.HTMLStripCharFilter.  The exception

java.lang.ClassCastException: java.lang.String cannot be cast to java.util.List
       at org.apache.solr.client.solrj.response.AnalysisResponseBase.buildPhases(
       at org.apache.solr.client.solrj.response.FieldAnalysisResponse.setResponse(
       at org.apache.solr.client.solrj.request.FieldAnalysisRequest.process(

My schema definition is:

    <fieldType name="text" class="solr.TextField" positionIncrementGap="100">
        <charFilter class="solr.HTMLStripCharFilterFactory" />
        <tokenizer class="solr.StandardTokenizerFactory" />
        <filter class="solr.StandardFilterFactory" />
        <filter class="solr.TrimFilterFactory" />
        <filter class="solr.LowerCaseFilterFactory" />

The response is part is:

        <lst name="query">
          <str name="org.apache.solr.analysis.HTMLStripCharFilter">testing analysis</str>
          <arr name="org.apache.lucene.analysis.standard.StandardTokenizer">

A simplistic fix would be to test if the Entry value is an instance of List.

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:!default.jspa
For more information on JIRA, see:


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message