Using a Field extending AbstractField causes a ClassCastException in DocumentBuilderIndexedEntity when using @AnalyzerDiscriminator

Description

I use a @AnalyzerDiscriminator in order to return the name of an existing analyzer depending on the language out of my Analzyers defined in @AnalyzerDefs. Further on I use a custom Field extending AbstractField/implementing org.apache.lucene.document.Fieldable within a custom FieldBridge. On building the corresponding index I then do get a ClassCastException from ocumentBuilderIndexedEntity's allowAnalyzerDiscriminatorOverride() method because this method casts the document's fields retrieved with doc.getFields() to Field instead of Fieldable even though Fieldable interface implementing objects are only added to that list in Document! Thus Fieldable interface should rather be used here instead of Field.

Activity

Show:

Emmanuel Bernard April 8, 2010 at 3:54 PM

Thanks

Fixed

Details

Assignee

Reporter

Components

Fix versions

Affects versions

Priority

Created January 14, 2010 at 4:06 PM
Updated July 1, 2010 at 12:37 PM
Resolved April 8, 2010 at 3:54 PM

Flag notifications