lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "David Smiley (JIRA)" <>
Subject [jira] [Commented] (SOLR-4648) Create a PreAnalyzedUpdateProcessor
Date Thu, 04 Apr 2013 18:27:15 GMT


David Smiley commented on SOLR-4648:

I like how your refactoring has clarified the logic in the URP.  And I like your new PreAnalyzedUpdateProcessorFactory.createFieldType()

I think you're right that sharing Field instances isn't such a good idea after all.

* minor: in the URP, "for (Object o : src.getValues()) {" can be "for (Object o : src) {"
 since it implements Iterable, and for the single-value case avoids redundant collection wrapping.

The remaining thing I'm thinking of is wether PreAnalyzedUpdateProcessorFactory.createFieldType()
should move down into Solr's FieldType where it can be re-used so we don't duplicate this
code.  Seems pretty clear this is a good idea.  Then, I'm wondering if these Lucene FieldType
instances could be cached on Solr's SchemaField so that they don't have to be needlessly re-created
for each indexed value that runs through Solr.  The only obstacle I see to this is that getIndexOptions(field,val)
takes the value, and if that value were to alter the logic then the FieldType can't be shared.
 This is a protected method and I don't see anything that overrides it, and the default implementation
doesn't use the value.  I'll create another issue for that; I can get off track easily and
try to fix the world in one issue :-)
> Create a PreAnalyzedUpdateProcessor
> -----------------------------------
>                 Key: SOLR-4648
>                 URL:
>             Project: Solr
>          Issue Type: Bug
>          Components: update
>    Affects Versions: 4.3, 5.0
>            Reporter: Andrzej Bialecki 
>            Assignee: Andrzej Bialecki 
>             Fix For: 4.3, 5.0
>         Attachments: SOLR-4648.patch, SOLR-4648.patch, SOLR-4648.patch, SOLR-4648.patch
> Spin-off from the discussion in SOLR-4619.
> Instead of using a PreAnalyzedField type we can use an UpdateRequestProcessor that converts
any input field values to StorableField-s, using the PreAnalyzedParser-s, and then directly
passes StorableField-s to DocumentBuilder for indexing.

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:

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

View raw message